johan yapson
/
Nucleo_blink_led
first edition
main.cpp
- Committer:
- johanyapson
- Date:
- 2017-02-27
- Revision:
- 0:582b91be6159
File content as of revision 0:582b91be6159:
#include "mbed.h" DigitalIn input(D2); Serial pc(SERIAL_TX, SERIAL_RX); int i ; int hitung = 0; int main() { pc.baud(115200); while(1) { if (D2 == 1) { i++; } hitung = i; pc.printf("barang = %d ",hitung); wait(1.0); } }