Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

Arduino-Controlled Rocket Launcher with Relay and Geared Motor

View and Edit Project In Cirkit DesignerImage of Arduino-Controlled Rocket Launcher with Relay and Geared Motor

Circuit Documentation

Summary

This circuit is designed to control a 12V geared motor using an Arduino UNO microcontroller and a 5V relay. The motor is part of a rocket launcher system, where the activation of the relay causes the rocket to ascend, and deactivation causes it to descend. The system is powered by two 18650 Li-ion batteries connected in series. The Arduino UNO controls the relay through one of its digital pins, and the relay switches the power to the motor from the batteries.

Component List

Arduino UNO

12V Geared Motor

5V Relay

18650 Li-ion Battery x 2

Wiring Details

Arduino UNO

12V Geared Motor

5V Relay

18650 Li-ion Battery x 2

Documented Code

/*
 * Rocket Launcher Control
 * This code controls a relay to manage a 12V geared motor for a rocket launcher.
 * The rocket will ascend when the relay is activated and descend when deactivated.
 * The speed of ascent and descent is controlled by delays.
 */

const int relayPin = 13; // Pin connected to the relay input

void setup() {
  pinMode(relayPin, OUTPUT); // Set relay pin as output
  digitalWrite(relayPin, LOW); // Ensure relay is off initially
}

void loop() {
  // Launch the rocket (activate relay)
  digitalWrite(relayPin, HIGH);
  delay(5000); // Adjust delay for ascent speed

  // Stop the rocket (deactivate relay)
  digitalWrite(relayPin, LOW);
  delay(5000); // Adjust delay for descent speed
}

The code is written for the Arduino UNO and is responsible for controlling the relay that powers the 12V geared motor. The relayPin is set to pin 13, which corresponds to the digital pin D13 on the Arduino UNO. The setup() function initializes this pin as an output and ensures the relay starts in the off position. The loop() function then alternates between turning the relay on and off, with a 5-second delay between each state change, simulating the ascent and descent of the rocket.