Differences

This shows you the differences between two versions of the page.

Link to this comparison view

pm:prj2022:agmocanu:rc_car_with_camera [2022/05/25 23:35]
george_codrin.preda
pm:prj2022:agmocanu:rc_car_with_camera [2022/05/27 23:03] (current)
george_codrin.preda
Line 5: Line 5:
  
 Résumé: Résumé:
-The project is inspired by the Curiosity Mars rover and the growing need for remote controlled surveillance devices. From bomb disposal robots to Mars rovers, we need robots that we can send on risky missions instead of humans. A robot does not need food or sleep and it can do many things that a human cannot : it can withstand harsh conditions such as extreme temperatures or high levels of radiation.+The project is inspired by the Curiosity Mars rover and the growing need for remote-controlled surveillance devices. From bomb disposal robots to Mars rovers, we need robots that we can send on risky missions instead of humans. A robot does not need food or sleep and it can do many things that a human cannot: it can withstand harsh conditions such as extreme temperatures or high levels of radiation.
  
 {{curiosity1.jpg?​500|}} {{curiosity1.jpg?​500|}}
  
 ===== General description ​ ===== ===== General description ​ =====
-The car is built using a robot car kit with 4 motors,4 wheels and connectors,​an ESP32 cam module,L298N motor driver module, 8x1.5V batteries and  the supports for the batteries, double sided tape, jumper wires and female to male and female to female wires. After assembling everything according to the diagram below, I took the ESP32 cam module out and assembled a circuit for the code upload using a breadboard, an arduino uno and a few jumper wires, the diagram for the code upload is below, in the Hardware Design section. After   +The car is built using a robot car kit with 4 motors,4 wheels and connectors, an ESP32 cam module, ​an L298N motor driver module, 8x1.5V batteriesand the supports for the batteries, double-sided tape, jumper wiresand female to male and female to female wires. After assembling everything according to the diagram below, I took the ESP32 cam module out and assembled a circuit for the code upload using a breadboard, an Arduino Uno and a few jumper wires, the diagram for the code upload is below, in the Hardware Design section. After   
-reconnecting the ESP32 cam module, I connected the batteries to the car. The car captures video footage using the camera present ​on the car and it sends the footage to my mobile phone using WebSocket through Wi-Fi connection+reconnecting the ESP32 cam module, I connected the batteries to the car. The car captures video footage using the camera present ​in the car and it sends the footage to my mobile phone using WebSocket through ​Wi-Fi connection. The mobile application created can adjust the speed of the car and the light of the flashlight present on the cam module.
  
  
Line 17: Line 17:
  Block scheme:  Block scheme:
    
-{{blockdiagram.jpg.drawio_1_.png}}+{{1.png?500|}}
  
  
 ===== Hardware Design ===== ===== Hardware Design =====
  
-<​note>​+
  ​Components list:  ​Components list:
  
Line 31: Line 31:
   * 2xbattery supports   * 2xbattery supports
   * breadboard   * breadboard
-  * arduino uno+  * Arduino Uno
   * double-sided tape   * double-sided tape
   * jumper wires, female to female wires, female to male wires   * jumper wires, female to female wires, female to male wires
Line 41: Line 41:
 {{rsz_2camera_car.png}} {{rsz_2camera_car.png}}
  
-The code upload ​for the ESP32 cam module ​+The circuit required for the code upload ​on the ESP32 cam module ​
  
 {{codeup.png?​500|}} {{codeup.png?​500|}}
-</​note>​+
  
 ===== Software Design ===== ===== Software Design =====
 +Firstly, the ESP32 board was installed using Arduino Board Manager and the AsyncTCP library was added. In the AsyncWebSocket library folder the I set the WS_MAX_QUEUED_MESSAGES was set to 1 for a smooth stream. In the code, I included the AsyncTCP and ESPAsyncWebServer libraries and I assigned the left and right motor pins. The light pin was also defined and also the channels for speed and light. I added camera-related constants and set a name for the ESP32 Wi-Fi and a password. WebSocket is used for camera and car input control. Then, I created an HTML page for the camera control app. The rotateMotor function takes motorNumber and motorDirection as arguments as it will set the car in forward or backward direction. The moveCar function takes the cases and assigns the movement direction to the rotateMotor function and it moves the car accordingly. The setupCamera function enables the camera. The sendCameraPicture captures the image and sends it to the camera WebSocket client.
  
 +===== Results =====
 +{{car_1.jpeg?​500|}}
 +{{car_2.jpeg?​500|}}
 +{{car_3.jpeg?​500|}}
  
