The structure of this code is to use a custom sketch for serial communication on the arduino and then use a Python script to command the Arduino pins on or off. The Arduino will have pythoncontrol.ino ...
This project was made for the Junior Year Robotics Competition (JYRC) 2022 held at Ghulam Ishaq Khan Institute of Engineering Sciences and Technology (GIKI). The competition rules are explained here.