Libet had the subjects view an oscilloscope with a dot rotating periodically in a circle, and subjects were asked to retroactively report where the dot was when they first became aware that they were about to perform the voluntary task. He could then calculate the average latency between when the subject reported awareness and when the action actually occurred. I was able to replicate this setup in a more DIY manner.
I used a continuous rotating servo to turn a balsa wood arm with a period of 1.2s per rotation. Each time the arm of the clock passed over a photoresistor, a custom circuit I put together would return a digital low to the third channel of the arduino that's already recording EMG and EEG on channels 1 and 2. The drop in sample rate to 3333 Hz isn't an issue.
Unfortunately the clock needs an additional Arduino to drive the servo, since the data logging arduino can't put out enough power to do everything at once.
Here's the schematic.
Modifying the MATLAB code to detect the clock passing the 12:00 position was dead simple. The only inconvenient part of this new workflow is the researcher must manually write down all of the integer times reported (1-12) for each wrist flex and enter them one by one during the analysis. I'll work on streamlining it.
Here's the final result. Mean latency was 218 ms between awareness and action, with a significant RP showing up right as Libet documented at around 1 second before action. Monte Carlo (dotted blue) bars are 2SD from the mean signal (not plotted).