Note: Update the firmware of mBot Mega to the factory version before using the preset programs. For details about updating firmware, see About mBot Mega.
Press any one of the impact switches for 2 seconds to switch between different preset functions. The color of the RGB LEDs indicates the function being used:
Green: gesture recognition
Yellow: obstacle avoidance
Blue: line following
Gesture recognition: default function at boot
- LED color: green
- Standby state: Both RGB modules are all in dark green.
- When the obstacle avoidance sensor detects an obstacle, the RGB LEDs change to bright green.
- The three obstacle avoidance modules assembled in the front can detect three states within 3-10cm:
- Swiping to the right: When the obstacle avoidance sensors 3, 2, or sensors 2, 1 detect signals successively, the robot moves about 10cm to the right. When the robot moves, the RGB LEDs on the right side are lit up in bright green, and when the robot stops, it returns to dark green.
- Swiping to the left: When the obstacle avoidance sensors 1, 2, or sensors 2, 3 detect signals successively, the robot moves about 10cm to the left. When the robot moves, the RGB LEDs on the left side are lit up in bright green, and when the robot stops, it returns to dark green.
- Pushing: When obstacle avoidance sensors 1 and 3 detect signals at the same time for more than 0.2 seconds, it is judged as a pushing gesture, the left and right RGB LEDs are lit up in bright green, and the robot moves backward.
- Stop moving when all the sensors fail to detect the signal, and the RGB LEDs return to dark green.
Automatic obstacle avoidance:
- LED color: yellow
- When no obstacle is detected, all LEDs are lit in dark yellow.
- When any infrared sensor detects an obstacle, all LEDs are lit up in bright yellow.
- After switching to automatic obstacle avoidance mode, it moves according to the state of three sensors:
- Forward: moves forward when none of the three sensors detect obstacles
- Turn left: When the sensor on the left detects an obstacle, it rotates clockwise about 90 degrees on the spot.
- Turn right: When the sensor on the right detects an obstacle, it rotates about 90 degrees counterclockwise on the spot.
- Backward: When the middle sensor detects an obstacle, it moves backward about 5cm.
- LED color: blue
- When the line-following sensor does not detect a black line, the RGB LEDs are lit up in dark blue.
- When the line-following sensor detects a black line, the RGB LEDs on the corresponding side are lit up in bright blue.
- After switching to the line-following mode, the robot starts line-following when any line-following sensor detects a black line; if the two line-following sensors cannot detect black lines, the robot rotates in place for 5 seconds until a black line is detected and then starts line-following. If no black line is detected after 5 seconds, the robot stops the movement and waits for the black line to be detected again and then starts the line following (waiting to be manually moved to a black line).
My mBot Mega does not seem to have any of the default programming, When switched on, the LEDs do not come on. In play mode, I can drive it, but it will not follow the line nor do obstacle avoidance.
Please sign in to leave a comment.