Hardware Logitech Dual Action P/N 863247-0010 usb corded controller Software Python on a windows 10 machine, using VS-Code IDE goto https://code.visualstudio.com/ and download the VS code for your machine goto the extensions and install python goto the CLI and type python --version to confirm the python installation. install pygame at the CLI by typing py -m pip install -U pygame --user (for help goto https://www.pygame.org/wiki/GettingStarted) pygame is the python code that has useful libraries for interfacing game controllers with your code commands. I used this code to test whether my code/game controller/ laptop/ were working: https://github.com/denilsonsa/pygame-joystick-test (thank you denilsonsa)
NEW code. I asked ChatGPT to write code for controlling motors in python. PyJoyMotor needs RPi.GPIO library loaded before building. Also, using GPIO pins with Ubuntu, is NOT a realtime way of controlling motors. So a real time operating system may have to be explored if we lose control of the motors.