DigitalIn Hello World

Fork of DigitalIn_HelloWorld_Mbed by Mbed

Use

The DigitalIn API is used to read a digital pin. The value will be either 0 or 1. Buttons and switches are some of the more common digital inputs.

API

API reference.

Import librarymbed

No documentation found.
Revision:
6:315942f167d7
Parent:
5:fa65447e171b
Child:
7:64e67ec4441e
--- a/main.cpp	Fri Mar 27 21:01:15 2015 +0000
+++ b/main.cpp	Fri Mar 27 21:05:43 2015 +0000
@@ -15,7 +15,7 @@
  */
 #include "mbed.h"
 
-DigitalIn  mypin(BUTTON1);
+DigitalIn  mypin(BUTTON1); // change this to the button on your board
 DigitalOut myled(LED1);
 
 int main()