Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

problem with timing in python and psychopy: recording a video and audio and showing a circle and sending a marker to EEG #120

Open
Niloofar-GH opened this issue May 31, 2024 · 0 comments

Comments

@Niloofar-GH
Copy link

Hi,

In my script, I show a text "press s to start and press f to finish the experiment". when I press s key the audio and video recording start at the same time ( I am recording my screen with one webcam ) and then I show one green circle with the duration of one second just one time and at the same time I want to send a trigger to EEG so I tried the script and it worked:

Screenshot (1)

but there is one problem after running my script. I saw the recorded video. This recorded video is related to screen that shows the circle. I saw that the video recording start with delay and I cannot see the green circle flashing on the screen and I understood that I have to make a delay it means that when I press the s start the first audio and video recording and then set one second delay and then show the green circle and send the trigger to the EEG so therefore when I see the recorded video at the end of my script I can see the green circle on the recorded video. So I changed my while loop to the format below:

Screenshot (2)

it works now. It means when I see the recorded video I can see the text "press s to start and press f to finish the experiment" and after less than one second I can see a green circle but the problem is that I can not chang the timing of the delay. It means that when I set psy.core.wait to 0.030 (less than one seond), in my recorded video the timing of the delay is the same.

Do you have any ideas how can I solve this issue?

Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant