This repository contains all Arduino codes used in the ACROM Chapter 1: Smart Robot Workshop.
Each code corresponds to a specific session activity or the final integrated smart robot project.
/codes/
βββ 01_Blink_LED.ino
βββ 02_Button_LED.ino
βββ 03_Buzzer.ino
βββ 04_RGB_LED.ino
βββ 05_IR_Sensor.ino
βββ 06_Ultrasonic_Sensor.ino
βββ 07_Touch_Sensor.ino
βββ 08_Tilt_Sensor.ino
βββ 09_Bluetooth_LED.ino
βββ 10_Bluetooth_Motor.ino
βββ 11_OLED_Display.ino
βββ 12_Obstacle_Avoidance.ino
βββ 13_Smart_Robot_Final.ino
Follow these steps to run the codes:
-
Install Arduino IDE
Download and install the latest version from the Arduino Software page. -
Clone this repository
Open your terminal or command prompt and run:
git clone https://github.com/YOUR-ORG/ACROM-Chapter1.git
-
Open a code file
Navigate to theACROM-Chapter1/codes/directory and open any.inofile in the Arduino IDE. -
Select your board
Go to Tools > Board > Arduino Uno. -
Upload and test
- Connect your Arduino Uno to your computer
- Select the correct port under Tools > Port
- Click Upload to transfer the code
- 01_Blink_LED.ino β The classic Arduino "Hello World" β blinks an LED.
- 02_Button_LED.ino β Turns an LED on/off using a button.
- 03_Buzzer.ino β Produces sound with a buzzer.
- 04_RGB_LED.ino β Controls the colors of an RGB LED.
- 05_IR_Sensor.ino β Detects objects using an IR sensor.
- 06_Ultrasonic_Sensor.ino β Measures distance with an HC-SR04 sensor.
- 07_Touch_Sensor.ino β Detects human touch input.
- 08_Tilt_Sensor.ino β Detects tilt/motion.
- 09_Bluetooth_LED.ino β Controls an LED via Bluetooth.
- 10_Bluetooth_Motor.ino β Controls motors via Bluetooth.
- 11_OLED_Display.ino β Displays text/graphics on OLED.
- 12_Obstacle_Avoidance.ino β Simple obstacle avoidance for a robot.
- 13_Smart_Robot_Final.ino β The final integrated Smart Robot project.
- All codes are written for the Arduino Uno board.
- For OLED Display and HC-SR04 Ultrasonic Sensor, ensure you install required libraries:
Go to Arduino IDE β Sketch β Include Library β Manage Libraries... - Refer to the Workshop Manual for wiring diagrams and hardware setup.
To follow along, youβll need:
- Arduino Uno
- Breadboard & jumper wires
- LEDs, buzzer, and sensors (IR, Ultrasonic, Touch, Tilt, etc.)
- Bluetooth Module (HC-05/06)
- OLED Display module
- Arduino IDE (latest version)
The Smart Robot Final Code (13_Smart_Robot_Final.ino) integrates:
- Sensor fusion (IR, Ultrasonic, Touch, Tilt)
- Obstacle avoidance
- Bluetooth remote control
- OLED text display
- Autonomous smart robot functionalityβ¨
Contributions are welcome!
Feel free to fork this repository and open a pull request with improvements, bug fixes, or enhancements.