![](/media/cache/group/default_image.jpg.50x50_q85.jpg)
Checks which muscles are activated and gives and output (left/right/keypress/rest)
Dependencies: mbed
main.cpp
- Committer:
- woutende
- Date:
- 2015-10-16
- Revision:
- 0:8aba349193ec
File content as of revision 0:8aba349193ec:
#include "mbed.h" bool state_left = false; bool state_right = true; int main() { if (state_left == true) { if (state_right == true) { std::string state = "keypress"; std::cout << state; } else { std::string state = "left"; std::cout << state; } } else { if (state_right == true) { std::string state = "right"; std::cout << state; } else { std::string state = "rest"; std::cout << state; } } }