Mechatronics example program

Dependencies:   mbed

main.cpp

Committer:
ykuroda
Date:
2017-10-05
Revision:
0:fbfdf477cfd1
Child:
1:e450b69e093a

File content as of revision 0:fbfdf477cfd1:

#include "mbed.h"

DigitalOut myled(LED1);
DigitalIn d0(D0);

int main() {
    while(1) {
        myled = ~myled; // LED is toggled

        printf("D[%1d]\n",d0);
    }
}