KS0470 Keyestudio 4WD BT Robot Car V2.0 Kit for Arduino: Difference between revisions

From Keyestudio Wiki
Jump to navigation Jump to search
 
(Created page with "Thanks for your support on our products, we will continue to provide you better quality and service!<br> *About keyestudio<br> Keyestudio is a best-selling br...")
Line 1: Line 1:
<br> [[image:KS0470-10.jpg|thumb|600px|right| KS0470 Keyestudio 4WD BT Robot Car V2.0 Kit for Arduino]]
Thanks for your support on our products, we will continue to provide you better quality and service!<br>
*About keyestudio<br>  
           
Keyestudio is a best-selling brand owned by KEYES Corporation, our product lines range from controller boards, shields and sensor modules to smart car and complete starter kits for Arduino, Raspberry Pi and BBC micro:bit, which designed for customers of any level to learn electronics and programming knowledge. All of our products comply with international quality standards and are greatly appreciated in a variety of different markets throughout the world. <br>


<br>  
You can obtain the details and the latest information through visiting the following web sites:http://www.keyestudio.com<br>
== Description ==
*References and After-sales Service <br>
The popularity of Maker Education has resulted in a variety of Maker products, some of which are combinations of electronic components and modules, and some are novel and innovative products.<br>
   
The 4WD multifunctional smart car newly upgraded by the Keyestudio Group is one of the most popular categories: programming robots.<br>
1.Download Profile:https://fs.keyestudio.com/KS0470<br>
It is not only beautiful in appearance, but also powerful in function.Except for the commonly used functions of tracking, obstacle avoidance, remote control, etc.,a facial expression is added too, you can DIY your own cute expression, amazing! If you think it’s not enough, you can add other sensors to complete your exploration journey.<br>


2.Feel free to contact us please, if there is missing part or you encounter some troubles. Welcome to send email to us:service@keyestudio.com. We will update projects and products continuously based on your sincere advice.<br>


<br>
*Warning
                         
1.This product contains tiny parts(screws, copper pillars), keep it out of reach of children under 7 years old please.<br>
2.This product contains conductive parts (control board and electronic module). Please operate according to the requirements of this tutorial. Improper operation may cause overheating and damage parts. Do not touch and immediately disconnect the circuit power.<br>


== Parameters ==
*Copyright  
* Motor control is driven by L298P expansion board, built-in power control switch. <br>
                                                         
* Ultrasonic module is used to detect whether there is front obstacles and the distance between the obstacle and the 4WD BT Robot Car. The 4WD BT Robot Car obstacle avoidance system is formed.<br>
The keyestudio trademark and logo are the copyright of KEYES DIY ROBOT co.,LTD. All products under keyestudio brand can’t be copied, sold and resold without authorization by anyone or company. If you’re interested in our items, please contact to our sales representatives: fennie@keyestudio.com
* Motor’s Parameters: 5V 200 rpm/ min<br>
* Provide graphical programming test code and support Mixly.<br>
* Bluetooth wireless module can match with Bluetooth on mobile phone to remotely control the 4WD BT Robot Car, and supports Android and IOS system.<br>
* Can access to the external voltage 7~12V, and can carry various sensor modules, achieve all kinds of functions according to your imagination.
* IR receiver module matches with IR remote control to control 4WD BT Robot Car<br>


== Component List ==
{| class="wikitable"
|-
! No !! Name !! QTY !! Picture
|-
| 1 || Keyestudio Arduino REV4 Board|| 1 || [[File:KS0470-1-1(2).jpg|100px|frameless|]]<br>
|-
| 2 || Keyestudio quick connectors motor driver shield V2 || 1 || [[File:0470-2.png |100px|frameless|]]
|-
| 3|| Keyestudio HM-10 Bluetooth-4.0 V3 compatible HC-06 pin  || 1|| [[File:0470-3-1.png|100px|frameless|]]
|-
| 4 || HC-SR04 ultrasonic sensor || 1 ||[[File: 0470-3-2.png|100px|frameless|]]
|-
| 5 || Keyestudio quick connectors line tracking sensor|| 1 ||[[File: 0470-3-3.png|100px|frameless|]]
|-6 || Keyestudio quick connectors  IR receiver sensor || 1 ||[[File: 0470-10.png|100px|frameless|]]
|-
| 7 ||Keyestudio 8X16 LED light board with DuPont line || 1 ||[[File: 0428图片20.png|100px|frameless|]]
|-
| 8 || Keyestudio 9G 23*12.2*29mm  black servo 180° with white mounts || 1 ||[[File:0470-12.png |100px|frameless|]]
|-
| 9 || Keyestudio JMFP-4 17 button 86*40*6.5MM yellow eco-friendly(without battery)|| 1 || [[File:0470-13.png|100px|frameless|]]
|-
| 10 || AM/BM clear blue OD:5.0 L=50cm eco-friendly|| 1 || [[File:0470-14.png|100px|frameless|]]
|-
| 11 || 18650 2-cell 15CM Dew line for DIY car+double headJST-PH2.0MM-2P wire(bus length115MM)|| 1 || [[File:0470-15.png|100px|frameless|]]
|-
| 12|| 6-cell AA with 15CM dew line + double head JST-PH2.0MM-2P cable (bus length 200MM)|| 1 ||[[File:0470-16.png |100px|frameless|]]
|-
| 13 || Pan tilt mount(black) kit || 1 || [[File:0470-17.png |100px|frameless|]]
|-
| 14|| Double head JST-PH2.0MM-5P 24AWG blue green yellow red black line 15CM || 1 ||  [[File:0470-18.png |100px|frameless|]]
|-
| 15 || Double head JST-PH2.0MM-3P 24AWG yellow red black line 8CM || 1 ||  [[File:0470-19.png |100px|frameless|]]
|-
| 16 || JST-PH2.0mm-4P to 2.54 DuPont female single 26AWG black red blue green line || 1 || [[File:0470-20.png |100px|frameless|]]
|-
| 17|| The front acrylic board of 4WD car LED screen || 1||  [[File:0470-21.png |100px|frameless|]]
|-
| 18 || Keyestudio 4WD smart car V2.0 Top PCB board || 1|| [[File:0470-22.png |100px|frameless|]]
|-
| 19 || Keyestudio 4WD smart car V2.0 bottom PCB || 1 || [[File:0470-23.png |100px|frameless|]]
|-
| 20 || Fixed parts 23*15*5MM 9MM pitch aluminum || 4 || [[File:0470-24.png |100px|frameless|]]
|-
| 21 || Wheel 68*26mm Shaft inner diameter: 5.3*3.6mm Wheel hub: yellow Tire: black  || 4 || [[File:0470-25.png |100px|frameless|]]
|-
| 22 || M3*10MM dual-pass copper pillars || 10 || [[File:0470-26.png |100px|frameless|]]
|-
| 23 || M3*40MM dual-pass copper pillar || 4 || [[File:0470-27.png |100px|frameless|]]
|-
| 24|| M3*30MM round-head cross screw || 8 || [[File:0470-28.png |100px|frameless|]]
|-
| 25 ||M3*6MM round-head screw|| 40 || [[File:0470-29.png |100px|frameless|]]
|-
| 26||M3 Nickel Plated Nut || 16 || [[File:0470-30.png |100px|frameless|]]
|-
| 27||M2X8MM round-head screw || 6 || [[File:0470-31.png |100px|frameless|]]
|-
| 28 || M3*8MM round-head screw  || 4 || [[File:0470-32.png |100px|frameless|]]
|-
| 29|| M2 Nickel Plated Nut || 6 || [[File:0470-33.png |100px|frameless|]]
|-30 || M3*10MM flat screw|| 3|| [[File:0470-34.png |100px|frameless|]]
|-
| 31 || 5V 200/rpm gear motor (with welding wire)|| 4 || [[File:0470-35.png |100px|frameless|]]
|-
| 32 || 3*40MM screwdriver || 1 || [[File:0470-36.png |100px|frameless|]]
|-
| 33 || black Nylon cable 3*100MM || 10 || [[File:0470-37.png |100px|frameless|]]
|-
| 34 || Winding tube diameter 8MM black|| 1|| [[File:0470-38.png |100px|frameless|]]
|}


