FAQs on Product Specifications
How much load can CyberPi working in combination with Pocket Shield bear?
For common electronic modules instead of motors or servos, no more than 10 modules are recommended; for motors or servos, no more than 4 modules are recommended.
FAQs on the LAN communication of CyberPi
1. What is the working principle of LAN communication?
LAN commnunication between CyberPis is implemented based on the ESP-NOW protocol pf ESP32. Messages can be transmitted through Wi-Fi without Wi-Fi connection. The transmission, however, is not reliable. The data broadcast may fail to be received by the target device due to any one of the possible causes, such as that the LAN has not been started properly and the target device uses another Wi-Fi channel.
CyberPis on the same LAN can communicate with each other without Internet access. The communication is implemented in one-to-multiple mode. Generally, one CyberPi can broadcast data to any number of other CyberPis.
2. My two CyberPis fail to communicate with each other by broadcasting messages on the LAN, why?
CyberPis can’t communicate with each other by broadcasting messages on the same LAN if they use different Wi-Fi channels. One CyberPi can’t send data to or receive data from another one using a different Wi-Fi channel. Both the LAN broadcasting and Internet access (that is, visiting the Internet through a router) functions of CyberPi are performed based on Wi-Fi and they share one Wi-Fi channel. After you connect CyberPi to a router, the Wi-Fi channel used by CyberPi is the same as that used by the router, which may be different from the default Wi-Fi channel (channel 6) of CyberPi.
In the following scenarios, the two CyberPis fail to communicate with each other because they use different Wi-Fi channels:
CyberPi 1 is connected to router A, and CyberPi 2 is not (due to empty connection setting, incorrect password input, or out of connection range). If the channel used by router A is different from the deafult one (channel 6) of CyberPi, CyberPis 1 and 2 use different Wi-Fi channels and therefore can’t communicate with each other.
CyberPi 1 is connected to router A, and CyberPi 2 is connected to router B. CyberPis 1 and 2 can’t communicate with each other if rounters A and B use different Wi-Fi channels.
3. How do I ensure that two or more CyberPis properly communicate with each other by broadcasting messages on the LAN?
CyberPis can communicate with each other properly by broadcasting messages on the LAN as long as they use the same Wi-Fi channel.
You can ensure two or more CyberPis use the same Wi-Fi channel in either of the following ways:
Use only the LAN functions of CyberPis. Do not connect any of them to the Internet. In this case, all CyberPis use the default Wi-Fi channel, channel 6. If CyberPi has been connected to the Internet, you can set the Wi-Fi name and password to empty to disconnect it from the Internet. For example, the following program can be used to disconnect CyberPi from the Internet.
Connect all CyberPis to the Internet through the same router. After being connected to a router, CyberPi uses the same Wi-Fi channel as the router, and therefore all CyberPis connected to the same router use the same Wi-Fi channel. Thus, they can communicate with each other while maintaining the access to the Internet.
- Ensure that the data broadcast on a LAN is no more than 200 bytes. Otherwise, data may be lost.
- After you connect CyberPi to a router, the Wi-Fi channel it uses depends on the router. If a router uses channel 6, the default Wi-Fi channel of CyberPi, another CyberPi that is not connected to the router can communicate properly with the one connected.
- After being turned on, CyberPi attempts to connect to the Internet by default. If you have set a Wi-Fi connection for it, it may keep trying to connect to the Internet. Before the connection is complete, the Wi-Fi channel is not determined, and therefore the LAN communication may fail.
FAQs on the chassis and encoder motors
1. Turning errors occur when I control my mBot2, why?
mBot2 is assembled with multiple parts, including metal and plastic structural parts, of which the tolerance can’t be completely eliminated due to industrial limitations. Besides, a tolerance is allowed on the assembly of mBot2. All these tolerances may cause turning errors on the chassis of mBot2. This turning error, however, is quite stable and can be rectified by using a turning coefficient.
The following figure shows the program for rectifying the error:
We are now testing a chassis calibration mechanism to rectify the turning error caused by structural tolerances. So far, the turning error can be reduced significantly. You can download the mBot2 motion calibration test and drag it to the PC client of mBlock 5 to use the blocks for reducing the error.
2. How do I use the blocks for calibrating the chassis of mBot2?
When the gyro-based motor calibration (turning 720°) block is executed, CyberPi lights up its LEDs and turns off the LEDs after mBot2 has turned 720° and the value output of the gyro is stable. The calibration coefficient obtained is stored on CyberPi and is not deleted after CyberPi is powered off.
3. The accumulative error is large after an encoder motor runs multiple times, why?
This is what it is supposed to be. A certain error occurs every time the encoder motor runs, and the error is accumulative after mBot2 runs multiple times. For example, the error is large if the following blocks are executed:
We are making efforts to improve the motion of mBot2, and a new firmware version is expected to be released by the end of July to rectify the accumulative error.
FAQs on the quad RGB sensor
1. How are the line, background, and colors defined for the quad RGB sensor?
The quad RGB sensor provides two functions: line following and color recognition.
the quad RGB sensor needs to learn the line and background first.
Line and background learning: Place the sensor on the background and double-press the button on the sensor, and then swipe the sensor horizontally over the line and background.
For more information about line following, see Quad RGB Sensor.
The quad RGB sensor can recognize eight colors, namely black, red, green, cyan, blue, yellow, purple, and white.
Line following & color recognition
The quad RGB sensor can recognize colors while identifying a line and background.
For example, when identifying the black line on a white background, the quad RGB sensor can also recognize the colors on the line.
2. How do I use the quad RGB sensor?
With the quad RGB sensor, mBot2 can recognize colors while following a line.
The following is an example program.
After you press button A, mBot2 stops moving.
After you press button B, mBot2 starts to follow a line.
After you press in the middle of the joystick, the name of the detected color is diplayed on the screen of CyberPi.
How to change program names in CyberPi?
Change program names in mBlock through your PC.
Note: There are preset programs and My Programs in CyberPi, of which the preset programs can’t be renamed or overwritten by an uploaded program. (When you upload a new program while one of the preset programs is being executed, the first program in My Programs is overwritten by the new one. Its name is the default “main” unless it has been renamed.)
For example, steps to change the name of the third program in My Programs are as below:
- Choose My Programs- Program 3 in CyberPi and press the confirmation key to execute the program.
- Connect CyberPi to mBlock in your PC and follow the steps below.
- Restart your CyberPi when the program is uploaded. Open My Programs and then you can find the program successfully renamed.