Keisuke Sehara
/
STM32_Whisking
fast-feedback virtual target task code on STM Nucleo
rig.cpp@3:991c6d5ce19d, 2018-05-17 (annotated)
- Committer:
- gwappa
- Date:
- Thu May 17 13:37:43 2018 +0000
- Revision:
- 3:991c6d5ce19d
- Child:
- 4:fcf597f82632
implement arraylists
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
gwappa | 3:991c6d5ce19d | 1 | #include "rig.h" |
gwappa | 3:991c6d5ce19d | 2 | |
gwappa | 3:991c6d5ce19d | 3 | // the task timer |
gwappa | 3:991c6d5ce19d | 4 | Timer timer; |
gwappa | 3:991c6d5ce19d | 5 | |
gwappa | 3:991c6d5ce19d | 6 | // state time out |
gwappa | 3:991c6d5ce19d | 7 | Timeout stateTimeout; |
gwappa | 3:991c6d5ce19d | 8 | |
gwappa | 3:991c6d5ce19d | 9 | // reward time out |
gwappa | 3:991c6d5ce19d | 10 | Timeout rewardTimeout; |
gwappa | 3:991c6d5ce19d | 11 | |
gwappa | 3:991c6d5ce19d | 12 | // input |
gwappa | 3:991c6d5ce19d | 13 | InterruptIn whiskIn(PA_13); |
gwappa | 3:991c6d5ce19d | 14 | InterruptIn lickIn(PA_14); |
gwappa | 3:991c6d5ce19d | 15 | |
gwappa | 3:991c6d5ce19d | 16 | // output |
gwappa | 3:991c6d5ce19d | 17 | DigitalOut taskOut(PA_15); |
gwappa | 3:991c6d5ce19d | 18 | DigitalOut cueOut(LED1); // or PA_4 |
gwappa | 3:991c6d5ce19d | 19 | DigitalOut enableOut(PA_0); |
gwappa | 3:991c6d5ce19d | 20 | DigitalOut rewardOut(PA_1); |
gwappa | 3:991c6d5ce19d | 21 | |
gwappa | 3:991c6d5ce19d | 22 | Task task(Pair); |
gwappa | 3:991c6d5ce19d | 23 | Trial trial; |