<br>
== Introduction ==


== '''<big>Resources</big>''' ==
Nowadays, technological education such as VR, kids programming, and artificial intelligence, has become mainstream in educational industry. Thereby, people attach importance to STEAM education. Arduino is pretty notable in Maker education.
https://fs.keyestudio.com/KS0470


<br>
So what is Arduino? Arduino is an open-source electronics platform based on easy-to-use hardware and software. Arduino boards are able to read inputs - light on a sensor, a finger on a button, or a Twitter message - and turn it into an output - activating a motor, turning on an LED, publishing something online. Based on this, Keyestudio team has designed a 4wd robot. It has a processor which is programmable using the Arduino IDE, to mapped its pins to sensors and actuators by a shield that plug in the processor, it reads sensors and controls the actuators and decides how to operate.


== Getting Started with Mixly and ARDUINO ==
15 learning projects, from simple to complex, will guide you how to make a smart 4wd robot on you own and introduce the detailed knowledge about sensors and modules.  
===Installing Arduino IDE===
We enter the ARDUINO official website: https://www.arduino.cc, we’ll see the following page,


<br>[[File:0470-3.png|600px|frameless]]<br>
Simultaneously, it is the best choice if you intend to obtain a DIY robot for learning programming, entertainment and competition requirement.


The software we’ll download is in the SOFTWARE section.<br>
   
<br>[[File:0470-4.png|600px|frameless]]<br>


Click the icon as below:<br>


<br>[[File:0470-5.png|600px|frameless]]<br>
== Features ==  
 
We can find IDE software which is compatible with various versions and systems. We choose the 1.8.5 version of the IDE, you can choose other versions according to your personal preferences.<br>
 
<br>[[File:0470-39.png|600px|frameless]]<br>
The Windows version also has two options,for one option that we could directly click on “install” to download the file. Another choice is to download the file to the computer firstly, then extract the file, and open the program file of the ARDUINO icon to start.<br>
 
==== 1. Installing Driver ====
<br>Following the previous method, we installed the Arduino IDE software. Before using it, we need to install the driver of the REV3 development board, otherwise it will not be used. The driver file can be used of the drivers file in the link, or the built-in drivers file can be used too after installing.<br>
<br>[[File:0470-40.png|600px|frameless]]<br>
There are some small differences for installing driver on different computer systems. Next, we introduce the method of installing the driver in the WIN 7 system. Firstly connect the development board to the computer, click on Computer--Properties--Device Manager to display the following figure.<br>
[[File:15937.png|600px|frameless]]<br>
 
Click “Unknown device” to install the driver, as shown below.<br>
 
<br>[[File:15938.png|600px|frameless]]<br>
 
Enter this following page and choose:<br>
 
<br>[[File:15939.png|600px|frameless]]<br>
 
Find the drivers folder for the installation of Arduino.<br>
 
<br>[[File:0470-44.png|600px|frameless]]<br>
 
Click "Next" and click "Install this driver software anyway" t to start installing  driver .<br>
 
<br>[[File:15941.png|600px|frameless]]<br>
 
Complete driver installation, click “Close” as shown below <br>
 
<br>[[File:15942.png|600px|frameless]]<br>
 
This drive is installed. Click on Computer--Properties--Device Manager, we can see the following figure.<br>
 
<br>[[File:15943.png|600px|frameless]]<br>
 
==== 2. Getting started with Arduino IDE ====
Step 1: Open software
In the previous lesson, we successfully installed the driver for the REV3 development board. In this lesson, let's learn how to use the Arduino IDE software. We open the folder with decompressed ARDUINO development software and click the ARDUINO icon to open the software.
 
<br>[[File:0470-50.png|600px|frameless]]<br>
 
Step 2: Create project
Once the software starts, you have two options:
Create a new project.
Open an existing project example.
To create a new project, choose Flie→New please.
 
<br>[[File:0470-51.png |600px|frameless]] [[File:0470-52.png|600px|frameless]]<br>
 
Open an existing project example, choose File→Example→Basics→Blink please.
 
<br>[[File:0470-53.png |600px|frameless]]<br> <br>[[File: 0470-54.png|600px|frameless]]<br>
 
Step 3: Select Arduino main board
To avoid any errors when uploading the program to the board, you need to select the correct Arduino board.
Go to Tools→Board and select your board.
 
<br>[[File:0470-55.png |600px|frameless]]<br>
 
Here, we chose the Arduino UNO board according to our tutorial.
Step 4: Select the serial port.
Select the serial device of the Arduino board. Go to the Tools→Serial Port menu. We can find the corresponding COM port by clicking Computer--Property-Device Manager.
 
<br>[[File:1594br3.png |600px|frameless]]<br>
[[File:0470-57.png |600px|frameless]]<br>
 
Step 5: Upload the program to your board
 
Before explaining how to upload our program to the board, we demonstrate the functionality of each symbol that appears in the Arduino IDE toolbar.
 
[[File:0470-58.png |600px|frameless]]<br>
 
A - for checking any compile error <br>
B - for uploading programs to the Arduino board <br>
C - for creating shortcut for a new sketch <br>
D - for opening one of the sample sketches directly<br>
E - for saving sketches<br>
F - for receiving serial data from the board and sending serial data to the board of serial monitor<br>
 
=== How to import library folder of Arduino IDE ===
Sometimes, when uploading the code, we need to add the corresponding library file. Firstly we open the folder with decompressed ARDUINO development software and find the libraries folder.<br>
[[File:0470-59.png|600px|frameless]]<br>
 
Then place the corresponding folder with the library file in the libraries folder. This library file is installed.<br>
Note: If the Arduino IDE software is already open when the library file is placed, need to close the Arduino IDE and re-open the Arduino IDE. The library file will take effect, otherwise the library file will be invalid.
Specific methods you can refer to:<br>
 
https://wiki.keyestudio.com/How_to_Install_Arduino_Library
website.
 
=== Downloading Mixly Software ===
Next,we will learn about Mixly graphical programming software. Firstly we need to download a  Mixly  software.
More info please check the link to download the Mixly blocks software.<br>
https://fs.keyestudio.com/WINMixly <br>
https://fs.keyestudio.com/MACMixly<br>
 
=== Getting started with Mixly ===
 
Introduction for Mixly
 
Mixly is a free open-source graphical Arduino programming software, based on Google’s Blockly graphical programming framework, and developed by Mixly Team@ BNU.
It is a free open-source graphical programming tool for creative electronic development; a complete support ecosystem for creative e-education; a stage for maker educators to realize their dreams.
 
Mixly functions
 
