Example Code for micro:bit-Mind+ Graphical Programming

This project uses Mind+ graphical programming with the micro:bit to control the MU Vision Sensor for number card detection. The detection result is displayed on the micro:bit.

Hardware Preparation

  • micro:bit x 1
  • MU Vision Sensor x 1
  • Connectors x 1

Software Preparation

Wiring Diagram

SEN0314 MU Vision Sensor Microbit and MU

Other Preparation Work

  1. Set the DIP switches:
    Output Mode: DIP 1 down, DIP 2 up
    Device Address: DIP 1 down, DIP 2 down (sets the address to 0x60)

  2. Open Mind+ and switch to Offline mode.

  3. Click Extension to load a controller such as micro:bit or mPython, then add the SEN0314 MU Vision Sensor extension.

    SEN0314 MU Vision Sensor Load module SEN0314 MU Vision Sensor Sensor Block
  4. Connect the device to your computer and upload the program.

Sample Code

Select the target device and start programming.
Taking the micro:bit as an example, use the Mind+ graphical blocks as shown below:

SEN0314 MU Vision Sensor Programming

Result

When the sensor detects the number card, the recognition result will be displayed on the micro:bit.(Switch Output DIP 1 down, 2 up; Switch Address DIP 1 down, 2 down.)

Was this article helpful?

TOP