AMKpy

Powerful auto mouse click and keyboard type in python tool.

AMKpy drawing


How works

Spanish version here.
Spanish video here.
Spanish blog post about this here.

AMKpy is a script in the python language where we can automate tasks which we perform with our mouse and keyboard, such as:

And everything that your imagination allows you... for example the draw!

Adding and modifying lines of code depending on our action to automate,and executing the code when we have it ready and every time we need it.


Guide

Requirements:


Steps:

- Import pyAutogui library, we place inside the console:

MacOS pip3 install pyautogui
Windows pip install pyautogui

Find more about PyAutoGUI here.

- Download files here.

- Open main.py to calculate the size of your screen in pixels to then place our clicks using the X and Y axes or width and height. This step is not necessary but it is helpful to know how to place ourselves inside the screen.

- Knowing the above we are ready to automate our task, our code without enabling any function we will see it like this:

Depending on what we want to do, we will add one of these options below the other:

- pyautogui.click(70, 40) for click.
- pyautogui.typewrite('writing hello') to write.
- pyautogui.hotkey('command', 'q') for hotkeys.
- pyautogui.scroll(-500) for scroll down.
- pyautogui.scroll(500) for scroll up.
- time.sleep(2) with the number of seconds we want to pause.

Four options, click, write, hotkey and pause... simple right?!

When you add a command and want to verify or run the script, run the file! Learn failing.

You do not need more to automate processes, keep in mind that if you need to automate something more complex, this tool is NOT for that, since we know that there are other more robust ways to do it, such as web scraping, among others.

Look at the examples bellows to get inspired.
Many things can be done with these simple steps.


Live examples

Drawing

Autopush for nothing


Download

Download clicking.

All files here

main.py with the basics.

Examples:

draw.py with draw.
autopush.py with autopush.

See repositorie on GitHub.

by Joaquin Metayer