Through this interface, you can complete the code compile、upload、save and manage. It support four remove methods: drag it left out code window, or drag to Recycle Bin, delete key, or right-click to delete block. It supports four languages: English, Spanish, Chinese Simplified and Chinese Traditional. <br>
[[File:3.1-1.png |600px|frameless]]<br>
[[File:Ks0446图片8.png |600px|frameless]]<br>
<br>
(1)In/Out Block<br>
[[File:0470-63.png |600px|frameless]]<br>
<br>
(2)Control Block<br>
[[File:0470-64.png |600px|frameless]]<br>
<br>
(3) Math Block<br>
[[File:0470-77.png |600px|frameless]]<br>
<br>
(4) Text Block<br>
[[File:0470-66.png |600px|frameless]]<br>
<br>
(5) List Block<br>
[[File:0470-67.png|600px|frameless]]<br>
<br>
(6) Logic Block<br>
[[File:0470-68.png|600px|frameless]]<br>
<br>
(7)Variable Block<br>
[[File:0470-69.png|600px|frameless]]<br>
<br>
(8) SerialPort Block<br>
[[File:0470-70.png|600px|frameless]]<br>
<br>
(9)Communicate Block<br>
[[File:0470-71.png|600px|frameless]]<br>
<br>
(10) Sensor Block<br>
[[File:0470-72.png|600px|frameless]]<br>
<br>
(11)Actuator Block<br>
[[File:0470-73.png|600px|frameless]]<br>
<br>
(12)Monitor Block<br>
[[File:0470-74.png|600px|frameless]]<br>
<br>
(13)Function Block<br>
[[File:0470-75.png |600px|frameless]]<br>
 
=== How to import file on Mixly ===
To facilitate the car program process, we specially design a smart library file for this smart car. The import, export, and editing of library files are shown below:
[[File:0470-76.png |600px|frameless]]<br>
 
Click”import” to enter library folder, click [[File:0470-78.png|100px|frameless]],the library file is imported successfully.<br>
 
== Getting Started with Hardware Projects for 4WD BT Robot Car ==
In this course, we will start testing the functions of various electronic components in the kit to ensure that each component is good.
 
=== Project 1: REV4 Control Board ===
[[File:KS0470-1-1(2).jpg|600px|frameless]]<br>
When it comes to using the REV4 as core of our robot, the REV4 is the best board to get started with electronics and coding. <br>
If this is your first experience tinkering with the platform, the REV4 is the most robust board you can start playing with.<br>
Well, let's at first have a look at this REV4 board. <br>
[[File:KS0341 引脚标图.jpg|600px|frameless]]<br>
 
{| width="80%" cellspacing="0" border="1"
|-
| align="center" | [[Image:KS0001 5-1.png|500px|frameless]]
| align="light" | '''ICSP (In-Circuit Serial Programming) Header'''
In most case, ICSP is the AVR,an Arduino micro-program header consisting of MOSI, MISO, SCK, RESET, VCC, and GND. It is often called the SPI (serial peripheral interface) and can be considered an "extension" of the output. In fact, slave the output devices under the SPI bus host.<br>
When connecting to PC, program the firmware to ATMEGA328P-PU.
|-
 
| align="center" | [[Image:KS0001 5-2.png|500px|frameless]]
| align="light" | '''Power LED Indicator'''
Powering the Arduino, LED on means that your circuit board is correctly powered on. If LED is off, connection is wrong.
|-
 
| align="center" | [[Image:KS0001 5-3.png|500px|frameless]]
| align="light" | '''Digital I/O'''
Arduino UNO has 14 digital input/output pins (of which 6 can be used as PWM outputs). These pins can be configured as digital input pin to read the logic value (0 or 1). Or used as digital output pin to drive different modules like LED, relay, etc. The pin labeled “〜” can be used to generate PWM.
|-
 
| align="center" | [[Image:KS0001 5-4.png|500px|frameless]]
| align="light" | '''GND ( Ground pin headers)'''
Used for circuit ground 
|-
 
| align="center" | [[Image:KS0001 5-5.png|500px|frameless]]
| align="light" | '''AREF'''
Reference voltage (0-5V) for analog inputs. Used with [https://www.arduino.cc/reference/en/language/functions/analog-io/analogreference/    analogReference()].
|-
 
| align="center" | [[Image:KS0001 5-6.png|500px|frameless]]
| align="light" | '''SDA'''
IIC communication pin
|-
 
| align="center" | [[Image:KS0001 5-7.png|500px|frameless]]
| align="light" | '''SCL'''
IIC communication pin
|-
 
| align="center" | [[Image:KS0001 5-8.png|500px|frameless]]
| align="light" | '''ICSP (In-Circuit Serial Programming) Header'''
In most case, ICSP is the AVR,an Arduino micro-program header consisting of MOSI, MISO, SCK, RESET, VCC, and GND. Connected to ATMEGA 16U2-MU. When connecting to PC, program the firmware to ATMEGA 16U2-MU.
|-
 
| align="center" | [[Image:KS0001 5-9.png|500px|frameless]]
| align="light" | '''RESET Button'''
You can reset your Arduino board, for example, start the program from the initial status. You can use the RESET button.
|-
 
| align="center" | [[Image:KS0001 5-10.png|500px|frameless]]
| align="light" | '''D13 LED'''
There is a built-in LED driven by digital pin 13. When the pin is HIGH value, the LED is on, when the pin is LOW, it's off.
|-
 
| align="center" | [[Image:KS0001 5-11.png|500px|frameless]]
| align="light" | '''USB Connection'''
Arduino board can be powered via USB connector.
All you needed to do is connecting the USB port to PC using a USB cable.
|-
 
| align="center" | [[Image:KS0001 5-12.png|500px|frameless]]
| align="light" | '''ATMEGA 16U2-MU  '''
USB to serial chip, can convert the USB signal into serial port signal.
 
|-
| align="center" | [[Image:KS0001 5-13.png|500px|frameless]]
| align="light" | '''TX LED'''
Onboard you can find the label: TX (transmit)
When Arduino board communicates via serial port, send the message, TX led flashes.
 
|-
| align="center" | [[Image:KS0001 5-14.png|500px|frameless]]
| align="light" | '''RX LED'''
Onboard you can find the label: RX(receive )
When Arduino board communicates via serial port, receive the message, RX led flashes.
|-
 
| align="center" | [[Image:KS0001 5-15.png|500px|frameless]]
| align="light" | '''Crystal Oscillator '''
Helping Arduino deal with time problems. How does Arduino calculate time? by using a crystal oscillator.<br>
The number printed on the top of the Arduino crystal is 16.000H9H. It tells us that the frequency is 16,000,000 Hertz or 16MHz.
 
|-
| align="center" | [[Image:KS0001 5-16.png|500px|frameless]]
| align="light" | '''Voltage Regulator'''
To control the voltage provided to the Arduino board, as well as to stabilize the DC voltage used by the processor and other components.<br>
Convert an external input DC7-12V voltage into DC 5V, then switch DC 5V  to the processor and other components.
 
|-
 
| align="center" | [[Image:KS0001 5-17.png|500px|frameless]]
| align="light" | '''DC Power Jack'''
Arduino board can be supplied with an external power DC7-12V from the DC power jack.
|-
 
| align="center" | [[Image:KS0001 5-18.png|500px|frameless]]
| align="light" | '''IOREF '''
Used to configure the operating voltage of microcontrollers. Use it less.
 
|-
| align="center" | [[Image:KS0001 5-19.png|500px|frameless]]
| align="light" | '''RESET Header '''
Connect an external button to reset the board. The function is the same as reset button (labeled 9)
 
|-
| align="center" | [[Image:KS0001 5-20.png|500px|frameless]]
| align="light" | '''Power Pin 3V3'''
A 3.3 volt supply generated by the on-board regulator. Maximum current draw is 50 mA.
|-
 
| align="center" | [[Image:KS0001 5-21.png|500px|frameless]]
| align="light" | '''Power Pin 5V'''
Provides 5V output voltage
 
|-
| align="center" | [[Image:KS0001 5-22.png|500px|frameless]]
| align="light" | '''Vin'''
You can supply an external power input DC7-12V through this pin to Arduino board.
 
|-
| align="center" | [[Image:KS0001 5-23.png|500px|frameless]]
| align="light" | '''Analog Pins'''
Arduino UNO board has 6 analog inputs, labeled A0 through A5. <br>
These pins can read the signal from analog sensors (such as humidity sensor or temperature sensor), and convert it into the digital value that can read by microcontrollers)
Can also used as digital pins, A0=D14, A1=D15, A2=D16, A3=D17, A4=D18, A5=D19.
|-
 
| align="center" | [[Image:KS0001 5-24.png|500px|frameless]]
| align="light" | '''Microcontroller '''
Each Arduino board has its own microcontroller. You can regard it as the brain of your board.<br>
The main IC (integrated circuit) on the Arduino is slightly different from the panel pair. Microcontrollers are usually from ATMEL. Before you load a new program on the Arduino IDE, you must know what IC is on your board. This information can be checked at the top of IC.
|-
|}
 
