Skip to content

Commit ca47124

Browse files
authored
Add files via upload
Added tone to signal pending reward.
1 parent bfea4db commit ca47124

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

examples/FORCE/FORCE.ino

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,9 @@ void loop() {
3232
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////
3333
if (force.pressLength > force.hold_time) { //if the force lever is held down for longer than the hold_req
3434
force.presses++; //keep count of successful presses
35+
3536
if (force.presses == force.ratio) { //if the ratio for number of presses is met
36-
37+
force.Tone(); //tone signals pending reward
3738
//This code block runs only if it's a progressive ratio session
3839
if (force.PR == true) { //if it's a progressive ratio session
3940
if ((force.trial % force.trials_per_block) == 0) { //if the number of trials_per_block is reached
@@ -43,6 +44,7 @@ void loop() {
4344
}
4445

4546
force.Dispense(); //dispense reward
47+
force.Timeout(force.timeout_length); //timeout (length in seconds)
4648
force.presses = 0; //reset presses
4749
}
4850
else {

0 commit comments

Comments
 (0)