top of page

PROJECT PHASE 2

LESSONS LEARNED

  • The first thing I learned through this assignment was that four DC motors could be meagered together and controlled by a single L298N motor driver.

  • The next thing I learn through this project is that these same four DC motors can be powered by a single battery pack and two 3.7V, 18650 batteries.

  • Another thing I learned was how to format a Python code that would allows users to control multiple DC motors and their directions through Blynk.

  • The next thing I learned was how to utilize a slider widget in blynk in order to control a servo motor and its change of angle.

  • Another thing that I learned was that ASA filament does not print as clean or accurate as PLA.

  • The next thing I learned was how to combine multiple separate files of python code in order to control multiple sensors with one file.

  • The last thing I learned was how to call and run multiple different python code files simultaneously from a single master script

3D MODELING

3D Model for the Base of the Chassis

Robotchassis2.JPG
RobotChassis.JPG

3D Model for the Top of the Chassis

top1.JPG
top2.JPG

3D Model for Servo Motor and Camera Mount

Cameraassembly.JPG
cameramountbase.JPG
cameramount1.JPG

3D Model for the Base of the Chassis w/ DC Motors and Ultrasonic Sensor

RobotNoBat2.JPG
RobotNoBat.JPG

3D Model for the Base of the Chassis w/ All Components

robotwithcomp2.JPG
robotwithcomp.JPG

3D Model for Robot w/ All Components and Top

Robotchassistop.JPG
Robotchassistop2.JPG

3D Model for Robot w/ All Components, Top and Camera System

finalphase2.JPG
Phase 2 final.JPG

DC MOTOR DIRECTIONAL TEST

At this point in the project I decided to utilize LimitOS in order to test which way the motors would spin when positioned in the desired orientation. Doing this allowed me to pair motors together that will spin in the same direction, effectively only having to code for "two" motor directions down the line. 

Schematic

4WD.JPG

Physical Circuit

IMG_0563.jpg

Test Video

ROBOT 3D PRINTS

Physical 3D Print for the Chassis Base

IMG_0572.jpg
IMG_0575.jpg

Physical 3D Print for the Chassis Top

IMG_0597 (2).jpg
IMG_0598 (1).jpg

Physical 3D Print for the Servo Motor and Camera Mount

IMG_0605.jpg
IMG_0612.jpg

PHYSICAL ASSEMBLY

IMG_0578.jpg
IMG_0579.jpg
IMG_0580.jpg
IMG_0581.jpg
IMG_0582.jpg
IMG_0600.jpg
IMG_0605.jpg
IMG_0619.jpg
IMG_0618.jpg

DC MOTOR CONTROL
(PYTHON+BLYNK)

Blynk Setup

IMG_0585.PNG

Schematic

4WD.JPG

Physical Circuit

IMG_0563.jpg

Python Code

DCmotorcode1.JPG
DCmotorcode2.JPG

Test Video

ULTRASONIC SENSOR CONTROL
(PYTHON+BLYNK)

Blynk Setup

IMG_0502.PNG
IMG_0501.PNG

Schematic

USschem.JPG

Physical Circuit

IMG_0500.jpg

Python Code (Gathered from Dr. Fagan's Example Code)

uscodee.JPG

Test Video

DC MOTOR AND ULTRASONIC SENSOR CONTROL 
(PYTHON+BLYNK)

Blynk Setup

Screenshot 2021-07-20 at 5.47.21 PM.png

Schematic

US4x4.JPG

Physical Circuit

IMG_0596 (1).jpg

Python Code

phase21.JPG
phase22.JPG
phas23.JPG

Test Video

CAMERA FEED AND HORIZONTAL SERVO PAN
(PYTHON+BLYNK)

Blynk Setup

Screenshot 2021-07-22 at 8.21.17 PM.png
Screenshot 2021-07-22 at 8.21.58 PM.png

Schematic

panningcamera.JPG

Physical Circuit

IMG_0604.jpg

Python Code

The code shown below ("MasterCode") runs the two python scripts responsible for servo pan control as well as the Raspberry Pi's camera livestream simultaneously.

Mastercode.JPG

The code shown below ("ServoPan") controls the degree at which the servo, and therefor the camera, is rotated.

servopan.JPG

The code shown below ("Video") controls the camera and creates a livestream that can be then viewed from blynk. The issue with this strategy is the significant stream lag.

video.JPG
video2.JPG

Test Video

PHASE 2: FINAL ROBOT
(PYTHON+BLYNK)

Blynk Setup

IMG_0501.PNG
IMG_0603.PNG
Screenshot 2021-07-22 at 8.21.58 PM.png

Schematic

Phase 2.JPG

Physical Circuit

IMG_0615.jpg

Python Code

The code shown below ("Phase2MasterCode") runs the two python scripts responsible for full robot control as well as the Raspberry Pi's camera livestream simultaneously.

Phase2MasterCode.JPG

The code shown below ("Phase2Final") is responsible for full control over the robot. This includes control over the dc motors, distance monitoring with the ultrasonic sensor and finally camera panning with a servo motor

Phase2Final1.JPG
Phase2Final2.JPG
Phase2Final3.JPG

Final Product Video

SOURCES

© 2023 by Joseph Petite. Proudly created with Wix.com

bottom of page