Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Diff: main.cpp
- Revision:
- 30:0c89e3f9bf05
- Parent:
- 29:2146e1bb7b4a
--- a/main.cpp Tue Sep 08 14:50:19 2020 +0000
+++ b/main.cpp Tue Sep 08 15:05:33 2020 +0000
@@ -1,27 +1,17 @@
#include "mbed.h"
- DigitalOut led_rouge (LED4);
- DigitalOut led_verte (LED2);
- DigitalIn BP2(PTC6);
- DigitalIn BP3 (PTA4);
+ DigitalOut led (D2);
+ DigitalIn BP (D3);
int main() {
while(1) {
- if (BP2==1)
+ if (BP==1)
{
- led_rouge = 1;
+ led = 1;
}
else
{
- led_rouge =0;
- }
- if (BP3==1)
- {
- led_verte = 1;
- }
- else
- {
- led_verte = 0;
+ led =0;
}
}