Blank program for v0.9 API
Dependencies: PsiSwarmV9 mbed
Fork of PsiSwarm_V8_Blank_CPP by
Diff: main.cpp
- Revision:
- 4:3af6e6afbfef
- Parent:
- 3:53cc107bcff1
--- a/main.cpp Thu Jun 01 23:04:49 2017 +0000 +++ b/main.cpp Mon Jun 05 22:47:38 2017 +0000 @@ -27,7 +27,8 @@ wait(0.8); // The display is still updating from init so wait a short while display.clear_display(); display.set_position(0,0); - display.write_string(" [ No Code ]"); + animations.set_colour(1); + display.write_string(" [ No Code ]"); } ///User code loop: This is where user code should go; it is run as an infinite loop @@ -61,7 +62,8 @@ user_code_setup(); ///run user code setup block user_code_running = 1; ///nb. user code can be paused by external commands sent from PC\BT interfaces while(1) { - user_code_loop(); ///run user code + if(user_code_running == 1) user_code_loop(); ///run user code + else wait_us(1000); } }