Skip to content

Commit 7edf7f5

Browse files
authored
Merge pull request #28 from banchan86/tutorial-reaction
Add reaction time task tutorial for Harp Hobgoblin
2 parents 4997f3f + 12aa009 commit 7edf7f5

23 files changed

Lines changed: 2169 additions & 1 deletion

images/hobgoblin-reactiontime-ledbutton.svg

Lines changed: 110 additions & 0 deletions
Loading

tutorials/hobgoblin-reaction.md

Lines changed: 304 additions & 0 deletions
Large diffs are not rendered by default.

tutorials/toc.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
11
- name: Harp Hobgoblin
22
- href: hobgoblin-setup.md
3-
- href: hobgoblin-acquisition.md
3+
- href: hobgoblin-acquisition.md
4+
- href: hobgoblin-reaction.md
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<WorkflowBuilder Version="2.8.5"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xmlns:rx="clr-namespace:Bonsai.Reactive;assembly=Bonsai.Core"
5+
xmlns:harp="clr-namespace:Bonsai.Harp;assembly=Bonsai.Harp"
6+
xmlns:p1="clr-namespace:Harp.Hobgoblin;assembly=Harp.Hobgoblin"
7+
xmlns="https://bonsai-rx.org/2018/workflow">
8+
<Workflow>
9+
<Nodes>
10+
<Expression xsi:type="rx:BehaviorSubject" TypeArguments="harp:HarpMessage">
11+
<rx:Name>Hobgoblin Commands</rx:Name>
12+
</Expression>
13+
<Expression xsi:type="Combinator">
14+
<Combinator xsi:type="p1:Device">
15+
<harp:OperationMode>Active</harp:OperationMode>
16+
<harp:OperationLed>On</harp:OperationLed>
17+
<harp:DumpRegisters>true</harp:DumpRegisters>
18+
<harp:VisualIndicators>On</harp:VisualIndicators>
19+
<harp:Heartbeat>Disabled</harp:Heartbeat>
20+
<harp:IgnoreErrors>false</harp:IgnoreErrors>
21+
<harp:PortName>COM7</harp:PortName>
22+
</Combinator>
23+
</Expression>
24+
<Expression xsi:type="Combinator">
25+
<Combinator xsi:type="p1:DeviceDataWriter">
26+
<p1:Path>data</p1:Path>
27+
<p1:Buffered>true</p1:Buffered>
28+
<p1:Overwrite>false</p1:Overwrite>
29+
<p1:FilterType>Include</p1:FilterType>
30+
<p1:MessageType xsi:nil="true" />
31+
</Combinator>
32+
</Expression>
33+
<Expression xsi:type="rx:PublishSubject">
34+
<Name>Hobgoblin Events</Name>
35+
</Expression>
36+
</Nodes>
37+
<Edges>
38+
<Edge From="0" To="1" Label="Source1" />
39+
<Edge From="1" To="2" Label="Source1" />
40+
<Edge From="2" To="3" Label="Source1" />
41+
</Edges>
42+
</Workflow>
43+
</WorkflowBuilder>
Lines changed: 73 additions & 0 deletions
Loading
Lines changed: 27 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,27 @@
1+
<?xml version="1.0" encoding="utf-8"?>
2+
<WorkflowBuilder Version="2.8.5"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xmlns:p1="clr-namespace:Harp.Hobgoblin;assembly=Harp.Hobgoblin"
5+
xmlns:harp="clr-namespace:Bonsai.Harp;assembly=Bonsai.Harp"
6+
xmlns="https://bonsai-rx.org/2018/workflow">
7+
<Workflow>
8+
<Nodes>
9+
<Expression xsi:type="SubscribeSubject">
10+
<Name>Hobgoblin Events</Name>
11+
</Expression>
12+
<Expression xsi:type="p1:Parse">
13+
<harp:Register xsi:type="p1:TimestampedDigitalOutputSet" />
14+
</Expression>
15+
<Expression xsi:type="SubscribeSubject">
16+
<Name>Hobgoblin Events</Name>
17+
</Expression>
18+
<Expression xsi:type="p1:Parse">
19+
<harp:Register xsi:type="p1:TimestampedDigitalInputState" />
20+
</Expression>
21+
</Nodes>
22+
<Edges>
23+
<Edge From="0" To="1" Label="Source1" />
24+
<Edge From="2" To="3" Label="Source1" />
25+
</Edges>
26+
</Workflow>
27+
</WorkflowBuilder>

0 commit comments

Comments
 (0)