Interference current stimulation program with kaji-lab ES device.
Dependencies: mbed SerialInputReactionHandler AMPulseTrain SwArr16MOSFET StrCommandHandler KajiLabES
main.cpp
- Committer:
- aktk
- Date:
- 2019-11-27
- Revision:
- 2:5cb68cc8ecaa
- Parent:
- 1:b97639dad576
File content as of revision 2:5cb68cc8ecaa:
#include "mbed.h" #include "subroutines.h" DigitalOut myled1(LED1); DigitalOut myled2(LED2); DigitalOut myled3(LED3); DigitalOut myled4(LED4); ProcessState pstate = WAIT_A_CERTAIN_KEY; int main() { printf("SystemCoreClock = %d Hz\n", SystemCoreClock); myled1 = myled2 = myled3 = myled4 = 0; init(); PRELOOP_POINT: while (pstate == WAIT_A_CERTAIN_KEY) { wait(0.5); myled3 = (!myled3); } myled3 = 1; while(pstate == MAIN_ROUTINE) { wait(.1); myled3 = (!myled3); } myled3 = 0; goto PRELOOP_POINT; }