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.
Diff: Blinking.cpp
- Revision:
- 2:553cc8c4474f
- Parent:
- 1:9929cc08730b
- Child:
- 3:99f8c29cbac7
--- a/Blinking.cpp Fri Nov 15 14:00:57 2019 +0000
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,32 +0,0 @@
-#include "mbed.h"
-// genera un oggetto serial collegato al PC
-Serial pc(USBTX, USBRX);
-
-// genera un oggetto DigitalOut collegato al Led
-DigitalIn myButton(USER_BUTTON);
-DigitalOut myLed(LED1);
-
-//DigitalIn myButton(PA_0); // verde
-int main()
-{
- // configura velocità della comunicazione seriale su USB-VirtualCom e invia messaggio di benvenuto
- pc.baud(921600); //921600 bps
-
- while(true)
- {
- myLed = 0;
- wait(1);
- myLed = 1;
-
- if(myButton==0)
- {
- pc.printf("IN = 0\r\n");
- myLed = 1;
- }
- else
- {
- pc.printf("IN = 1\r\n");
- myLed = 0;
- }
- }
-}