Circuit Documentation
Summary
This circuit consists of an Arduino Nano microcontroller, a Tower Pro SG90 servo motor, and a rain sensor. The Arduino Nano serves as the central control unit, interfacing with the rain sensor to detect moisture levels and controlling the servo motor based on the sensor's readings.
Component List
Arduino Nano
- Description: A small, complete, and breadboard-friendly board based on the ATmega328P.
- Pins: D1/TX, D0/RX, RESET, GND, D2, D3, D4, D5, D6, D7, D8, D9, D10, D11/MOSI, D12/MISO, VIN, 5V, A7, A6, A5, A4, A3, A2, A1, A0, AREF, 3V3, D13/SCK
Tower Pro SG90 Servo
- Description: A micro servo motor commonly used in robotics and hobby projects.
- Pins: Signal, +5V, GND
Rain Sensor
- Description: A sensor used to detect the presence of rain or water.
- Pins: AO, DO, GRD, VCC
Wiring Details
Arduino Nano
- GND: Connected to GND of the Rain Sensor and GND of the Tower Pro SG90 Servo.
- D2: Connected to DO of the Rain Sensor.
- D9: Connected to Signal of the Tower Pro SG90 Servo.
- 5V: Connected to VCC of the Rain Sensor and +5V of the Tower Pro SG90 Servo.
Tower Pro SG90 Servo
- Signal: Connected to D9 of the Arduino Nano.
- +5V: Connected to 5V of the Arduino Nano.
- GND: Connected to GND of the Arduino Nano.
Rain Sensor
- GRD: Connected to GND of the Arduino Nano.
- DO: Connected to D2 of the Arduino Nano.
- VCC: Connected to 5V of the Arduino Nano.
Code Documentation
Arduino Nano Code
void setup() {
// put your setup code here, to run once:
}
void loop() {
// put your main code here, to run repeatedly:
}
This code is a basic template for the Arduino Nano. The setup() function is where you initialize your components and settings, and the loop() function is where the main logic of your program runs repeatedly.
Additional Documentation
This section is reserved for any additional documentation or notes related to the code or circuit. Currently, it is empty.
