note: user can force pyautogui to stop running by moving the mouse to a corner of the screen
pip3 install pyautogui
import pyautogui
for i in range(100):
pyautogui.moveTo(100, 100, duration = 0.25)
pyautogui.moveTo(200, 100, duration = 0.25)
pyautogui.moveTo(200, 200, duration = 0.25)
pyautogui.moveTo(100, 200, duration = 0.25)
import pyautogui
import threading
import datetime
screenSize= pyautogui.size() # get screensize
def moveMouse():
pyautogui.moveTo95, screenSize[1], duration = 1
def clickMouse():
pyautogui.click()
main()
def main():
hour = datetime.datetime.now().hour
if hour == 17 or hour == 12:
print('end of day reached')
quit()
else:
threading.Timer(5.0, moveMouse).start()
threading.Timer(10.0, clickMouse).start()
main()