Task Examples (Arduino)

The six training stages of the Follow the Light task (see Task Examples (Bpod)), run by an Arduino instead of a Bpod (BEHAVIOR_CONTROLLER set to OTHER). Each page has the task and the part of the firmware that runs its trials. All of them use the same firmware, village_arduino.ino, uploaded once to the board.

File

What it shows

arduino_1_habituation.py

Arduino version of bpod_1_habituation.py: the same task and states (see its diagram), run by an Arduino that reports every state and poke to the Raspberry Pi.

arduino_2_passive.py

Arduino version of bpod_2_passive.py: the same task and states (see its diagram), run by an Arduino that reports every state and poke to the Raspberry Pi. The ITI and the penalty, if any, are timed by the Raspberry Pi.

arduino_3_active.py

Arduino version of bpod_3_active.py: the same task and states (see its diagram), run by an Arduino that reports every state and poke to the Raspberry Pi. The ITI and the penalty, if any, are timed by the Raspberry Pi.

arduino_4_center_initiated.py

Arduino version of bpod_4_center_initiated.py: the same task and states (see its diagram), run by an Arduino that reports every state and poke to the Raspberry Pi. The ITI and the penalty, if any, are timed by the Raspberry Pi.

arduino_5_introduce_penalty.py

Arduino version of bpod_5_introduce_penalty.py: the same task and states (see its diagram), run by an Arduino that reports every state and poke to the Raspberry Pi. The ITI and the penalty, if any, are timed by the Raspberry Pi.

arduino_6_delay.py

Arduino version of bpod_6_delay.py: the same task and states (see its diagram), run by an Arduino that reports every state and poke to the Raspberry Pi. The ITI and the penalty, if any, are timed by the Raspberry Pi.

They need the same calibrations as the Bpod ones (see Water Calibration and Sound Calibration):

  • Stages 2 to 6: water, for ports 1 and 3.

  • Stages 5 and 6: also the tone_600 sound, for speaker 0 (left) at 70 dB: the penalty tone.

The example training protocol moves the subjects through the Bpod tasks. To use it with these ones, change the task names in it (Bpod1Habituation → Arduino1Habituation, Bpod2Passive → Arduino2Passive…): they read the same settings and register the same values.