{"id":4844,"date":"2026-05-06T08:19:40","date_gmt":"2026-05-06T15:19:40","guid":{"rendered":"https:\/\/www.donluc.com\/?p=4844"},"modified":"2026-05-06T08:19:40","modified_gmt":"2026-05-06T15:19:40","slug":"project-12-robotics-arduino-robot-car-2wd-mk38","status":"publish","type":"post","link":"https:\/\/www.donluc.com\/?p=4844","title":{"rendered":"Project #12: Robotics &#8211; Arduino Robot Car 2WD &#8211; Mk38"},"content":{"rendered":"<div style=\"width: 1200px;\" class=\"wp-video\"><video class=\"wp-video-shortcode\" id=\"video-4844-1\" width=\"1200\" height=\"675\" preload=\"metadata\" controls=\"controls\"><source type=\"video\/mp4\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06W.mp4?_=1\" \/><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06W.mp4\">https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06W.mp4<\/a><\/video><\/div>\n<p>&#8212;&#8212;<\/p>\n<p>#DonLucElectronics #DonLuc #Robotics #BLE #L298N #MotorDC #ArduinoUNOR4  #Project #Fritzing #Programming #Electronics #Microcontrollers #Consultant<\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06a.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06a.jpg\" alt=\"Arduino Robot Car 2WD\" width=\"720\" height=\"721\" class=\"alignnone size-full wp-image-4846\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06a.jpg 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06a-300x300.jpg 300w, https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06a-150x150.jpg 150w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;-<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06b.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06b.jpg\" alt=\"Arduino Robot Car 2WD\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-4847\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06b.jpg 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06b-300x200.jpg 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><a href=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06c.jpg\"><img loading=\"lazy\" decoding=\"async\" src=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06c.jpg\" alt=\"Arduino Robot Car 2WD\" width=\"720\" height=\"480\" class=\"alignnone size-full wp-image-4848\" srcset=\"https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06c.jpg 720w, https:\/\/www.donluc.com\/wp-content\/uploads\/2026\/05\/DL2603Mk06c-300x200.jpg 300w\" sizes=\"auto, (max-width: 720px) 100vw, 720px\" \/><\/a><\/p>\n<p>&#8212;&#8212;<\/p>\n<p><strong>Arduino Robot Car 2WD<\/strong><\/p>\n<p>An Arduino Robot Car is a mobile robotic platform controlled by an Arduino microcontroller. The basic architecture consists of a chassis, DC motors for propulsion, a motor driver for controlling those motors, power supply, sensors for environment awareness, and the Arduino brain coordinating everything.<\/p>\n<p>Two-wheel drive robots use two powered wheels at the rear with a ball caster or swivel wheel at the front for balance. This differential drive system allows precise turn in each wheel can rotate independently at different speeds or even in opposite directions, enabling the robot to spin in place. The simplicity means fewer motors to control, less current draw, and easier programming.<\/p>\n<p><strong>DL2603Mk06<\/strong><\/p>\n<p>1 x Arduino UNO R4 WiFi<br \/>\n1 x L298N DC Motor Driver Module<br \/>\n2 x Motor DC<br \/>\n1 x Power Switch<br \/>\n1 x 4 AA Battery Holder (5.5 Volts)<br \/>\n4 x AA Battery<br \/>\n1 x USB 3.0 to Type-C Cable<br \/>\n1 x Car<\/p>\n<p><strong>DL2603Mk06p<\/strong><\/p>\n<p><strong>DL2603Mk06p.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/****** Don Luc Electronics \u00a9 ******\r\nSoftware Version Information\r\nProject #12: Robotics - Arduino Robot Car 2WD - Mk38\r\n12-38\r\nDL2603Mk06p.ino\r\nDL2603Mk06\r\n1 x Arduino UNO R4 WiFi\r\n1 x L298N DC Motor Driver Module\r\n2 x Motor DC\r\n1 x Power Switch\r\n1 x AA Battery Holder (5.5 Volts)\r\n3 x AA Battery\r\n1 x Micro USB Cable\r\n1 x Car\r\n*\/\r\n\r\n\/\/ Include the Library Code\r\n\/\/ LED_Matrix library\r\n#include &quot;Arduino_LED_Matrix.h&quot; \r\n\/\/ Arduino BLE\r\n#include &lt;ArduinoBLE.h&gt;\r\n\r\n\/\/ Arduino UNO R4 WiFi\r\n\/\/ Car Service\r\nBLEService carService(&quot;546b10ec-9c23-4f5e-ab33-cd415313439f&quot;);\r\n\/\/ Command Char\r\nBLECharacteristic commandChar(&quot;c607bca7-4832-4032-a0ab-e9c180dcce1e&quot;, BLEWrite, 20);\r\n\r\n\/\/ Create an instance of the ArduinoLEDMatrix class\r\nArduinoLEDMatrix matrix;\r\n\r\n\/\/ Motor DC 1 \r\nint motor1pin1 = 2;\r\nint motor1pin2 = 3;\r\n\r\n\/\/ Motor DC 2\r\nint motor2pin1 = 4;\r\nint motor2pin2 = 5;\r\n\r\n\/\/ CMD\r\nchar cmd;\r\n\r\n\/\/ Software Version Information\r\nString sver = &quot;12-36&quot;;\r\n\r\nvoid loop() {\r\n\r\n  \/\/ BLE Device Central\r\n  BLEDevice central = BLE.central();\r\n  \/\/ Central\r\n  if (central) {\r\n    \r\n    \/\/ Connected\r\n    while (central.connected()) {\r\n\r\n      \/\/ Written\r\n      if (commandChar.written()) {\r\n\r\n        \/\/ CMD\r\n        cmd = commandChar.value()[0];\r\n       \r\n        \/\/ Drive\r\n        drive(cmd);\r\n\r\n      }\r\n\r\n    }\r\n\r\n  }\r\n\r\n}\r\n<\/pre>\n<p><strong>getDrive.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/\/ Drive\r\nvoid drive(char cmd) {\r\n  \/\/ Forward\r\n       if (cmd == &#039;F&#039;) { forward();  }  \r\n    \/\/ Backward\r\n  else if (cmd == &#039;B&#039;) { backward(); }  \r\n  \/\/ Left\r\n  else if (cmd == &#039;L&#039;) { left(); } \r\n  \/\/ Right     \r\n  else if (cmd == &#039;R&#039;) { right(); }\r\n  \/\/ Spin\r\n  else if (cmd == &#039;O&#039;) { spin(); } \r\n  \/\/ Stop\r\n  else { stopCar(); }\r\n}\r\n\r\n\/\/ Forward\r\nvoid forward()  { digitalWrite(motor1pin1, LOW);  digitalWrite(motor1pin2, HIGH); digitalWrite(motor2pin1, HIGH); digitalWrite(motor2pin2, LOW); }\r\n\/\/ Backward\r\nvoid backward() { digitalWrite(motor1pin1, HIGH); digitalWrite(motor1pin2, LOW);  digitalWrite(motor2pin1, LOW);  digitalWrite(motor2pin2,HIGH); }\r\n\/\/ Left\r\nvoid left()     { digitalWrite(motor1pin1, LOW);  digitalWrite(motor1pin2, HIGH); digitalWrite(motor2pin1, LOW);  digitalWrite(motor2pin2, LOW); }\r\n\/\/ Right\r\nvoid right()    { digitalWrite(motor1pin1, LOW);  digitalWrite(motor1pin2, LOW);  digitalWrite(motor2pin1, HIGH); digitalWrite(motor2pin2, LOW); }\r\n\/\/ Spin\r\nvoid spin()     { digitalWrite(motor1pin1, HIGH); digitalWrite(motor1pin2, LOW);  digitalWrite(motor2pin1, HIGH); digitalWrite(motor2pin2, LOW); }\r\n\/\/ Stop\r\nvoid stopCar()  { digitalWrite(motor1pin1, LOW);  digitalWrite(motor1pin2, LOW);  digitalWrite(motor2pin1, LOW);  digitalWrite(motor2pin2, LOW); }\r\n\r\n<\/pre>\n<p><strong>setup.ino<\/strong><\/p>\n<pre class=\"EnlighterJSRAW\" data-enlighter-language=\"arduino\" data-enlighter-title=\"\">\r\n\/\/ Setup\r\nvoid setup()\r\n{\r\n \r\n  \/\/ Initialize the LED matrix\r\n  matrix.begin();\r\n\r\n  \/\/ Load and display the basic emoji frame on the LED matrix\r\n  matrix.loadFrame(LEDMATRIX_UNO);\r\n  \r\n  \/\/ Motor DC 1\r\n  pinMode(motor1pin1, OUTPUT);\r\n  pinMode(motor1pin2, OUTPUT);\r\n\r\n  \/\/ Motor DC 2\r\n  pinMode(motor2pin1, OUTPUT);\r\n  pinMode(motor2pin2, OUTPUT);\r\n\r\n  \/\/ Serial Begin\r\n  Serial.begin(9600);\r\n  \r\n  \/\/ BLE Begin\r\n  if (!BLE.begin()) {\r\n    \r\n    while (1);\r\n\r\n  }\r\n\r\n  \/\/ Name\r\n  BLE.setLocalName(&quot;UnoR4Car&quot;);\r\n  \/\/ Advertised Service\r\n  BLE.setAdvertisedService(carService);\r\n  \/\/ Characteristic\r\n  carService.addCharacteristic(commandChar);\r\n  \/\/ Service\r\n  BLE.addService(carService);\r\n  \/\/ Advertise\r\n  BLE.advertise();\r\n\r\n}\r\n<\/pre>\n<p>&#8212;&#8212;<\/p>\n<p><strong>People can contact us:<\/strong> https:\/\/www.donluc.com\/?page_id=1927<\/p>\n<p><strong>Consultant, R&#038;D, Electronics, IoT, Teacher and Instructor<\/strong><\/p>\n<ul>\n<li>Programming Language<\/li>\n<li>Single-Board Microcontrollers (PIC, Arduino, Raspberry Pi, Arm, Silicon Labs, Espressif, Etc&#8230;)<\/li>\n<li>IoT<\/li>\n<li>Wireless (Radio Frequency, Bluetooth, WiFi, Etc&#8230;)<\/li>\n<li>Robotics<\/li>\n<li>Automation<\/li>\n<li>Camera and Video Capture Receiver Stationary, Wheel\/Tank , Underwater and UAV Vehicle<\/li>\n<li>Unmanned Vehicles Terrestrial,  Marine and UAV<\/li>\n<li>Machine Learning<\/li>\n<li>Artificial Intelligence (AI)<\/li>\n<li>RTOS<\/li>\n<li>Sensors, eHealth Sensors, Biosensor, and Biometric<\/li>\n<li>Research &#038; Development (R &#038; D)<\/li>\n<li>Consulting<\/li>\n<\/ul>\n<p><strong>Follow Us<\/strong><\/p>\n<p><strong>Luc Paquin \u2013 Curriculum Vitae &#8211; 2026<\/strong><br \/>\nhttps:\/\/www.donluc.com\/luc\/LucPaquinCVEng2026Mk01.pdf<br \/>\nhttps:\/\/www.donluc.com\/luc\/<\/p>\n<p><strong>Web:<\/strong> https:\/\/www.donluc.com\/<br \/>\n<strong>Web:<\/strong> https:\/\/www.jlpconsultants.com\/<br \/>\n<strong>Facebook:<\/strong> https:\/\/www.facebook.com\/neosteam.labs.9\/<br \/>\n<strong>YouTube:<\/strong> https:\/\/www.youtube.com\/@thesass2063<br \/>\n<strong>DFRobot:<\/strong> https:\/\/learn.dfrobot.com\/user-10186.html<br \/>\n<strong>Elecrow:<\/strong> https:\/\/www.elecrow.com\/share\/sharepj\/center\/no\/760816d385ebb1edc0732fd873bfbf13<br \/>\n<strong>TikTok:<\/strong> https:\/\/www.tiktok.com\/@luc.paquin8<br \/>\n<strong>Hackster:<\/strong> https:\/\/www.hackster.io\/luc-paquin<br \/>\n<strong>LinkedIn:<\/strong> https:\/\/www.linkedin.com\/in\/jlucpaquin\/<\/p>\n<p><strong>Don Luc<\/strong><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&#8212;&#8212; #DonLucElectronics #DonLuc #Robotics #BLE #L298N #MotorDC #ArduinoUNOR4 #Project #Fritzing #Programming #Electronics #Microcontrollers #Consultant &#8212;&#8212; &#8212;&#8212;- &#8212;&#8212; &#8212;&#8212; Arduino Robot Car 2WD An Arduino Robot Car is a mobile robotic platform controlled by an Arduino microcontroller. The basic architecture consists of a chassis, DC motors for propulsion, a motor driver for controlling those motors, power &#8230; <a title=\"Project #12: Robotics &#8211; Arduino Robot Car 2WD &#8211; Mk38\" class=\"read-more\" href=\"https:\/\/www.donluc.com\/?p=4844\" aria-label=\"Read more about Project #12: Robotics &#8211; Arduino Robot Car 2WD &#8211; Mk38\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[94,397,50,49,38,80,59,115,5,287,416],"tags":[6,423,92,242,102,4,19,83,85,24,9,84,27,95,33,34,108],"class_list":["post-4844","post","type-post","status-publish","format-standard","hentry","category-robotics-projerts","category-arduino-digitalelectronics","category-arduino","category-consultant","category-digitalelectronics","category-esp32","category-fritzing","category-e-mentor","category-microcontrollers","category-program","category-unit","tag-arduino","tag-arduino-robot-car-2wd","tag-battery","tag-bluetooth","tag-components","tag-consultant","tag-electronics","tag-esp32","tag-fritzing","tag-microcontroller","tag-programming","tag-programming-esp32","tag-projects-2","tag-robotic","tag-technology","tag-video-blog","tag-vlog"],"_links":{"self":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/4844","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=4844"}],"version-history":[{"count":1,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/4844\/revisions"}],"predecessor-version":[{"id":4849,"href":"https:\/\/www.donluc.com\/index.php?rest_route=\/wp\/v2\/posts\/4844\/revisions\/4849"}],"wp:attachment":[{"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=4844"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=4844"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.donluc.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=4844"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}