Val Glynn
/
2_5_App_Board_Joystick
CA 2.5 App Board Joystick
Revision 0:fc75582c0f9d, committed 2020-07-26
- Comitter:
- vmg
- Date:
- Sun Jul 26 21:02:11 2020 +0000
- Commit message:
- CA 2.5 App Board Joystick
Changed in this revision
main.cpp | Show annotated file Show diff for this revision Revisions of this file |
mbed.bld | Show annotated file Show diff for this revision Revisions of this file |
diff -r 000000000000 -r fc75582c0f9d main.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/main.cpp Sun Jul 26 21:02:11 2020 +0000 @@ -0,0 +1,18 @@ +#include "mbed.h" + +BusIn joy(p15,p12,p13,p16); +DigitalIn fire(p14); + +BusOut leds(LED1,LED2,LED3,LED4); + +int main() +{ + while(1) { + if (fire) { + leds=0xf; + } else { + leds=joy; + } + wait(0.1); + } +}
diff -r 000000000000 -r fc75582c0f9d mbed.bld --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mbed.bld Sun Jul 26 21:02:11 2020 +0000 @@ -0,0 +1,1 @@ +https://os.mbed.com/users/mbed_official/code/mbed/builds/65be27845400 \ No newline at end of file