<br>
 
=== Project 2: Adjusting Servo Angle ===
 
'''Overview''' <br>
Servo motor is a position control rotary actuator. It mainly consists of housing, circuit board, core-less motor, gear and position sensor. 
Included with your servo motor you will find a variety of white motor mounts that connect to the shaft of your servo.
You may choose to attach any mount you wish for the circuit. It will serve as a visual aid, making it easier to see the servo spin.
[[File:0464-pro8图1.png |400px|frameless]]<br>
 
'''Working principle:''' <br>
The receiver or MCU outputs a signal to the servomotor. The motor has a built-in reference circuit that gives out reference signal, cycle of 20ms and width of 1.5ms. The motor compares the acquired DC bias voltage to the voltage of the potentiometer and outputs a voltage difference.
Servo motor comes with many specifications. But all of them have three connection wires, distinguished by brown, red, orange colors (different brand may have different color).
Brown one is for GND, red one for power positive, orange one for signal line.
 
The rotation angle of servo motor is controlled by regulating the duty cycle of PWM (Pulse-Width Modulation) signal. The standard cycle of PWM signal is 20ms (50Hz).
Theoretically, the width is distributed between 1ms-2ms, but in fact, it's between 0.5ms-2.5ms. The width corresponds the rotation angle from 0° to 180°. But note that for different brand motor, the same signal may have different rotation angle. 
[[File:0470-82.png|600px|frameless]]<br>
 
We can directly set the output high and low level of the corresponding pin on Mixly to control the angle of servo; and we specially set library file of smart car via one code to control, which is easy and convenient.
 
'''Specifications:''' <br>
* Working voltage: DC 4.8V~6V
* Operating angle range: About 180° (at 500 → 2500 μsec)
* Pulse-width range: 500 → 2500 μsec
* No-load speed: 0.12±0.01 sec/60 (DC 4.8V) 0.1±0.01 sec/60 (DC 6V)
* No-load current: 200±20mA (DC 4.8V) 220±20mA (DC 6V)
* Stop torque: 1.3±0.01kg·cm (DC 4.8V) 1.5±0.1kg·cm (DC 6V)
* Stop current: ≦850mA (DC 4.8V) ≦1000mA (DC 6V)
* Standby current: 3±1mA (DC 4.8V) 4±1mA (DC 6V)
* Wire length: 250 ± 5 mm
* Appearance size: 22.9*12.2*30mm
* Weight: 9 ± 1 g (without servo horn)
* Storage temperature: -20 ° C ~ 60 ° C
* Operating temperature: -10 ° C ~ 50 ° C
 
'''Wiring Diagram''' <br>
[[File:0470-83.png |600px|frameless]]<br>
'''Test Code''' <br>
[[File:0470-84.png |600px|frameless]]<br>
'''Test Result''' <br>
Upload the code on the REV4 board successfully, power on according to wiring diagram, the servo will swing back and forth in the range of 0° to 180°.
 
'''Little Knowledge''' <br>
1)In the code, the default signal interface of library file is A3.<br>
2)[[File:0470-85.png |300px|frameless]]<br>represents variable i, i increases directly from 0 to 180, by 1 each time, 180 times in total.<br>
3)[[File:0470-86.png |300px|frameless]] represents variable i, i directly decreases from 180 to 0, by 1 each time, 180 times in total.<br>
4)[[File:0470-87.png |300px|frameless]] means the angle of servo, the range of this servo angle is 0-180 degree.<br>
 
'''Extension Practice:''' <br>
1)Increase angle of servo from 0° to 180°, increase by 2° each time, then gradually reduce from 180° to 0° , each time by 5°.<br>
2)Set servo to 90°.<br>
 
=== Project 3: Ultrasonic Detecting Obstacles ===
'''Overview:'''  <br>
In the process of smart car DIY,  the ultrasonic module is a very commonly used sensor module. The module can detect whether there is obstacle ahead. We can also know about the distance between the smart car and the obstacle through calculation. The smart car is controlled by the the distance that the ultrasonic detects, so as to realize various functions, such as automatic avoiding, following, etc.
In the experiment, we test the corresponded distance by detecting the ultrasonic module and the obstacle ahead, and display on the serial monitor.
 
* Working Voltage: DC 5V
* Working Current: 15mA
* Working Frequency: 40KHz
* Max Range: 2--3m
* Min Range: 2cm
* Measuring Angle: 15 degree
* Trigger Input Signal: 10µS TTL pulse
 
'''Wiring Diagram''' <br>
[[File:0470-88.png|600px|frameless]]<br>
'''Test Code''' <br>
[[File:0470-89.png|600px|frameless]]<br>
 
'''Test Result''' <br>
In the experiment, we use the USB cable to supply power, upload the test code, open the serial monitor and set the baud rate to 9600, we can see the distance between the ultrasonic module and the obstacle ahead ( cm), as shown below:<br>
[[File:464图片46.png|600px|frameless]]<br>
 
'''Knowledge''' <br>
1. Use [[File:0470-91.png |600px|frameless]]to test distance, the wire interface can’t be changed at you will. The library file has been fixed to the wiring port, and the interface cannot be changed.
2. Click [[File:0470-92.png|600px|frameless]],observe the C language code, you can find the corresponding interface and calculation formula in the code.<br>
 
'''Extension Practice''' <br>
We can test the data measured by the ultrasonic to control the angle of rotation of servo. For example, when the distance is less than 15cm, set servo to 60º; when the distance is greater than or equal to 15cm, set servo to 120º.<br>
 
=== Project 4: LED Matrix Display Pattern ===
'''Overview''' <br>
This is a smart car kit with built-in an 8x16 LED light board that can be used to display various states of the smart car. Firstly let's learn the next 8x16 LED board.
The 8x16 LED board comes with 128 LEDs and an AIP1640 chip. We can use the MCU and this module for I2C communication. By controlling the AIP1640 chip,the on/off of the 128 LEDs on the module is controlled and the pattern you need is displayed on the dot matrix of the module. To facilitate wiring, we also provide a HX-2.54 4Pin wiring.
 
