Using Pico:ed V2 board as a replacement for BBC Micro:bit

We’ve received a sample of the Pico:ed V2 board developed by ELECFREAKS and will show how to use it as a replacement for the BBC micro:bit in a project using CircuitPython.

We’ve already covered the board in detail with specifications, block diagram, and pinout diagram before, and it’s basically a Raspberry Pi Pico RP2040 board with BBC Micro:bit form factor including a 17×7 Dot Matrix LED display, some buttons, a buzzer, but no wireless connectivity, relying only on USB instead.

CircuitPython firmware installation on the Pico:ed V2 board

The board supports C/C++, MicroPython, and CircuitPython programming languages, and for this review, we’ve decided to download the CircuitPython UF2 firmware.

Pico:ed v2 circuitpython firmware

Press and hold the BOOTSEL button after having downloaded the firmware file…

Pico:ed V2 python Bootsel

… and connect the board to your computer using a USB cable before releasing the BOOSEL button on the Pico:ed V2 board, which should then show up as the “RPI-RP2” drive in your file manager.

Pico:ed V2 RPI-RP2 Drive

Now drag the previously downloaded UF2 file to the “RPI-RP2” drive and once the installation is complete, the “RPI-RP2” drive will disappear and the “CIRCUITPY” drive will appear in its place.

CIRCUITPY drive

That’s all you have to do to install the CircuitPython firmware, and you can start writing programs in code.py file in the CIRCUITPY drive.

code.py circuitpython

Programming the Pico:ed V2 board

We’ll use the Thonny Python IDE for programming which can install on Windows, Linux, macOS, or even run from a Raspberry Pi SBC. Once the installation is complete, open Thonny, then click on the “Run” menu and select “Configure interpreter” and select “CircuitPython(generic)” as we did with the Wukong 2040 review.

Thonny CircuitPython Interpreter

 

Testing the onboard LED

We have to start somewhere and the easiest is to program the onboard LED on the Pico:ed V2 board to blink.

Pico:ed V2 LED Indicator

Blinky code:

Buttons programming

The Pico:ed V2 board also comes with two buttons which can be programmed individually or in combination.

Pico ed V2 Buttons

The test code will display a number starting at 0. If the A button is pressed, the number will be -1, and if the B button is pressed, the number will be +1.

Making the Pico:ed V2 buzzer play music

The board is also equipped with a passive buzzer which can be programmed to play sounds according to different types of music notes and also has more than 20 ready-made song commands as follows:

  • DADADADUM, ENTERTAINER, PRELUDE, ODE
  • NYAN, RINGTONE, FUNK, BLUES,
  • BIRTHDAY, WEDDING, FUNERAL, PUNCHLINE
  • PYTHON, BADDY, CHASE, BA_DING, WAWAWAWAA
  • JUMP_UP JUMP_DOWN POWER_UP POWER_DOWN

Pico:ed V2 Buzzer

Here’s the code to play DADADADUM:


It could not be easier than that, but we can also write code to play music as defined in a music score.

LED DOT Matrix

The ELECFREAKS board’s 7×17 LED dot matrix is driven by an IS31FL3731 chip to display graphics and text.

Pico ed V2 LED matrix

Sample code to show text and numbers:


The firmware also supports over 25 preset graphics display commands:

  • NO, SQUARE, RECTANGLE, RHOMBUS, TARGET
  • CHESSBOARD, HAPPY, SAD, YES, HEART
  • TRIANGLE, CHAGRIN, SMILING_FACE, CRY, DOWNCAST
  • LOOK_RIGHT, LOOK_LEFT, TONGUE, PEEK_RIGHT, PEEK_LEFT
  • TEAR_EYES, PROUD, SNEER_LEFT, SNEER_RIGHT, SUPERCILIOUS_LOOK, EXCITED

Pico:ed V2 review LED DOT Matrix graphics

Here’s the code to display the HAPPY graphic as shown in the top left corner of the photo above:


Below is some sample code to display custom graphics with each number in the arrays representing the individual brightness of the LED with 1 being the dimmest, 9 being the brightest.

Using the Pico:ed V2 with accessories for the BBC Micro:bit V2 board

The Pico:ed V2 has the same edge connector as the BBC Micro:bit board compatible with accessories as well as the 5 larger pads suitable for crocodile clips.

BBC Micro:Bit Edge Connector

In order to test BBC Micro:bit compatibility, we’ll use the Pico:ed V2 board with an RGB:BIT board to drive 16 RGB lights (WS2812B) by connecting PIN16 (P16). We call this project the RGB Light Box. The structure is custom-designed and 3D printed, and the project is powered by two 3V AAA batteries.

Pico:ed V2 with BBC Micro:Bit Expansion Board

We’ll need to install Adafruit’s Neopixel library in order to program the WS2812B RGB LED with CircuitPython. Download it and copy it into the “lib” directory on the “CIRCUITPY” drive.

neopixel ibrary circuitpythonWe have then inserted the Pico:ed V2 into the RGB:BIT board and written a test program to light the RGB lights in rainbow style.

Pico:ed V2 BBC Micro:bit Alternative

Here’s the code:


Assemble everything together and you will get a beautiful RGB Light Box that can change colors using the color chasing effect.

RGB Light Box

The code below is for the RGB LED color chasing demo:


Summary

The Pico:ed V2 board has a cute and colorful design and is user-friendly thanks to BBC Micro:bit compatibility and support for CircuitPuython programming language, as well as C/C++ and visual (drag-and-drop) programming. The board can be used to teach electronics and programming with many of the existing modules and is suitable for children in the classroom.

We were able to replace the BBC Micro:bit with the Pico:ed V2 Raspberry Pi RP2040 board in our own project with an RGB LED add-on board initially designed for the Micro:bit, but we had less luck with a SUMO ROBOT project where the Pico:ed V2 would not work. So compatibility with the Micro:bit board will depend on the specific extension board, and your mileage may vary.

We would like to thank ELECFREAKS for sending a Pico:ed V2 board for review and testing. The Pico:ed V2 can be purchased on Amazon or ELECFREAKS’ own store.

This guide/review is an adaption of the tutorial first published in Thai language on CNX Software Thailand.

Share this:

Support CNX Software! Donate via cryptocurrencies, become a Patron on Patreon, or purchase goods on Amazon or Aliexpress

Radxa Orion O6 Armv9 mini-ITX motherboard
Subscribe
Notify of
guest
The comment form collects your name, email and content to allow us keep track of the comments placed on the website. Please read and accept our website Terms and Privacy Policy to post a comment.
2 Comments
oldest
newest
Peter Mathijssen
1 year ago

Maybe you could add that the Pico:ed board also works great with MicroBlocks.

Boardcon Rockchip RK3588S SBC with 8K, WiFI 6, 4G LTE, NVME SSD, HDMI 2.1...