Car Kit - 图1

I Introduction

Car Kit makes it easy for you to assemble a color line following car. The car is constructed with only 4 modules through snap together magnetic connections: the color line follower, chassis, mainboard and battery. The kit additionally comes with three game maps for kids who are aged 6 or older to develop their skills and knowledge in math, problem solving and programming. We can use both the maps and the User Guide to find the magic of the car. After getting familiar with the modules, we can go to Codecraft to create our own programs for the car. Together using a Starter Kit which extends the possibilities of the car, we could implement more project ideas, such as a remote control car, a sound-activated car and a light-sensing car.

II Module Details

Items included in the kit are as follows: 1 color line follower, 1 chassis, 1 mainboard BLE, 1 battery, 1 USB cable, 3 game maps, 4 markers and 1 User Guide. Below is an informative table about the specific module details. You can click one of the small images to see a large version of the modules, or click More Info to know more about them.

Name Image Detail
Color Line Follower Car Kit - 图2 Using the built-in infrared LED, this sensor is able to detect a black track and recognize various colors on the ground. By connecting it to the chassis, you can get a cool, compact line following car. More Info
Chassis Car Kit - 图3 The chassis is composed of two electric motors to drive the wheels. Just a few seconds needed, you can implement a fun and functional car by snapping Grove Zero modules to it. More Info
Mainboard BLE Car Kit - 图4 It is a key component of your projects. Whatever programs you design, a flashing LED or an alarming buzzer, it will convert the received signals and command for the output modules to execute these actions. It is available to be factory reset after the Reset button is pressed and held for 6 seconds. More Info
Battery Car Kit - 图5 It provides power supply for the entire circuit system of your car. More Info

Car Kit - 图6

III Programming Environment

Codecraft

IV Tutorials

Part A: Non-Programming Projects

Project 1 Line Following Car

i Implementation

The car will drive along a black line.
Car Kit - 图7

ii Specific Steps

Open the Car Kit and assemble the car. Turn on the switch on the battery and ensure that the LED indicator flashes green. Then, bring out the map #1. Use a black marker to color the unfinished part of the track. Once you complete, put your car on the map and see how it works.
Car Kit - 图8


Project 2 Color Recognizer

i Implementation

The default program in the car allows it to follow a black line and recognize various colors that it sees, which, to be specific, is defined as: when seeing black, the car drives along it; when seeing green, it turns left; when seeing blue, it turns right; when seeing red, it stops.
Car Kit - 图9

ii Specific Steps

Open the Car Kit and assemble the car. Turn on the switch on the battery and ensure that the LED indicator flashes green. Then, bring out the map #2. Follow the instruction on the map, color those boxes and circles correspondingly. Once you complete, put the car on the map and see how it works.
Car Kit - 图10


Project 3 Sound-Activated Car

Besides the G0 modules in the kit, the car is also compatible with other modules from this series to bring interesting projects that have not been made before. For example, we can add a sound sensor to make a sound-activated car.

i Implementation

We use a sound sensor to measure the sound intensity from the world around us. In this project, our car is expected to start driving forward when it detects a sound and adjust its speed as the sound intensity varies. The greater the sound, the faster the car.
Car Kit - 图11

ii Specific Steps

Open the Car Kit and assemble the car. Turn on the switch on the battery and ensure that the LED indicator flashes green. Snap the sound sensor to the car. Note that we don’t need a color line follower this time. Then, let’s put the car on the white ground (not map) and see how it works.


Project 4 Line Following in Different Conditions

i Implementation

The car requires a calibration to ensuring consistent behavior in different line following conditions.
Car Kit - 图12

ii Specific Steps

When operating or running, the car may not follow a line precisely. In this case, it needs calibration. Follow the instruction below and learn how to do it:

  • Bring out the car and turn it on. Press and hold the button on the color line follower for 2 seconds until the LED indicator lights up and the car enters the calibration mode. Then release the button.
  • Put the line follower onto the black spot in Map #1. Short press the button, then the indicator blinks rapidly and the sensor starts calibrating. Once calibration completes, the indicator goes back to normal.
  • Place the sensor on a white surface. Double press the button, then the LED indicator blinks slowly and the sensor starts calibrating. Once calibration completes, the indicator goes back to normal.
  • Now the car is ready. Reconnect the modules and have fun with it.

Part B: Programming Projects

Project 1 Calculator Car

i Implementation

The car will first drive along a black line. But when it sees different colors, it will react to them differently.
Car Kit - 图13

ii Start Programming