'''Specifications:''' <br>
 
* Working voltage: DC 3.3-5V
* Power loss: 400mW
* Oscillation frequency: 450KHz
* Driver current: 200mA
* Working temperature: -40~80°C
* Communication method: I2C communication
 
'''Wiring Diagram'''  <br> 
[[File:0470-93.png |600px|frameless]]<br>
'''Test Code''' <br>
[[File:0470-94.png |600px|frameless]]<br>
'''Test Result''' <br>
 
Upload the code on the REV4 board successfully, wire according to connection diagram, DIP switch is dialed to the right end. After power-on, 8X16 LED matrix circularly displays starts "V" pattern, forward pattern, backward pattern, leftward  pattern, rightward pattern and stop pattern with a time interval of 2 seconds.
 
'''Knowledge''' <br>
In the code, we have set the display state of the LED matrix in the library.
1.[[File:0470-95.png|300px|frameless]]code is adjustable, it has 7 conditions [[File:0470-95.png|300px|frameless]] stands for clearing up display.
2. [[File:0470-97.png|300px|frameless]] is delay code,which stands for delay 2000ms,we can set the digits freely. Set the delay time to control the display frequency of LED matrix
 
'''Extension Practice''' <br>
1.Set the code to make the LED matrix circularly display 7 states, the delay time of each state is 500ms.
 
=== Project 5: Line Tracking Sensor ===
 
'''Overview:''' <br>
[[File:Ks0313-7(3.png |400px|frameless]]<br>
The tracking sensor is actually an infrared sensor. The component used here is the TCRT5000 infrared tube. <br>
Its working principle is to use the different reflectivity of infrared light to the color, then convert the strength of the reflected signal into a current signal. <br>
During the process of detection, black is active at HIGH level, but white is active at LOW level. The detection height is 0-3 cm. <br>
The keyestudio 3-channel line tracking module has integrated 3 sets of TCRT5000 infrared tube on a single board, which is more convenient for wiring and control. <br>
By rotating the adjustable potentiometer on the sensor, it can adjust the detection sensitivity of the sensor.<br>
 
 
* Operating Voltage: 3.3-5V (DC)
* Interface: 5PIN
* Output Signal: Digital signal
* Detection Height: 0-3 cm
[[File:441图66.png|600px|frameless]]<br>
 
 
<span style=color:"red">Special note: before testing, turn the potentiometer on the sensor to adjust the detection sensitivity. When adjust the LED at the threshold between ON and OFF, the sensitivity is the best. </span>
 
'''Wiring Diagram'''<br>
[[File:0470-100.png |600px|frameless]]<br>
 
'''Test Code''' <br>
[[File:0470-101.png|600px|frameless]]<br>            [[File:0470-107.png|600px|frameless]]<br>
 
'''Test Result'''<br>
Upload the code on the REV4 board successfully, wire according to connection diagram , after power-on, the dial switch is dialed to the "ON" end. When any TCRT5000 infrared tube of the module detects the white line, the 8X16 LED matrix starts displaying “V" pattern; otherwise, 8X16 LED panel does not display patterns.<br>
 
'''Knowledge'''<br>         
In the code [[File:0470-102.png |600px|frameless]],which stands for using library file to read High/Low level of left sensor(D6), its function is as same as [[File:441图72.png |600px|frameless]]. At same time,the signal end of middle sensor corresponds to D7,the signal  end  of right sensor corresponds to D8.<br>
   
   
In the code [[File:0428图片45.png|600px|frameless]], it means that if condition 1 is met, the result is A, otherwise the result is B. When using it, you only find it on Mixly [[File:0470-105.png|600px|frameless]] sentences,click blue gear icon, then drag[[File:0470-106.png|600px|frameless]] to [[File:0470-107.png|600px|frameless]] block. Set successfully.<br>
                                                       
[[File:0470-108.png|600px|frameless]]<br>
1.Multi-purpose function: Obstacle avoidance, follow, IR remote control, Bluetooth control, ultrasonic follow and displayed face emoticons.
2. Simple assembly: No soldering circuit required, complete assembly easily.
3. High Tenacity: Aluminum alloy bracket, metal motors, high quality wheels and tracks
4. High extension: expand other sensors and modules through motor driver shield and sensor shield
5. Multiple controls: IR remote control, App control(IOS and Android system)
6.Basic programming:C language code of Arduino IDE.


In the experimentis [[File:0470-109.png |600px|frameless]]logic sentence, it is required to meet one of three requirements.<br>
== Specification ==   
 
                                                       
'''Extension Practice'''<br>
Working voltage: 5v
* Change the above code into the code without library file, the same function is required.
Input voltage: 7-12V
* Set up the three control terminals of the tracking module. Control the servo to rotate at different angles.
Maximum output current: 2A
 
=== Project 6: Infrared Receiver ===
 
There is no doubt that infrared remote control is commonly seen in our daily life. It's hard to imagine our world without it. In reality, an infrared remote control can be used to control a wide range of home appliances such as television, audio, video recorders and satellite signal receivers.
Well, in the following let’s get a better understanding of the infrared remote control.
Infrared remote control is composed of infrared transmitting and infrared receiving systems. That is, consist of an infrared remote control, an infrared receiver module and a microcontroller that can decode. <br>
  [[File:Ks0436-201.png|600px|frameless]]<br>
 
The 38K infrared carrier signal transmitted by an infrared remote controller is encoded by an encoding chip inside the remote controller. It is composed of a pilot code, user code, data code, and data inversion code. The time interval between pulses is used to distinguish whether it is a signal 0 or 1. (when the ratio of high level to low level is about 1:1, considered as signal 0.) And the encoding is just well composed of signal 0 and 1.
The user code of the same button on remote controller is unchanged. Using difference data distinguish the key pressed on the remote control. When press down a button on the remote control, it will send out an infrared carrier signal. And when infrared receiver receives that signal, its program will decode the carrier signal, and through different data codes, thus can judge which key is pressed.
The microcontroller is decoded by an received signal 0 or 1 to determine which key is pressed by the remote control.
As for an infrared receiver module, it is mainly composed of an infrared receiving head. This device integrates with reception, amplification and demodulation. Its internal IC has been demodulated, able to complete all the work from infrared reception to output TTL level signal compatible. It outputs Digital signal. Suitable for IR remote control and infrared data transmission.
The infrared receiver module has only three pins (Signal line, VCC, GND), very convenient to communicate with Arduino and other microcontrollers.
 
'''Parameters of IR Receiver:'''<br>
* Operating Voltage: 3.3-5V(DC)
* Interface: PH2.0-3P
* Output Signal: Digital signal
 
'''Wiring Diagram''' <br>
[[File:0470-111.png|600px|frameless]]<br>
'''Test Code''' <br>
[[File:0470-112.png |600px|frameless]]<br>
 
'''Test Result'''
In the experiment, we use the USB cable to supply power, upload the test code, open the serial monitor, set the baud rate to 9600, take out the remote control which points to infrared receiving sensor to send the signal. The key value of the corresponding button is shown. If pressed for long time, error codes will appear, as shown below.<br>
[[File:0470-113.png  |600px|frameless]]<br>
 
If the forward value of the infrared remote control is received, the dot matrix displays the forward pattern. If the key value of infrared remote control is “OK”, pattern “STOP”appear.
We made a remote control button value table through the obtained values, which is convenient for future use.<br>
[[File:0470-114.png|600px|frameless]]<br>
 
'''Knowledge'''<br>   
 
1.In the code [[File:0470-115.png |600px|frameless]], it  represents that library file is used directly, The signal terminal of the infrared receiving module is A1, infrared receiver module receives the infrared signal, outputs the 16-bit code, and displays on the serial monitor (baud rate 9600).
2.Through the code we can measure the 16-bit code of all keys of the infrared remote control, you can refer to the above picture.
 
'''Extension Practice'''<br>
1.We control the LED matrix by infrared remote control to display different patterns and control the servo to rotate at different angles.
 
=== Project 7: Motor Driving and Speed Control===
 
'''Overview:'''<br>
There are many ways to drive the motor. Our robot uses the most commonly used L298P solution. L298P is an excellent high-power motor driver IC produced by STMicroelectronics. It can directly drive DC motors, two-phase and four-phase stepping motors. The driving current up to 2A, and output terminal of motor adopts eight high-speed Schottky diodes as protection.
We have designed the motor driver shield V2 based on the L298P circuit.
The stackable design can make it be plugged directly into the Arduino, reducing the technical difficulty of using and driving the motor.
Direct stack the motor driver shield onto REV4 board, after the BAT is powered on, turn the Slide switch ON, to supply the power for both keyestudio motor driver shield V2 and REV4 board.
For simple wiring, the motor driver shield comes with anti-reverse interfaces. When connecting the motor, power supply and sensor modules, you just need to plug in directly.
 
The Bluetooth interface on the motor driver shield is fully compatible with keyestudio HM-10 Bluetooth module. When connecting, just plug HM-10 Bluetooth module into the corresponding interface.
 
At the same time, the motor drive shield has brought out extra digital and analog ports in 2.54mm pin headers, so that you can continue to add other sensors for experiments extension.
The motor drive shield can access to 4 DC motors, defaulted by jumper connection. The motor connector A and A1, connector B and B1 are separately in parallel.
 
The 8 jumpers can be applied to control the turning direction of 4 motors.
For instance, if change the 2 jumpers near the motor A connector from horizontal connection to vertical connection, the turning direction of motor A is opposite to the original rotation direction.
 
'''Specifications:'''<br>
Logic part input voltage: DC5V
Driving part input voltage (limit): DC 6-18V
Driving part input voltage (recommended): DC 7-12V
Driving part input voltage: DC 7-12V
Logic part working current: <36mA
Driving part working current: <2A
Maximum power dissipation: 25W (T=75℃)
Maximum power dissipation: 25W (T=75℃)
Working temperature: -25℃~+130℃
Motor speed: 5V 200 rpm/min
 
Motor drive mode: dual H bridge drive
'''PIN  Instructions:'''<br>
Ultrasonic induction angle: <15 degrees
[[File:0435英.png|600px|frameless]]<br>
Ultrasonic detection distance: 2cm-400cm
 
Infrared remote control distance: 10 meters (measured)
'''Wiring Diagram''' <br> 
Bluetooth remote control distance: 50 meters (measured)
[[File:0470-117.png |600px|frameless]]<br>
Bluetooth control: support Android and iOS system  
 
'''Driving Motor'''  <br> 
According to the wiring diagram, default the jumper connection method.
Follow the table below to drive the 2 motors rotate by Digital, PWM pins, so as to control the robot car run.
The PWM value is in the range of 0-255. The greater the value set, the faster the motors rotate.<br>
[[File:0470-118.png|600px|frameless]]<br>
 
 
'''Test Code''' <br>
[[File:0470-119.png |600px|frameless]]<br>
'''Test Result'''<br>
Upload the code on the REV4 board successfully, wire according to the connection diagram, after power-on, the DIP dial switch is dialed to the "ON" end, the smart car forward for 2 seconds, back  for 2 seconds, stop for 2 seconds, rotate to left for 2 seconds, turn right for 2 seconds, alternating cycles.<br>
 
'''Knowledge'''<br>
1)Driving robot car to run by the library files in the code, which is simple and convenient. The length of code is saved.
2) Click [[File:0470-120.png |600px|frameless]]on Mixly, we can see the C code that is compatible with the Arduino IDE, so as to know how the smart car controls the rotation of the motor.<br>
 
 
'''Extension Practice'''<br>
Reset the movement track of robot car through the library,so as to drive running according to your requirements.<br>
 
