📷MU Camera

Function introduction

Petoi Intelligent Vision Sensor can recognize many objects with a deep-learning algorithm. For example, it can detect color blocks, balls, the human body, and cards. Its detection result can be transmitted through the UART or I2C interface. MU is compact, has low power consumption, processes all algorithms locally, and can be widely used in intelligent toys, AI+STEAM lessons, creators, and other products or fields.

BiBoard

Hardware setup

BiBoard V1 for Bittle X V2 / Bittle X+Arm / Nybble Q

BiBoard V0 for Bittle X

circle-info

Note: The position of the left and right switches (left: down and up; right: down and down) must be dialed to the position shown in Figure 1.

Fix the end connected to the camera to the robot's head (included in Bittle's / Bittle X's mouth).

Software setup

Petoi Desktop App

You can use the Firmware Uploaderarrow-up-right within the Petoi Desktop App.

Please select the correct Product type, Borard version, and Serial port. The mode should be Standard, so press the Upgrade the Firmware button. for example, Bittle, BiBoard_V0_2, COM5 as follows:

After uploading, open the serial monitor and use the serial command "XC" to switch to using the camera mode.

Arduino IDE

  1. First, download and install the MU camera libraryarrow-up-right into the Arduino IDEarrow-up-right.

2. Use Arduino IDE to upload the sketcharrow-up-right(OpenCatEsp32.ino).

Use the latest OpenCatESP32 source code to finish the setup. For example, to modify the code for Bittle as shown below:

After uploading, open the serial monitorarrow-up-right and use the serial command "XC" to switch to using the camera mode.

NyBoard for Bittle / Nybble

Hardware setup

After uploading the firmware, switch the dial (left: down and up; right: down and down) on the MU Vision Sensor and connect to the mainboard with wire as shown in the following picture:

Figure 1

Software setup

Petoi Desktop App

  • You can use the Firmware Uploaderarrow-up-right within the Petoi Desktop App. Please select the correct Product type, Borard version, and Serial port. The mode should be Camera, so press the Upgrade the Firmware button. for example, Bittle, NyBoard_V1_2, COM5 as follows:

Arduino IDE

  1. First, download and install the MU camera libraryarrow-up-right into your Arduino IDE.

2. Use the latest OpenCatarrow-up-right code to finish the setup.

Use the latest OpenCat code to finish the setup. For example, to modify the code for Bittle as shown below:

If you have already uploaded the latest OpenCat code to make Bittle walk, you only need to uncomment #define CAMERA At the beginning of OpenCat.ino, then upload the code.

If unsure, you need to finish the upload process for the standard modearrow-up-right (Step 1 to Step 10) to ensure everything is configured correctly, then upload the code in the camera mode.

If the camera code is uploaded correctly, Bittle maintains the rest position. Success messages are printed on the serial monitorarrow-up-right of Arduino IDE. When the MU Vision Sensor recognizes a target, the two LEDs will turn blue, and Bittle's head can follow the target and swing left and right. The demo code will auto-switch the target between a yellow tennis ball and a human body if it fails to find any object.

Arduino code demo

The demo video is as follows:

FAQ

circle-info

If the MU Vision Sensor cannot identify the target object, please press the reset button on the camera and then the reset button on the main board.

circle-exclamation

This module also supports the following development environments:

  • MicroPython APIs

  • Mixly IDE

  • MakeCode IDE

For more details, please refer to the Technical Support Documentarrow-up-right.

Last updated