Introduction: A Very Cheap ESP8266 WiFi Smart Car Controlled by Phone Based on NodeMCU

DoitCar is designed and developed by Shenzhen Doctors of Intelligence & Technology (SZDOIT), which is the most cost-effective. It is widely applied in many fields, sucha as the electronic lover, college students, Internet of Things (IoT), mobile data collection, etc. DoitCar has a great temptation for the smart car solution.

The DoitCar kit is including the car chassis, 2 pieces of 6V motors, NodeMCU WiFi board, motor driven shield board. Especially, all the codes and hardwares are open for all people. Accordingly, the software collections are including android, Webchat, and internet. The android code is also open for all people to further develop it by your novel idea. DoitCar is controlled by ESP-12E (as the control board) and ESP-12E Motor Shield (as the driven board). For more information about these two boards, please visit http://www.doit.am.   

The develop computer language is Lua for DoitCar with large API encapsulation, which can make users design and exploit their products quickly and conveniently. In addition, DoitCar can be programmed under the condition of Arduino IDE. For more information about DoitCar, please visit http://www.doit.am. Skype: yichone. Email:yichone@doit.am.

Online Documents: http://doit-nodemcu-car.doit.am/

Free get the Android APP source code.

Step 1:

Step 2: Step 1: Installation for This Car Chassis

The installation is very simple and convenient, together with the English installation manual with the order. After installion, the picture is shown as the above picture.

Step 3: Step2: Install the NodeMCU WiFi & Control Development Kit

NodeMCU motor-deriven shield:

ESP-12E Motor Shield is designed and developed by Shenzhen Doctors of Intelligence & Technology (SZDOIT). This large current motor driven module can compatible with ESP12E Dev Kit and NodeMCU.By using the overlap-plug design, the motor shield can be directly plugged by ESP-12E Dev Kit and NodeMCU Lua module.
This shield board is driven by the special excent large power full-bridge chip L293DD from the famous Stmicroelectronics company, which can directly drive 2-channels DC motors or one-channel stepper motor. The driven current can be arrived at 1.2A. This board is generated with national layout, SMT ensuption, and convenient installation. For more details, please visit www.doit.am.

NodeMCU:

ESP-12E is designed and developed by Shenzhen Doctors of Intelligence & Technology (SZDOIT) based on the Ultra-low power consumption UART-WiFi ESP8266, which is specially for mobile devices and application of IoT (Internet of Things). Now, ESP-12E is widely applied to internet, communication in local area, intelligent home, industrial control, handed-devices, and etc.
ESP-12E DevKit is used the design of on-board antenna and encapsulated by 2.54 direct insertion. It is very convenient to debug and install device. In ESP-12E DevKit, Hardware API operation is encapsulated by Lua language, which can avoid the hardware difficulty for sorfware engineers, and then can speed the develop of products. For more details, please visit www.doit.am.

Step 4: Step 3: AP Mode

When get the DoitCar, the default mode is AP. Under this mode, the default SSID name is DoitWiFi, and password is 12345678.

Usage Steps:

(1) Open the power from the smart car;

(2) Search the AP SSID name DoitWiFi, and then connect it;

(3) Open the APP from your phone, if your has no this APP, please download (Android APP) and install it.

(4) After connect successfully, can let car Forward, Back, Stop, Turn Left, Turn Right, Left to Accelerate, and Right to Accelerate, etc.

Step 5: Step 4: STA Mode

The car can by controlled in the remote place with internet.

Under the STA mode, the DoitCar can be controlled by phone APP, WeChat, and page from internet. Note that, if using STA mode, you should firstly download the DoitCarControl.lua (https://github.com/SmartArduino/DoitCar) into the DoitCar. For more details about download methods, please visit the documents on NodeMCU development (). Before download the DoitCarControl.lua into the control-board, you must let the SSID name and password in DoitCarControl.lua same as the ones in your router. In addition, in the DoitCarControl.lua, you should rename the car as the one you like (the default name is car). This name is used as the device name controlled by mobile phone, Wechat, and web-page.

The following Figure is shown that car is controlled by web-page.

Step 6: Step 5: Code Parse

In the site doit, we give the detailed code parse for the DoitCar.

When NodeMCU starts to work, init.lua is used as the entrance of the application. If this file exists, then all the actions can start automatically. Therefore, by this characteristics, some codes can be written here to start automatically.

The code for init. lua is shown as.

1 print("\n")
2 print("ESP8266 Started")

3

4 local exefile="DoitCarControl"

5 local luaFile = {exefile..".lua"}

6 for i, f in ipairs(luaFile) do

7 if file.open(f) then

8 file.close()

9 print("Compile File:"..f)

10 node.compile(f)

11 print("Remove File:"..f)

12 file.remove(f)

13 end

14 end

15

16 if file.open(exefile..".lc") then

17 dofile(exefile..".lc")

18 else

19 print(exefile..".lc not exist")

20 end

21 exefile=nil;luaFile = nil

22 collectgarbage()

More details, please visit: www.doit.am.

Step 7: Step 6: How to Get It

Comments

author
yichone (author)2017-06-01

you can use the DT-06 WiFi module, like HC-06, More details, please visit the link: wiki.doit.am. thanks

author
জ্ঞানপ (author)2016-12-21

hello sir ,i have esp8266-01 ,can i make this car with esp8266-01

author

ESP8266-01 is very small, and only has 4 GPIO pins. You will need a chip with at least 4 GPIOs available.

About This Instructable

46,053views

71favorites

License:

Bio: Specializing in the OpenSource Hardware. skype: yichone
More by yichone:Make a Wireless Bluetooth/WiFi Robot Tank Car Chassis Based on ESP8266 and HC-06Mobile Robot Arm DoArm S7 by wifi Arduino uno r3Installation for DoArm S6
Add instructable to: