Building the Picar for my undergraduate project was a fun experience. It involved learning about electrical connections, reading the documentation of various parts, soldering, cutting and a lot of trial and error. The whole process took almost a month as I had to research about the parts, and order them online.
The first thing I need was a body for the car, I was looking for something that was big enough to fit a Raspberry Pi 3. Then I found this cool looking toy car from Amazon.
Controlling the motors
I opened the toy car to find a small motor controller which controls the three motors. One for each set of wheels and one to control the direction of the car. But I wanted to control the car from a Raspberry Pi and it was pretty hard to find the input signals that control the cars inbuild controller. So went online to find a motor controller that could power the motors. I found the L298 Motor Driver Module as a pretty good choice for the project. The motor driver module can be used to power two different motors at the same time and I used it to control the front and rear motors.
L298 Motor driver connected to the front and rear motors.
The direction control that came with the car can only do max left or max right, there was no in-between option. To allow for more granular control I opted for a servo motor that can be controlled by the PWM signals produced by the Raspberry Pi.
TowerPro MG995 Metal Gear Servo Motor to control steering
All the motors are controlled by a 4 cell battery that was already in the car. The battery powers the Motor controller, the front and rear motors and the servo motor.
Connection diagram for the driving system
The parts list:
- An RC car model
- L298 Motor Driver Module
- Servo motor
- Wires, connectors, tape, glue, solder iron etc.