Control of mbed using OSC. Based on code from the Make Controller. Right now you can turn the onboard LEDs on/off and toggle 8 digital out pins. More I/O will be done in the future.
main.cpp
- Committer:
- pehrhovey
- Date:
- 2010-03-17
- Revision:
- 0:439354122597
File content as of revision 0:439354122597:
/* * Pehr Hovey * mBed OSC * main.cpp * control mbed with OSC using mbed's ethernet port and UDP * */ #include "mbed.h" extern int osc_init(); extern void osc_poll(); int main() { osc_init(); //set everything up //Send a startup packet printf("mBed OSC Started...\r\n"); while(1) { //Poll OSC to get incoming UDP packets and handle them osc_poll(); //do other things... wait(0.1); //A little sleep to let Timeout work } }