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

Raspberry Pi 4B Controlled E-Bike with GPS and Ultrasonic Sensors

View and Edit Project In Cirkit DesignerImage of Raspberry Pi 4B Controlled E-Bike with GPS and Ultrasonic Sensors

Circuit Documentation

Summary

This circuit integrates a Raspberry Pi 4B with various peripherals including a GPS module (GPS NEO 6M), multiple HC-SR04 ultrasonic sensors, an Adafruit Mini Analog Thumbstick, two 24V e-bike DC motors, and a Cytron motor driver (MDDS30). The system is powered by a series of 12V 200Ah batteries, and a step-down module is used to convert the voltage to appropriate levels for the components requiring 5V. The Raspberry Pi 4B serves as the central processing unit, interfacing with the GPS module for location tracking and controlling the ultrasonic sensors for distance measurement. The motor driver is responsible for controlling the e-bike motors based on input from the Raspberry Pi 4B.

Component List

Raspberry Pi 4B

GPS NEO 6M

HC-SR04 Ultrasonic Sensor

24V e-bike DC Motor

12V 200Ah Battery

MDDS30 A Cytron Motor Driver

Step-down Module

Adafruit Mini Analog Thumbstick

Wiring Details

Raspberry Pi 4B

GPS NEO 6M

HC-SR04 Ultrasonic Sensor

24V e-bike DC Motor

12V 200Ah Battery

MDDS30 A Cytron Motor Driver

Step-down Module

Adafruit Mini Analog Thumbstick

Documented Code

Raspberry Pi 4B Code (sketch.ino)

void setup() {
  // put your setup code here, to run once:

}

void loop() {
  // put your main code here, to run repeatedly:

}

Step-down Module Code (sketch.ino)

void setup() {
  // put your setup code here, to run once:

}

void loop() {
  // put your main code here, to run repeatedly:

}

(Note: The provided code for both the Raspberry Pi 4B and the Step-down Module is a template with no specific functionality. Additional code is required to control the peripherals and implement the desired behavior of the circuit.)