== 4WD BT Robot Car Assembly Guide ==
 
Follow the assembly steps to build your own robot car.
 
1. Fix 4 motors on the bottom PCB board with 8 M3*30MM round-head screws, 8 M3*6MM round-head screws, 8 M3 nickel plated nuts and 4 black holders.
[[File:0470-121.png |600px|frameless]]<br>
2.Install the Keyestudio quick connectors tracking sensor on the bottom PCB board with 2 M3*8MM round-head screws and 2 M3 nickel-plated nuts.<br>
Fix 6 M3 *40MM double-pass copper pillars on the bottom PCB board with 6 M3*6MM round-head screws; at the same time, mount 4 wheels on the motor.<br>
[[File:0470-122.png |600px|frameless]][[File:0470-123.png|600px|frameless]]<br>
3.Fix Keyestudio 8X16 LED matrix onto the LED matrix acrylic baffle in front of the 4WD car with 4 M2X8MM round-head screws and 4 M2 nickel-plated nuts, and then connect the HX-2.54 4P to DuPont(female) line on the acrylic board.<br>
[[File:0470-124.png |600px|frameless]]<br>
 
4.Install the PTZ servo. Pay attention to set the servo to 90° before installation. When the ultrasonic module is facing  directly in front, the steering angle is 90°.
[[File:0470-125.png|600px|frameless]][[File:0470-126.png |600px|frameless]]<br>
5. Mount the ultrasonic sensor on the pan/tilt by two Nylon cables, and connect the JST-PH2.0mm-4P 2.54 DuPont line (female) to  the ultrasonic sensor.
[[File:0470-127.png |600px|frameless]] [[File:0470-128.png |600px|frameless]]<br>
6. Fix the control board on the bottom PCB board with 8 M3*6MM round-head screws and 4 M3*10MM double-pass copper pillars, and stack the motor drive boards on the control board.
[[File:QQ图片20191231131703.png|600px|frameless]][[File:QQ图片20191231131715.png|600px|frameless]]<br>
7.Fix the PTZ servo on the top PCB board with 8 M3*6MM round-head screws and 4 M3*10MM double-pass copper pillars.
  [[File:0470-131.png |600px|frameless]]<br>
8.Install 6 AA battery cases (or 2 18650 battery cases) on the top PCB board with 2 M3*10MM flat screws and 2 M3 nickel plated nuts; mount the Keyestudio quick connectors infrared receiver sensor on the PCB board with 1 M3*8MM round-head screw and 1 M3 nickel-plated nut and connect the two-head JST-PH2.0MM-3P line to the sensor.
[[File:0470-132.png |600px|frameless]][[File:0470-133.png |600px|frameless]]<br>
9.Connect the double-ended JST-PH2.0MM-5P cable to the Keyestudio quick connectors tracking sensor.<br>
[[File:0470-134.jpg |600px|frameless]]<br>
 
10.Install the accessories of step 9, 8, and 3 with 6 M3*6MM round-head screws.
[[File:0470-135.png|600px|frameless]]<br>
 
