- Open your web browser and navigate to the official Arduino Software Page.
- Locate the Arduino IDE 2.x.x section (or the latest stable version).
- Click on the link labeled "Windows Win 10 and newer, 64 bits".
- On the next page, you can choose to make a donation or click "JUST DOWNLOAD" to begin downloading the executable file (e.g.,
arduino-ide_2.x.x_Windows_64bit.exe).
- Navigate to your Downloads folder and double-click the downloaded
.exefile. - If a User Account Control (UAC) prompt appears asking for permission, click Yes.
- License Agreement: Read the terms and click I Agree.
- Installation Options: Choose whether you want to install the software for Anyone using this computer (requires admin privileges) or Just for me. Click Next.
- Choose Install Location: Leave the default destination folder as is (
C:\Program Files\Arduino IDE) and click Install.
- During installation, Windows may prompt you to install device drivers from "Arduino srl" or "Adafruit Industries". Crucially click "Install" on these prompts; these drivers allow your computer to communicate with Arduino hardware over USB.
- Once complete, leave the "Run Arduino IDE" box checked and click Finish.
- Ensure the program opens successfully. If Windows Defender Firewall blocks some features, click Allow access for private networks.
Hardware & Code Setup:
- The EKG sensor should be wired to pins 3.3V, GND, and A0 on your Arduino UNO.
- Ensure your Arduino sketch initializes serial communication with
Serial.begin(9600);inside thesetup()function.
- Plug the Arduino Uno into your computer using a USB cable.
- Windows should automatically detect the board and finish installing drivers in the background (usually indicated by a notification in the bottom-right corner).
- Open the Arduino IDE.
- Go to Tools → Board → Arduino AVR Boards → Arduino Uno.
- Go to Tools → Port and select the COM port your Arduino appears on (e.g.,
COM3 (Arduino Uno)orCOM4 (Arduino Uno)). This number varies by computer and USB port used.- If no port appears under this menu, try a different USB cable or port, and confirm the drivers installed correctly in Step 1.3.
If your project doesn't already include an .ino file, paste the following basic EMG-reading sketch into a new sketch window:
void setup() {
Serial.begin(9600);
}
void loop() {
int sensorValue = analogRead(A0);
Serial.println(sensorValue);
delay(10);
}Save the sketch (File → Save) before uploading.
- Click the right-arrow "Upload" icon in the top-left toolbar.
- It will then upload to the board. Watch for the small TX/RX LEDs on the Arduino to blink rapidly, this confirms data is transferring.
- When finished, the IDE displays "Done uploading." in the status bar. Troubleshooting: "Access is denied" / "unable to open port" errors during upload
This means another program is already holding the COM port open, blocking the IDE from using it. Before retrying:
- Close any open Serial Monitor or Serial Plotter window.
- Stop any running Python script that might be reading the serial port (
Ctrl+Cin its terminal). - Close other programs that might use serial ports (PuTTY, VS Code serial extensions, a second Arduino IDE window).
- If it still fails, unplug and replug the Arduino's USB cable, then try uploading again.
- Go to the official Python 3.12 downloads page (or the latest 3.12.x patch release).
- Scroll to the Files section and click Windows installer (64-bit).
- Double-click the downloaded Python installer file.
- CRITICAL STEP: At the bottom of the installation window, check the box that says "Add python.exe to PATH". If you skip this, your command prompt will not recognize Python or
pipcommands. - Check the box for "Use admin privileges when installing py.exe" (if available).
- Click Install Now at the top of the window.
- At the very end of the installation process, the wizard may show an option that says "Disable path length limit".
- Click this option. It prevents Windows from running into errors later on if Python packages are buried deep within nested folders.
- Click Close.
To make sure both environments are configured properly, use the Windows Command Prompt.
- Press the Windows Key, type
cmd, and press Enter to open the Command Prompt. - To verify Python, type the following command and press Enter:
python --version
Expected Output: Python 3.x.x
3. To verify pip (Python's package manager), type the following command and press Enter:
pip --version
Expected Output: pip xx.x from ... (python 3.x)
If you receive an error stating 'python' is not recognized as an internal or external command, the PATH checkbox was likely missed during installation.
- Fix: Re-run the downloaded Python installer file, choose Modify, and ensure the "Add Python to environment variables" or "PATH" option is checked on the advanced options page.
Before running the game, you need to install the project's external Python libraries (such as those needed for serial communication and graphics).
- Open the Command Prompt (
cmd). - Navigate to your project's root directory (where the
requirements.txtfile is located) using thecdcommand:
cd path\to\your\project_folder
- Run the following command to install all necessary dependencies at once:
pip install -r requirements.txt
- Wait for the installation to finish. You should see a message indicating successful installation of the packages.
Once the Arduino is plugged in and your Python dependencies are installed, you can launch the game.
- Ensure you are still in your project's root directory in the Command Prompt.
- Execute the Python script located in the
guifolder by running:
python gui/dino_game.py
- The Dino Game interface should now pop up on your screen.
⚠️ Serial Connection Warning: Make sure your Arduino is plugged in, and that the game is set to use a baud rate of 9600 (this matches the EKG sensor output rate). If the game asks for a COM port, select the one corresponding to your Arduino UNO.