Using Tang Shiming torque meter ( Tang S, Juusola M, 2010 Intrinsic Activity in the Fly Brain Gates Visual Information during Behavioral Choices.PLoS ONE 5(12):e14455.doi:10.1371/journal.pone.0014455) and a AD converter (USB 1208, Measurement computing). Input is downsampled to 21Hz, send to a waveform chart and a histogram, binarized to to decide if punishment output is given and to calculate a score. Experiment design is determined by another loop.
This was made without the realtime package.
julien.colomb@fu-berlin.de
for more details