Mouse code for the MacroRat
main.cpp
- Committer:
- sahilmgandhi
- Date:
- 2017-04-25
- Revision:
- 0:a03c771ab78e
- Child:
- 1:8a4b2f573923
File content as of revision 0:a03c771ab78e:
#include "mbed.h" #include <stdlib.h> DigitalOut redLed(PC_0); DigitalOut blueLed(PC_1); DigitalOut greenLed(PC_2); DigitalOut IR_1(PB_0); DigitalOut IR_2(PB_1); DigitalOut IR_3(PB_13); DigitalOut IR_4(PB_14); Serial serial(SERIAL_TX, SERIAL_RX); int main() { while (1) { redLed.write(0); wait_ms(1000); redLed.write(1); greenLed.write(0); wait_ms(1000); greenLed.write(1); blueLed.write(0); wait_ms(1000); blueLed.write(1); } }