11.According to the wiring method,wire and correspond to the silk-screen on the acrylic board. There are M1 M2 M3 M4 interfaces on acrylic board correspond to 4 ports of motor on the drive board. As shown below.<br>
[[File:0470-136.png |300px|frameless]]          [[File:0470-137.png |300px|frameless]]<br>
 
12.The 8 jumper caps and the Keyestudio HM-10 Bluetooth-4.0 are plugged into the motor driving board and the installation is complete.
Note: when uploading the test code, you need to remove the Keyestudio HM-10 Bluetooth-4.0, and then reconnect the code after successfully uploading, otherwise the upload code fails.
[[File:0470-138.png|400px|frameless]]          [[File:0470-139.png|400px|frameless]]<br>
 
== Getting Started with for 4WD BT Robot Car Projects ==
=== <span style="color:blue">Project 8: Line Tracking Robot Car</span> ===
'''Circuit Design'''
In the above sections we already introduced the various sensors, modules, and expansion board and other hardware.
In the project, we make the robot detect black line at the car bottom with line tracking sensor. Then control the 2 motors rotation by measured result, so as to drive the robot track black line.
<span style="color:blue">Below is a specific logic table of line tracking robot car for your reference:</span>
<br>[[File:0470-144.png|600px|frameless]]<br>
 
'''Building Line Tracking Robot:'''
We start making smart cars according to the design ideas. We need to design the corresponding wiring, test code, then upload code and run to ensure that the smart car can achieve the ideal function.
 
'''Wiring Diagram''' <br>
<br>[[File:0470-141.png|600px|frameless]]<br>
'''Test Code'''<br>
<br>[[File:0470-142.png|600px|frameless]]<br>
 
'''Test Result'''<br>
Upload the code on the REV4 board successfully. Stack the expansion board on the REV4 board and wire it according to connection diagram. After power-on, the DIP switch will be dialed to the “ON” end, and the smart car can walk along the black line.
 
=== Project 9: Ultrasonic Follow Robot Car ===
'''Circuit Design''' <br>
We combine the hardware knowledge -- various sensors, modules, motor drive, to build an ultrasonic follow robot car!
In the circuit process, we can make use of ultrasonic sensor to detect the distance between robot car and front obstacles. Control the motor rotating by measured data, thus control the motion of robot car.
The specific logic of ultrasonic follow robot car is as shown below:
<br>[[File:0470-143.png |600px|frameless]]<br>
 
'''Building Ultrasonic Follow Car''' <br>
After designing the smart car, we start making smart cars according to the design ideas. We need to design the corresponding wiring, test the code, and then wire and upload code to drive, ensuring that the smart car can achieve the ideal function.
 
'''Wiring Diagram''' <br>
<br>[[File:0470-145.png |600px|frameless]]<br>
'''Test Code'''<br>
<br>[[File:0470-146.png |600px|frameless]]<br>
 
'''Test Result'''<br>
Upload the code on the REV4 board successfully, wire according to connection diagram wiring, after the DIP switch is dialed to the right end, the smart car can move with the movement of the obstacle ahead (only on one line, can not turn)
 
=== Project 10: Ultrasonic Avoiding Smart Car ===
'''Circuit Design''' <br>
We combine the hardware knowledge -- LED matrix, motor drive, ultrasonic and servo, to build an ultrasonic avoiding robot!
In the circuit process, we can make use of ultrasonic sensor to detect the distance between robot and front obstacles. Control the motor rotating by measured data, thus control the robot motion and show the running state by dot matrix.
The ultrasonic avoiding capability is almost the same as the ultrasonic following function. We only need to change the source code.
 
'''The specific logic of ultrasonic avoiding smart car is as shown below:'''
<br>[[File:0470-147.png|600px|frameless]]<br>
 
'''Building Ultrasonic Avoiding Smart Car'''<br>
After designing the smart car, we start making smart cars according to the design ideas. We need to design the corresponding wiring, test the code, then wire and the upload code to drive, ensuring that the smart car can achieve the ideal function.
 
'''Wiring Diagram''' <br>
<br>[[File:0470-148.png|600px|frameless]]<br>
'''Test Code''' <br>
<br>[[File:0470-149.png|600px|frameless]]<br>
 
'''Test Result''' <br>
After uploading the code on the REV4 board, wire according to connection diagram. After the DIP switch is dialed to the right end, the smart car can automatically avoid obstacles.
 
=== Project 11: IR Remote Control Smart Car ===
'''Circuit Design''' <br>
We combine the hardware knowledge -- sensors, motor drive, and IR receiver, to build an infrared remote control robot car!
In the IR receiver section, we’ve listed out each key value of remote control. In this circuit design, we can set the key value in the code to navigate the robot car movement. The corresponding state pattern is displayed on the 8X16 LED matrix.
 
<span style=color:"gray">The specific logic of infrared remote control robot car is shown below:</span>
<br>[[File:0470-150.png |600px|frameless]]<br>
Based on the circuit design, we can start building our own remote control robot.
 
'''Wiring Diagram'''<br>
<br>[[File:0470-151.png|600px|frameless]]<br>
'''Test Code'''<br>
<br>[[File:0470-152.png|600px|frameless]]<br>
 
'''Test Result'''<br>
After uploading the code successfully on the REV4 board, wire according to the connection diagram, after DIP switch is dialed to the right end, we can use the infrared remote control to control the smart car movement. At the same time, the 8X16 LED light board displays the corresponding state pattern.
 
=== Project 12: Bluetooth Control Smart Car ===
 
'''Circuit Design''' <br>
We are now ready to give the turtle robot capability -- Bluetooth remote control!
For a control smart robot, there should be a control terminal and a controlled terminal.
In the course, we use the mobile phone as the console (host), and the HM-10 Bluetooth module (slave) connected to the robot as the controlled terminal.
When using it, we need to install an APP on the phone, and connect the HM-10 Bluetooth module, then we tap the buttons on the Bluetooth APP to navigate the various motion states of robot car.
 
'''Bluetooth Remote Control''' <br>
 
Bluetooth technology is a wireless standard technology that enables short-distance data exchange between fixed devices, mobile devices, and building personal area networks (using UHF radio waves in the ISM band of 2.4 to 2.485 GHz).
 
The robot kit is equipped with the HM-10 Bluetooth module, which is a master-slave machine. When use as the Host, it can send commands to the slave actively; when use as the Slave, it can only receive commands from the host.
 
The HM-10 Bluetooth module supports the Bluetooth 4.0 protocol, which not only supports Android mobile, but also supports iOS system.
In the experiment, we default use the HM-10 Bluetooth module as a Slave and the cellphone as a Host.
We install the Bluetooth APP on the mobile phone, connecting the Bluetooth module; finally use the Bluetooth APP to control the robot car move, or to control the working status of other sensor modules on the robot car. We provide you with 2 types of mobile APP, for Android and iOS system. In the experiment, connect the Bluetooth module by mobile Bluetooth APP, tap the front button on the Bluetooth APP to control the LED matrix displaying front image; release the button, display the “STOP”. <br>
 
