Elegoo offered to send me its Smart Car kit for a product review. Who am I to turn down interesting looking hardware?
I prefer to build gadgets from off-the-shelf parts. Starting with a blank sheet and ending up with something that works, is challenging and sometimes downright overwhelming for a lot of people. You have to push through the doubt and roadblocks to learning if you are going to be in physical computing. There is a lot of doing, along with a lot of dreaming. Sometimes you get off track. The key is to keep moving and learn from the missteps.
A very effective way to start learning, for many tech topics, is by building kits.
Decades ago, I cut my techie teeth building Heathkits and taking apart old radios. In my teens, Radio Shack kits provided me with endless hours of fun learning basic electronics theory and assembly techniques.
Now, here we are at the end of 2018, with kits like the Elegoo Smart Car. How times have changed. Have they now?
Anything currently considered “smart” loosely means that the device contains some manner of computing capability. The definition usually provides the ability to program or modify the behavior of the device by the user. It may or may not use artificial intelligence (AI) algorithms, depending on the application. The Elegoo kit has an Arduino UNO that you program and modify for basic device behavior. There are no AI capabilities included in this version.
The good news is that once you get comfortable with the basics, AI IS readily available for you to explore right now. Maybe just add a JeVois smart machine vision sensor somewhere down the line. The only AI I knew back in the day was the HAL 9000 (Sadly, the robotic voice of HAL, Douglas Rain recently left us mere mortals behind on his journey out beyond the stars).
The kit comes neatly packaged (disassembled) in an orange plastic box with a little handle. The major structural parts and wheels are in the bottom, while the microcontroller and some of the other bits are in a removable top tray.
The screws, standoffs, nuts and odd hardware were grouped in small plastic bags and marked for their respective purposes. I thought it was a nice detail and made assembly pretty straightforward.
The Li-Ion batteries, electronics modules and screwdrivers are included in the kit so you can just open the box and start putting everything together.
You’ll find a standard HC-SR04 style ultrasonic range finder up front sitting on top of a micro servo motor. It is used to detect obstacles. Below the rangefinder on the bottom of the chassis is an LED sensor board used to detect lines that the robot can follow. There are four gear-motors and rubber-tired wheels that move and turn the robot. The motor driver board resides on the bottom chassis in the middle between the gear-motors. Up top is the Arduino UNO and the battery holder. A daughter board sits on top of the Arduino and provides connectors that route short cables to the individual electrical/electronic components. Everything is plug and play, so no soldering skills are needed to assemble the car. An infrared (IR) receiver also resides on the daughter board and can detect commands from an included IR remote keypad. There’s also a Bluetooth transceiver that plugs into the daughter board and facilitates communication with a smartphone app.
A CD comes in the kit with assembly instructions and a variety of example programs to exercise and troubleshoot all the onboard components.
Experiences and Modding the Car
The car is a robust design with very good build quality. With appropriate care, I would expect reasonable life even in a classroom setting.
If you are familiar with the components assembly is straightforward. Physical computing newbies can consult the assembly documentation, in multiple languages to help them put the car together. Lots of pictorials and graphics will guide you through the process. While it looks like a ton of individual parts when you first open the box, the finished car is clean and uncluttered with a minimal but richly functional collection of components.
Programming was easy. Plug in the included USB cable and simply call up one of the demo examples on the CD. A fairly current version 1.8.5 of the Arduino IDE will automatically start. The only glitch is that you might need to add your Linux username (on your Linux notebook) to the “dialout” user group. Use the usermod command to enable USB write permission before you upload a program to the robot’s Arduino.
rob% sudo usermod -a -G dialout rob
Alternately you could just temporarily change the permissions on the USB port with the following:
rob% sudo chmod 777 /dev/ttyACM0
I uploaded the obstacle avoidance program example for this article. It used the rangefinder and drove the car forward until detecting an object in the way. The rangefinder would scan right and left, then decide on a new direction. Sometimes the ranger wouldn’t detect an angled, small or soft object and the car would just pointlessly spin the wheels after making contact with an object. I increased the obstacle detection distance value, in the program, from 20 to 40 and had fewer crash and burn mishaps.
The tires have a lot of grip. As a result, turning wasn’t very good out of the box. My solution was to simply add a strip of plastic tape to each front tire, so the slick side was in contact with the ground. It worked great on my laminate floors.
I’ll probably increase the wire diameter from the battery box to the daughter board, as well. I suspect that the existing smallish 24-gauge diameter wires are not allowing enough current to flow to the motor driver board and contributed to the trouble I had with turning.
Controlling the car using the small remote IR keypad worked out of the box, with a new program upload, of course. It is important to point the keypad at the car from behind since the IR receiver is facing rearward on the daughter board.
Line following and Bluetooth/smartphone control will have to be explored in a future article. Bluetooth might be interesting particularly if we do calculations/planning/monitoring on a companion Raspberry Pi. I’d assume the data could flow both directions.
The Elegoo Smart Car is a nice introductory mobile robot kit. It is easy to assemble and has everything you need to get started with learning practical physical computing principles. All necessary tools are provided and the connector-based setup allows project completion right out of the box. Neophyte off-the-shelf hackers will certainly want to pick up soldering skills early in their careers, though.
I’m wondering if the Smart Car could act as a platform for exploring mobile applications of the JeVois vision sensor. Maybe I’ll pick up a second camera so I don’t have to snarf the one out of Hedley the Skull’s right eye socket.
There might also be an opportunity to replace the Arduino UNO with an ESP8266 wireless module. Maybe develop a way for the Robot Car to modify operating behaviors according to MQTT data.
We’ll consider those possibilities in the future.