ScreenSHTR – take screenshots and send them to your server

Last modified date

Comments: 0

As you can see, CVisionDemy not only host computer vision posts but also various tutorials and tips & tricks. This is something I made in my freetime and for learning purpose. This last one is the same reason I present you this program. It makes screenshots and send them to a FTP server.

It first was only a few lines of code:

import pyautogui

pyautogui.screenshot(screenFolder + "\\" + today + "_{}.png".format(index))

As you can see, to do the screenshot, we use pyautogui library. Do install it use pip install pyautogui.

The other functions are just addition features along the core idea: we have a method which archive all the images taken until a given hour in a ZIP file, a method which send this .zip to a FTP server and some points where I am using a configuration file to give the necessary values to the script. These values can be changed by the user.

To run the script you must have the config file ScreenSHTR.ini in the same location of .py file.


Source code is available on GitHub.

All was made just for fun. You can find more informations in code comments.

Feel free to modify and improve the code if you want. Suggestions are widely accepted.

Stay tuned because this script could evolve fast in something really interesting.

Leave a Reply

Your email address will not be published. Required fields are marked *

Post comment