-<​note>​ +Most importantly,​ the car works and runs smoothlyI can follow its stream on my mobile phone and I can adjust the speed and the lightQuickly tapping the light adjusting button makes it flash its headlight just like a car
-Descrierea codului aplicaţiei (firmware):​ +
-  * mediu de dezvoltare (if any) (e.g. AVR Studio, CodeVisionAVR) +
-  * librării şi surse 3rd-party (e.gProcyon AVRlib) +
-  * algoritmi şi structuri pe care plănuiţi să le implementaţi +
-  * (etapa 3) surse şi funcţii implementate +
-</​note>​+
  
-===== Rezultate Obţinute ​=====+===== Conclusions ​=====
  
-<​note>​ +The car moves faster than expected and setting the cam module ​in a position where it has more visibility was tricky. The car-phone connection works as long as I am connected to the wifi connection the ESP32 cam module provides so that I can control the camera from quite a decent distance. Still, more testing needs to be done regarding the maximum distance I can control the car from. The car can run over small obstacles but its nature prevents it from being further tested in an off-road manner. The ESP32 module streams smoothly and the quality of the video is better than the moon landing footage I expected
-Work in progress. +
-</​note>​+
  
-===== Concluzii ===== 
-<​note>​ 
-Work in progress. 
-</​note>​ 
  
 ===== Download ===== ===== Download =====
  
-<note warning>​ +https://​drive.google.com/​drive/​folders/1IWhhHo9ssKpGtshJXIPaGPGebp8l0fNb?​usp=sharing
-Work in progress. +
-</note>+
  
-===== Jurnal =====+https://​github.com/​codrin-preda/​PM-Project-2022/​tree/​main/​PM%20Project%202022
  
-<​note>​ +===== Jurnal and Guide ===== 
-Work in progress+ 
-</​note>​+Modus operandi: 
 +  - assembly car 
 +  - take ESP32 module out  
 +  - connect it to arduino uno via breadboard ​in order to upload the code 
 +  - include the libraries mentioned above and set WS_MAX_QUEUED_MESSAGES to 1 
 +  - upload the code  
 +  - connect ESP32 back to the car  
 +  - connect the power source  
 +  - open up phone 
 +  - connect to ESP32 wifi 
 +  - open 192.168.4.1 in the browser ​ 
 +  - enjoy!
  
 ===== Bibliografie/​Resurse ===== ===== Bibliografie/​Resurse =====
  
-<​note>​ +https://​dev.to/​pawel/​how-to-build-your-own-rc-car-with-arduino-arducar-12ei 
-Work in progress+ 
-</note>+https://​create.arduino.cc/​projecthub/​shubhamsuresh/​how-to-make-a-bluetooth-controlled-rc-car-at-home-521212 
 + 
 +https://​www.instructables.com/​Smartphone-Controlled-RC-Car-Using-Arduino/​ 
 + 
 +https://​techatronic.com/​how-to-make-arduino-bluetooth-rc-car/​ 
 + 
 +https://​create.arduino.cc/​projecthub/​muhammad-aqib/high-speed-arduino-rc-car-5c2a3d
  
 <​html><​a class="​media mediafile mf_pdf"​ href="?​do=export_pdf">​Export to PDF</​a></​html>​ <​html><​a class="​media mediafile mf_pdf"​ href="?​do=export_pdf">​Export to PDF</​a></​html>​
pm/prj2022/agmocanu/rc_car_with_camera.1653510941.txt.gz · Last modified: 2022/05/25 23:35 by george_codrin.preda
CC Attribution-Share Alike 3.0 Unported
www.chimeric.de Valid CSS Driven by DokuWiki do yourself a favour and use a real browser - get firefox!! Recent changes RSS feed Valid XHTML 1.0