moses-palmer / pynput

Sends virtual input commands
GNU Lesser General Public License v3.0
1.79k stars 248 forks source link

Stop keyboard and mouse stream #337

Closed amitsou closed 3 years ago

amitsou commented 3 years ago

I need to get the keyboard and mouse stream every five minutes. I tried time.sleep() but it doesn't work. Is it possible in pynput?

moses-palmer commented 3 years ago

pynput will provide a continuous stream of events as they occur. I am uncertain what it would mean to get them every five minutes, would you please expand?

amitsou commented 3 years ago

Thank's for your time. I just wanted to create a cronjob in order to get the input and the mouse stream every 5 minutes, but I managed to achieve it using the schedule module in python3!

moses-palmer commented 3 years ago

Great! In that case, I will close this issue.