|
Hello, I am new to Bonsai and am currently developing a workflow using an Open Ephys nose-poke device. My goal is to open a water valve whenever an infrared (IR) beam break is detected. I would like to ask whether there is a relatively simple and concise way to implement this workflow. I am considering separating the LED-control node and the event-publishing node into different branches and connecting them using a publish–subscribe structure. Has anyone implemented a similar nose-poke and water-reward workflow, or would you be willing to share an example? I have also added a Could anyone advise me on what might be causing these settings not to be preserved after saving the workflow, and how I might resolve this issue? I will attach my current Bonsai workflow below for reference. Thank you very much for your time and assistance. |
Replies: 1 comment 5 replies
|
Hi @soyyso! Nice to see you on the forums again! So with regards to the publish/subscribe structure, you are already halfway there, you already published the events coming from the device with a
I could not find the I attached the reorganized workflow anyway with the sections split up and annotated. |








Hi @soyyso, the 2nd reorganization looks good to me! Unfortunately, you probably realized this, that when using
OutputPulseEnableyou need to list all the ports to enable at once, so you can't really separate that configuration out. However, I would just keep the LED in theOutputPulseEnableand any other LED configuration settings and disable or enable the LED output instead. You can group the LED output in aGroupWorkflowthat you can disable if you don't need:Does that make it simpler?
Also I noticed one other thing in your workflow:
I see you have zipped up these two sequences, but be careful when using [https://bonsai-rx.org/docs/articles/reactive-zip.html] as the number of eleme…