Go to Codecraft and start coding under a Device mode.
First, add a When start block. Make a new variable and name it as points. The points are initially set as 0. Then we add a 4 Digit Display show block to show the points in real time.
Next, the program is going to perform decision making 3 times which follows a program logic below:
If the color line follower sees green, then the points will increase 50 and pause for 1 second;
If the color line follower sees blue, then the points will increase 100 and pause for 1 second;
If the color line follower sees red, then the points will decrease 50 and pause for 1 second.
Then, for the second part of our program, we will give the car an instruction which follows a same program logic in the Tutorial 1 of Bit Kit Help Documentation – make the car follow a black line. So, let’s go ahead and learn how to do this step exactly.
Car Kit - 图14

iii Connect a Device

Snap the mainboard, battery, chassis, color line follower and 4 digit display* together. Connect the mainboard to your PC with a USB cable. Ensure that the LED indicator on the mainboard lights up continuously.

* The 4 digit display is also known as seven-segment display, which is commonly used for displaying decimal numerals and basic character. We can use it to make a digital clock, time counter or calculator that display numerical information.

Car Kit - 图15

iv Upload a Program

You have installed the Codecraft Assistant from the previous tutorials. Just make sure it is enabled. Connect the device and click the Upload button on Codecraft, then the program will be uploaded successfully.
Before uploading the program to a device, you can also save it to the desktop or any locations you like in your computer. The steps are quite easy: Click Project → Select Save as → Name your project.

v Run a Program

Bring out the Map #3 and color the blank boxes and circles correspondingly. Then, power on the car and see how it works.


Project 2 Obstacle Avoidance

i Implementation

The car will first drive forward slowly. When it detects an obstacle ahead of it, it will make a left turn and then drive forward again.
Car Kit - 图16

ii Start Programming

Go to Codecraft and start coding under a Device mode.
First, add a When start block. Connect a Chassis go forward at low speed block underneath.
Next, add a forever block and connect an IF-THEN-ELSE statement into it. Follow this program logic, if the ultrasonic sensor detects an obstacle within a range of 15 cm, then the car will make a left turn slowly. If not, the car will go forward slowly.
Car Kit - 图17

iii Connect a Device

Snap the mainboard, battery and chassis together. Next, use a connection module to connect an ultrasonic sensor to the top of the car. Make sure the ultrasonic sensor stands straight against the ground. Then, connect the mainboard to your PC with a USB cable. Ensure that the LED indicator on the mainboard lights up continuously.

* The connection module can lengthen the circuit through a snap-together connection.

Car Kit - 图18

* The ultrasonic sensor is used for measuring the distance to an object, in centimeter by default.

Car Kit - 图19

iv Upload a Program

You have installed the Codecraft Assistant from the previous tutorials. Just make sure it is enabled. Connect the device and click the Upload button on Codecraft, then the program will be uploaded successfully.
Before uploading the program to a device, you can also save it to the desktop or any locations you like in your computer. The steps are quite easy: Click Project → Select Save as → Name your project.

v Run a Program

Put the car on a flat floor and show it an object in the front. Observe whether it can avoid the obstacle automatically.


Project 3 Remote Control Car

i Implementation

Use a twin-button module to control the car. When the button A is pressed, the car can drive fast forward. When the button B is pressed, it can drive slowly backward.
Car Kit - 图20

ii Start Programming

Go to Codecraft and start coding under a Device mode.
First, add a When start block.
The radio broadcasts message 1. Ensure that the controller and the car will receive a same message.
The car first drives forward slowly.
Next, add an IF-THEN-ELSE statement. Follow this program logic: if the button A is pressed, the radio broadcasts message 11; if button B is pressed, the radio broadcasts message 22.
Then, let’s program the mainboard that works as the car controller. If the car receives message 11, it drives fast forward; if it receives message 22, it drives slowly backward.
Car Kit - 图21

iii Connect a Device

You need two different mainboards to assemble a car and a controller. First, connect one of the mainboards, the battery and the chassis together to make a car. Next, connect the other mainboard, the battery and the twin-button* together to make the controller.

* The twin-button module is composed of two buttons labeled as A and B. It can detect a short press, a long press and an ongoing press-down action.

Car Kit - 图22

iv Upload a Program

You have installed the Codecraft Assistant from the previous tutorials. Just make sure it is enabled. Connect the device and click the Upload button on Codecraft, then the program will be uploaded successfully.
Before uploading the program to a device, you can also save it to the desktop or any locations you like in your computer. The steps are quite easy: Click Project → Select Save as → Name your project.

【Note: You need to upload this program to both the mainboards.】

v Run a Program

Put the car on a flat floor. Control the car with the buttons and see how it works.

V Course Materials

You can see related course materials about the Grove Zero and Car Kit on our online course platform Make2Learn via this address: https://make2learn.tinkergen.com/


VI Attachments

Attachment 1: Car Kit Tutorial Source Code

Attachment 2: Car Kit Maps