{"id":68,"date":"2018-12-07T17:41:00","date_gmt":"2018-12-07T09:41:00","guid":{"rendered":"https:\/\/www.aitwg.com\/?p=68"},"modified":"2025-03-23T15:38:21","modified_gmt":"2025-03-23T07:38:21","slug":"esp-bluetooth-wifi-car","status":"publish","type":"post","link":"https:\/\/www.aitwg.com\/?p=68","title":{"rendered":"ESP Bluetooth\/WiFi Car"},"content":{"rendered":"<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/docs\/wifi_bt_car.jpg\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/docs\/wifi_bt_car.jpg\" alt=\"\" style=\"width:487px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n\n<h2 class=\"wp-block-heading\">All in one RC Car with WiFi and Bluetooth, and OLED (optional)<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/yckao1221\/ESPCode#all-in-one-rc-car-with-wifi-and-bluetooth-and-oled-optional\"><\/a>Most of remote control Robot Cars use WiFi or Bluetooth protocol only. Thanks for ESP32-CAM, we could build RC robot with Camera with both WiFi and Bluetooth protocol.<\/p>\n\n\n\n<!--more-->\n\n\n\n<p>ESP32-CAM Car<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>build the wifi car<\/li>\n\n\n\n<li>develop the HTTP server with streaming video &amp; motor control<\/li>\n\n\n\n<li>develop the Bluetooth command<\/li>\n\n\n\n<li>develop the mobile application<\/li>\n<\/ul>\n\n\n\n<p>ESP32 Car (w\/o CAM)<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>build the wifi car<\/li>\n\n\n\n<li>develop the HTTP server with streaming video &amp; motor control<\/li>\n\n\n\n<li>develop the mobile application<\/li>\n<\/ul>\n\n\n\n<p>ESP8266 Car (w\/o CAM &amp; Bluetooth)<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>build the wifi car<\/li>\n\n\n\n<li>develop the HTTP server with streaming video &amp; motor control<\/li>\n\n\n\n<li>develop the Bluetooth command<\/li>\n\n\n\n<li>develop the mobile application<\/li>\n<\/ul>\n\n\n\n<h2 class=\"wp-block-heading\">Youtube Video<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/yckao1221\/ESPCode#youtube-video\"><\/a><\/p>\n\n\n\n<figure class=\"wp-block-image is-resized\"><a href=\"https:\/\/www.youtube.com\/watch?v=OzC1y5DCzQk\"><img decoding=\"async\" src=\"https:\/\/camo.githubusercontent.com\/8ca9fd4e16101ace7b6e4fa4ffc10910653061d515b1aa684cefe56790324d0e\/68747470733a2f2f696d672e796f75747562652e636f6d2f76692f4f7a4331793544437a516b2f302e6a7067\" alt=\"IMAGE ALT TEXT HERE\" style=\"width:578px;height:auto\"\/><\/a><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">ESP WiFi\/Bluetooth RC CAM CAR (Free No ADs)<a href=\"https:\/\/github.com\/yckao1221\/ESPCode#esp-wifibluetooth-rc-cam-car-free-no-ads\"><\/a><\/h2>\n\n\n\n<figure class=\"wp-block-image is-resized\"><a href=\"https:\/\/play.google.com\/store\/apps\/details?id=com.ieeelab.bluetoothrc\"><img decoding=\"async\" src=\"https:\/\/camo.githubusercontent.com\/1c498046b5901ad8edbda2642aac002794df0c6f17aac9787f648bf776912914\/68747470733a2f2f706c61792e676f6f676c652e636f6d2f696e746c2f656e5f75732f6261646765732f696d616765732f67656e657269632f656e5f62616467655f7765625f67656e657269632e706e67\" alt=\"Download from Google Play\" style=\"width:304px;height:auto\"\/><\/a><\/figure>\n\n\n\n<h2 class=\"wp-block-heading\">How it works<a href=\"https:\/\/github.com\/yckao1221\/ESPCode#how-it-works\"><\/a><\/h2>\n\n\n\n<p>We are using HTTP protocol and Bluetooth Serial port command.<\/p>\n\n\n\n<p>For Bluetooth, it&#8217;s ESP32 only. We use Bluetooth Serial to control the car.<\/p>\n\n\n\n<p>For WiFi, The server is the ESP32\/ESP8266 and the client is the smartphone. The client will send HTTP requests to the server in order to control the car.<\/p>\n\n\n\n<p>ESP32\/ESP8266 chip is able to create its own WIFI network (Access Point mode = AP) or to connect to an existing wifi network (Station Mode = STA).<\/p>\n\n\n\n<p>The smartphone must be connected to the same wifi network as the chip and know its ip address and the port of its server. To make it easier, I also use an OLED display to show current IP address on the display.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Build your own wifi car<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/yckao1221\/ESPCode#build-your-own-wifi-car\"><\/a><\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>ESP32-CAM \/ ESP32 DevKit \/ ESP8266<\/li>\n\n\n\n<li>L9110s motor driver or L293D\/L298N<\/li>\n\n\n\n<li>USB PowerBank or other Power source such as 18650&#215;2.<\/li>\n<\/ul>\n\n\n\n<p>You cound find car kit to assemble your car such as.<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li><a href=\"https:\/\/shopee.tw\/%E9%8B%81%E5%90%88%E9%87%91%E5%B0%8F%E8%BB%8A-%E6%A9%9F%E5%99%A8%E4%BA%BA%E5%B0%8F%E8%BB%8A-%E6%99%BA%E8%83%BD%E5%B0%8F%E8%BB%8A%E5%BA%95%E7%9B%A4%E5%90%88%E9%87%91%E5%BA%95%E7%9B%A4-2%E8%BC%AA%E5%B0%8F%E8%BB%8ADIY%E6%96%B0%E6%AC%BEA30-i.59477120.3757226429\">Car Kit#1<\/a><\/li>\n<\/ul>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/docs\/carkit.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/docs\/carkit.png\" alt=\"\" style=\"width:457px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n\n<p>*<a href=\"https:\/\/shopee.tw\/-RWG-Arduino-%E8%87%AA%E8%B5%B0%E8%BB%8A-%E5%BE%AA%E8%B7%A1%E8%BB%8A-%E9%81%BF%E9%9A%9C%E8%BB%8A-%E5%B0%8F%E8%BB%8A%E5%BA%95%E7%9B%A4-i.14363185.2341583690\">Car Kit#2<\/a><\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/docs\/carkit2.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/docs\/carkit2.png\" alt=\"\"\/><\/a><\/figure>\n<\/div>\n\n\n<p>*<a href=\"https:\/\/www.amazon.com\/perseids-Chassis-Encoder-Wheels-Battery\/dp\/B07DNYQ3PX\/ref=sr_1_21?dchild=1&amp;keywords=WIFI+Smart+Robot+Car+With+NodeMCU&amp;qid=1624955907&amp;s=toys-and-games&amp;sr=1-21\">Amazon(Car Kit#3)<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\">Android application settings for WiFi and Bluetooth Command<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/yckao1221\/ESPCode#android-application-settings-for-wifi-and-bluetooth-command\"><\/a><\/p>\n\n\n\n<p>You can customize all the commands with Android Apps. The apps support both WiFi comand and Bluetooth Command. You could switch between WiFi mode and Bluetooth mode via Android app.<\/p>\n\n\n\n<p>To control RC car with WiFi, you must connect your smartphone to the same wifi network as your wifi car. Make sure that the application parameters are correct (IP, PORT, etc..).<\/p>\n\n\n\n<p>To control RC car with Bluetooth, you must pair the car with it&#8217;s Bluetooth name, and then connect on it.<\/p>\n\n\n\n<p>The defaults commands sent are:<\/p>\n\n\n\n<p>Live Camera URL : (port = http port(80) +1)<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>CAM URL: http:\/\/192.168.4.1:81\/stream\n<\/code><\/pre>\n\n\n\n<p>Besides Robot CAM Car URL, since it&#8217;s WebView browser, you could assign any public IP CAM URL such as.<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/docs\/ipcam01.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/docs\/ipcam01.png\" alt=\"\" style=\"width:261px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/docs\/ipcam02.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/docs\/ipcam02.png\" alt=\"\" style=\"width:262px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n\n<p>HTTP Command<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>GET - http:\/\/192.168.4.1:80\/state?cmd=F (forward)\nGET - http:\/\/192.168.4.1:80\/state?cmd=B (backward)\nGET - http:\/\/192.168.4.1:80\/state?cmd=R (right)\nGET - http:\/\/192.168.4.1:80\/state?cmd=L (left)\nGET - http:\/\/192.168.4.1:80\/state?cmd=S (stop)\n<\/code><\/pre>\n\n\n\n<p>Bluetooth Serial Comand<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>cmd 'L' : MotorLeft()  (Left)\ncmd 'R' : MotorRight() (Right)\ncmd 'F' : MotorUp()    (Forward)\ncmd 'B' : MotorDown()  (Backword)\ncmd 'X' : MotorStop()  (Stop)\n<\/code><\/pre>\n\n\n\n<p>Android:<\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_01.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_01.png\" alt=\"\" style=\"width:320px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_02.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_02.png\" alt=\"\" style=\"width:320px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_01.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_01.png\" alt=\"\" style=\"width:319px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_04.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_04.png\" alt=\"\" style=\"width:318px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_05.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/ESP32_CAM_Car_GPIO\/2021-06-25_05.png\" alt=\"\" style=\"width:318px;height:auto\"\/><\/a><\/figure>\n<\/div>\n\n\n<h2 class=\"wp-block-heading\">ESP32-CAM Reference design<\/h2>\n\n\n\n<p><a href=\"https:\/\/github.com\/yckao1221\/ESPCode#esp32-cam-reference-design\"><\/a><\/p>\n\n\n<div class=\"wp-block-image\">\n<figure class=\"aligncenter is-resized\"><a href=\"https:\/\/github.com\/yckao1221\/ESPCode\/blob\/main\/docs\/cardesign.png\" target=\"_blank\" rel=\"noreferrer noopener\"><img decoding=\"async\" src=\"https:\/\/github.com\/yckao1221\/ESPCode\/raw\/main\/docs\/cardesign.png\" alt=\"\" style=\"width:762px;height:auto\"\/><\/a><\/figure>\n<\/div>","protected":false},"excerpt":{"rendered":"<p>All in one RC Car with WiFi and Bluetooth, and OLED (op&hellip;&nbsp;<a href=\"https:\/\/www.aitwg.com\/?p=68\" rel=\"bookmark\"><span class=\"screen-reader-text\">ESP Bluetooth\/WiFi Car<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"neve_meta_sidebar":"","neve_meta_container":"","neve_meta_enable_content_width":"","neve_meta_content_width":0,"neve_meta_title_alignment":"","neve_meta_author_avatar":"","neve_post_elements_order":"","neve_meta_disable_header":"","neve_meta_disable_footer":"","neve_meta_disable_title":"","footnotes":""},"categories":[2,5],"tags":[],"class_list":["post-68","post","type-post","status-publish","format-standard","hentry","category-maker","category-5"],"_links":{"self":[{"href":"https:\/\/www.aitwg.com\/index.php?rest_route=\/wp\/v2\/posts\/68","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.aitwg.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.aitwg.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.aitwg.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.aitwg.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=68"}],"version-history":[{"count":1,"href":"https:\/\/www.aitwg.com\/index.php?rest_route=\/wp\/v2\/posts\/68\/revisions"}],"predecessor-version":[{"id":194,"href":"https:\/\/www.aitwg.com\/index.php?rest_route=\/wp\/v2\/posts\/68\/revisions\/194"}],"wp:attachment":[{"href":"https:\/\/www.aitwg.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=68"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.aitwg.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=68"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.aitwg.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=68"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}