'''Parameters of HM-10 Bluetooth Module:''' <br>
Bluetooth protocol: Bluetooth Specification V4.0 BLE
No byte limit in serial port Transceiving
In open environment, realize 100m ultra-distance communication with iphone4s
* USB protocol: USB V2.0
* Working frequency: 2.4GHz ISM band
* Modulation method: GFSK(Gaussian Frequency Shift Keying)
* Transmission power: -23dbm, -6dbm, 0dbm, 6dbm, can be modified by AT command.
* Sensitivity: ≤-84dBm at 0.1% BER
* Transmission rate: Asynchronous: 6K bytes ; Synchronous: 6k Bytes
* Security feature: Authentication and encryption
* Supporting service: Central & Peripheral UUID FFE0, FFE1
* Power consumption: Auto sleep mode, stand by current 400uA~800uA, 8.5mA during transmission.
* Power supply: 5V DC
* Working temperature: -5 to +65 Centigrade
 
 
'''Using Bluetooth APP'''<br>
 
For Android system: <br>
1.There is link for downloading in the file. Download and install directly, installed well, appear the icon below on your mobile phone:
<br>[[File:0470-153.png|300px|frameless]]<br>
2.Click above icon to enter app, as shown below: 
<br>[[File:0470-154.png |300px|frameless]]<br>
3.Done uploading the code to REV4 board, connect the Bluetooth module, the LED on the Bluetooth module will flash.
Click on APP [[File:0470-155.png|100px|frameless]]icon,searching the Bluetooth.
4.Click to connect the Bluetooth. HMSoft connected, Bluetooth LED will turn on normally.
<br>[[File:0470-156.png|400px|frameless]]<br>
 
'''Wiring Diagram'''
<br>[[File:0470-158.png|700px|frameless]]<br>
 
'''Test Code'''<br>
<span style="color:red>Special Note: Before uploading the test code, you need to remove the Bluetooth module, otherwise the test code will fail to upload. After the code is uploaded successful, then reconnect the Bluetooth module.</span>
 
'''Test Result'''<br>
After uploading the Test Code on the control board, wire according to connection diagram and install the Bluetooth app on your phone. After powering on the control board with USB cable, open the serial port monitor, set the baud rate to 9600, the Bluetooth indicator flashes, and enter the mobile APP to connect to Bluetooth. After successful connection, press the button of the Bluetooth APP, and the corresponding characters are displayed in the serial monitor. For more details, as shown below.
<br>[[File:0470-159.png|500px|frameless]]<br>
 
'''Circuit Design'''<br>
In the previous lesson we tested the control characters on the phone app. We only need use the buttons on the APP to control the sensor modules and  driver board on the smart car, so as to control smart car via Bluetooth.
<span style="color:blue>Below is 4D Robot Car Bluetooth APP interface and we have listed out what function of each key does</span>
<br>[[File:0470-160.png |500px|frameless]]<br>
 
'''Circuit Design'''<br>
After designing the smart car according to the previous ideas, we need to start making smart cars according to the design ideas. We need to design the corresponding wiring, test code, and then wire the upload code to run, to ensure that the smart car can achieve the desired function.
 
'''Wiring Diagram'''<br>
<br>[[File:0470-161.png |600px|frameless]]<br>
'''Test Code'''
<br>[[File:0470-162.png|600px|frameless]]<br>
 
'''Test Result'''<br>
Upload the code on the REV4  board successfully. Stack the expansion board on the REV4 board and wire it according to the connection diagram. After power-on, the DIP switch will be dialed to the “ON” end. After connecting Bluetooth successfully, we can use the mobile APP to control the smart car to move.
 
=== Project 13: Bluetooth Multifunctional Robot car ===
'''Circuit Design''' <br>
How to build a multifunctional robot combined with all the functions we’ve learned? In this circuit, we use a complete code to program the smart car to switch different functions with Bluetooth APP, pretty simple and easy.
 
'''Wiring Diagram''' <br>
  <br>[[File:0470-163.png|1000px|frameless]]<br>
'''Test Code'''
<br>[[File:0470-164.png |1000px|frameless]]<br>
 
 
'''Test Result''' <br>
Upload the code on the REV4 board successfully. Stack the expansion board on the REV4 board and wire it according to the connection diagram. After power-on, the DIP switch will be dialed to the “ON” end. After connecting to Bluetooth successfully, we can use the mobile APP to control the smart car to move. We can achieve the corresponding function by pressing the corresponding button.
 
==Get One Now ==
*[  '''Official Websie''']
 
 
 


<br>
== Product List ==

Revision as of 17:49, 8 September 2020

Thanks for your support on our products, we will continue to provide you better quality and service!

  • About keyestudio

Keyestudio is a best-selling brand owned by KEYES Corporation, our product lines range from controller boards, shields and sensor modules to smart car and complete starter kits for Arduino, Raspberry Pi and BBC micro:bit, which designed for customers of any level to learn electronics and programming knowledge. All of our products comply with international quality standards and are greatly appreciated in a variety of different markets throughout the world.

You can obtain the details and the latest information through visiting the following web sites:http://www.keyestudio.com

  • References and After-sales Service

1.Download Profile:https://fs.keyestudio.com/KS0470

2.Feel free to contact us please, if there is missing part or you encounter some troubles. Welcome to send email to us:service@keyestudio.com. We will update projects and products continuously based on your sincere advice.

  • Warning

1.This product contains tiny parts(screws, copper pillars), keep it out of reach of children under 7 years old please.
2.This product contains conductive parts (control board and electronic module). Please operate according to the requirements of this tutorial. Improper operation may cause overheating and damage parts. Do not touch and immediately disconnect the circuit power.

  • Copyright

The keyestudio trademark and logo are the copyright of KEYES DIY ROBOT co.,LTD. All products under keyestudio brand can’t be copied, sold and resold without authorization by anyone or company. If you’re interested in our items, please contact to our sales representatives: fennie@keyestudio.com


Introduction

Nowadays, technological education such as VR, kids programming, and artificial intelligence, has become mainstream in educational industry. Thereby, people attach importance to STEAM education. Arduino is pretty notable in Maker education.

So what is Arduino? Arduino is an open-source electronics platform based on easy-to-use hardware and software. Arduino boards are able to read inputs - light on a sensor, a finger on a button, or a Twitter message - and turn it into an output - activating a motor, turning on an LED, publishing something online. Based on this, Keyestudio team has designed a 4wd robot. It has a processor which is programmable using the Arduino IDE, to mapped its pins to sensors and actuators by a shield that plug in the processor, it reads sensors and controls the actuators and decides how to operate.

15 learning projects, from simple to complex, will guide you how to make a smart 4wd robot on you own and introduce the detailed knowledge about sensors and modules.

Simultaneously, it is the best choice if you intend to obtain a DIY robot for learning programming, entertainment and competition requirement.


Features

1.Multi-purpose function: Obstacle avoidance, follow, IR remote control, Bluetooth control, ultrasonic follow and displayed face emoticons. 2. Simple assembly: No soldering circuit required, complete assembly easily. 3. High Tenacity: Aluminum alloy bracket, metal motors, high quality wheels and tracks 4. High extension: expand other sensors and modules through motor driver shield and sensor shield 5. Multiple controls: IR remote control, App control(IOS and Android system) 6.Basic programming:C language code of Arduino IDE.

Specification

Working voltage: 5v Input voltage: 7-12V Maximum output current: 2A Maximum power dissipation: 25W (T=75℃) Motor speed: 5V 200 rpm/min Motor drive mode: dual H bridge drive Ultrasonic induction angle: <15 degrees Ultrasonic detection distance: 2cm-400cm Infrared remote control distance: 10 meters (measured) Bluetooth remote control distance: 50 meters (measured) Bluetooth control: support Android and iOS system

Product List