09-17-2021 08:23 AM
I need my data acquisition system to have a channel that saves user input as triggers. basically saving the timestamp of a key or mouse button press. preferably with an indication of what type of an event it was (start/stop, events A/B/C/D, etc.)
I tried to understand from the manual whether DASYLab has this ability, but so far I didn't come across something similar.
1) Can someone confirm if DASYLab has or doesn't have this ability?
2) If not, can I create a script module that does that?
3) Does someone have an example of a similar script module?
09-17-2021 10:27 AM
Hey Pnina,
DASYLab cannot trap mouse clicks or keyboard key events and I don't see a solution using the Python Script module. This is because a Python script runs inline with the rest of the worksheet modules. Because of this, it cannot use an infinite loop or input statement that would hold up execution. Instead, it must perform its task and exit so that the next DASYLab module can do its thing.
Best regards,
John