Easy new OLED driver for the micro:bit

I love OLED displays! The 128×64 pixel ones are really cheap and easy to interface with a BBC micro:bit, Arduino or Raspberry Pi.

Here are a few things I’ve made with them:

One thing that’s been missing is a really good micro:bit driver or MakeCode extension for OLED displays.

The good folk at Kitronik have just released a new product, a micro:bit OLED display board. The good news is, their MakeCode extension also works with the cheap OLED displays I have lying around. (I’ve not tried the Python modules yet, but will do).

OLED display connected to micro:bit

It’s possible some other displays will have different I2C addresses, so you may need to tweak the code of the extension, but I was pleased to find mine worked with no changes.

This means you can use them with an OLED connected to a micro:bit’s I2C pins via a breakout board and 4 female-female jumper wires.

A couple of things I really like about their extension:

  • The text is small so you can get a useful amount of stuff on the screen
  • The ‘plot’ block, which is more useful than it sounds – it’s a really simple way of drawing live graphs of sensor data with a number to show the current reading. The graph even scrolls when it gets to the end, a lovely touch.

You can load Kitronik’s MakeCode extension pasting this URL into MakeCode: https://github.com/KitronikLtd/pxt-kitronik-128x64Display

Here’s just how simple the code is to put some text, a light reading number and plot a live graph using the Kitronik extension:

MakeCode blocks for plotting graph

If you don’t already have a breakout board and OLED display to hand, the Kitronik accessory just snaps on to your micro:bit’s edge connector, and leaves other pins free for connecting more goodies, which is an excellent feature. It’s currently £13.80 including VAT, which seems like a very reasonable price point for a well-supported accessory – though I must say I’ve not actually tested the Kitronik board itself, just their MakeCode extension!

This entry was posted in computers, microbit and tagged , , , . Bookmark the permalink.

Leave a Reply