Hi is there some sample code describing the use of TCP or UDP in controlling as well as reading data from PsychoPy?.
I’m new to PsychoPy. Just migrating to it after > 15 years of running visual behavior + physiology experiments using a (home-brew) C++ program that monitored behavior (eye position etc) presented visual stimuli (using a Cambridge Systems board) and triggered imaging (intrinsic signal optical imaging). I would like to still use my old software for behavior, timing etc while presenting stimuli and running some routines (e.g. staircase to get thresholds). The easiest would be to communicate between the C++ machine and PsychoPy (on a Linux machine) via TCP or UDP, which could trigger either low level (‘display grating’) or high level (‘run staircase’) routines on PsychoPy and get some communication back from PsychoPy
So my question:
1: Are there examples I can use to quickly build up code (using the Coder)?
2: Is there any preference for TCP vs UDP