Beginner's Guide to Robotics with Arduino and TinkerCAD
1. What is Robotics?
Robotics is the science of designing and building machines that can move and react to the environment.
Robots are used in factories, homes, hospitals, and more. They often include sensors, motors, and
controllers.
2. Basic Electronic Components
LDR (Light Dependent Resistor): Changes resistance with light.
LED (Light Emitting Diode): A small light that turns on with electricity.
Resistor: Limits the current in a circuit.
Push Button: Turns something on/off when pressed.
Buzzer: Makes sound when powered.
3. Introduction to Arduino UNO
Arduino UNO is a microcontroller board used to control electronics. It has digital and analog pins, USB power
input, and can be programmed easily using the Arduino IDE or TinkerCAD simulator.
4. How to Use TinkerCAD
TinkerCAD is a free online simulator where you can build circuits and write Arduino code. Go to
https://tinkercad.com, create an account, and start using the Circuits section.
5. Important Arduino Pins
- 5V: Powers components
- GND: Ground
- Digital Pins (2-13): For output/input like LEDs
- Analog Pins (A0-A5): Read sensors like LDR
6. Circuit Project 1: LDR Controlled LED
Parts Needed: Arduino UNO, Breadboard, LDR, 10k Resistor, LED, 220 Ohm Resistor, Wires
Connect the LDR and 10k resistor as a voltage divider to A0. LED on pin 13.
Beginner's Guide to Robotics with Arduino and TinkerCAD
Arduino Code:
int ldrPin = A0;
int ledPin = 13;
void setup() {
pinMode(ledPin, OUTPUT);
void loop() {
int value = analogRead(ldrPin);
if(value < 500) digitalWrite(ledPin, HIGH);
else digitalWrite(ledPin, LOW);
7. Circuit Project 2: Push Button LED
Parts: Arduino UNO, Breadboard, Button, LED, 220 Ohm Resistor
Connect the button to pin 2 and LED to pin 13.
Code:
int button = 2;
int led = 13;
void setup() {
pinMode(button, INPUT);
pinMode(led, OUTPUT);
void loop() {
if(digitalRead(button)) digitalWrite(led, HIGH);
else digitalWrite(led, LOW);
8. Circuit Project 3: Buzzer Alarm System
Parts: Buzzer, Arduino, Breadboard
Connect buzzer to pin 9.
Code:
Beginner's Guide to Robotics with Arduino and TinkerCAD
void setup() {
pinMode(9, OUTPUT);
void loop() {
digitalWrite(9, HIGH);
delay(1000);
digitalWrite(9, LOW);
delay(1000);
9. Circuit Project 4: Automatic Street Light using LDR
Same as Project 1 but for street lights. Adjust LDR value to switch LED on at night.
10. Circuit Project 5: Traffic Light
Use 3 LEDs: Red to pin 9, Yellow to pin 10, Green to pin 11.
Code:
void setup() {
pinMode(9, OUTPUT);
pinMode(10, OUTPUT);
pinMode(11, OUTPUT);
void loop() {
digitalWrite(9, HIGH); delay(3000);
digitalWrite(9, LOW);
digitalWrite(10, HIGH); delay(1000);
digitalWrite(10, LOW);
digitalWrite(11, HIGH); delay(3000);
digitalWrite(11, LOW);