This is only a preview of the September 2025 issue of Practical Electronics. You can view 0 of the 80 pages in the full issue. Articles in this series:
Items relevant to "Compact Hi-Fi Headphone Amplifier, part one":
Articles in this series:
Articles in this series:
Articles in this series:
Articles in this series:
Articles in this series:
|
Low-cost Electronic Modules
Using Electronic Modules with Jim Rowe
0.91-inch monochrome
OLED screen
Small monochrome OLED display modules have
become widely available at a low cost in the last
few years. This one is just 37.5 × 11.5 × 4.5mm
but has a 128 × 32 pixel display that’s either white or blue.
With its I2C serial interface it can be easily driven by a microcontroller.
I
n the September 2024 issue, we
reviewed the ‘big brother’ of this
OLED module, with a display measuring 1.3 inches or 33mm diagonally.
It had 128 × 64 pixels – twice that
of this module – along with an I2C
serial interface. We have used the 1.3inch module in several projects, like
the Multi-Stage Buck/Boost Charger
Adaptor project in the October 2023
issue.
We have also used smaller OLED displays in various projects. For example,
a 0.96in module with 128 × 64 pixels
was used in these projects:
» LC Meter Mk3, November 2023
» Advanced Test Tweezers,
February & March 2024
And there’s an even smaller 0.49in
OLED display with 64 × 32 pixels
that we used in the SMD Test Tweezers project from the October 2022
issue.
The main difference between the
current module and all of those others
is that the ‘active area’ of its display
is wider but shorter: 22.4mm wide
by 5.6mm high. Since it has 128 × 32
pixels, that means that it provides a
display basically equivalent to the
top or bottom half of the 1.3in OLED
module.
We obtained the module shown in
the photos from a supplier on AliExpress for ~£1. Another supplier on
AliExpress had it for ~£.50, while it
was on eBay for ~£6. All the prices
listed above are exclusive of postage costs.
all use a single interface/controller
and OLED driver IC, usually either
the SH1106 device from Sino Wealth
or the SSD1306 device from Solomon Systech. The same controllers
are also used in many of the larger
modules.
Fig.1 is a block diagram of the
SH1106 and the SSD1306 interface/
controllers. At upper left is the microcontroller (MCU) interface, which can
be configured to interface with an MCU
via an 8-bit 6800/8080 parallel interface, a 3- or 4-wire SPI interface or an
I2C serial interface. Most of the OLED
modules currently available use the
I2C interface, including the one we’re
looking at here.
Display data from the MCU is stored
in the Data RAM just to the right of
the interface block. The SH1106 and
SSD1306 controllers both have around
1024 bytes of Data RAM, enough for
a 128 × 64 pixel display. Since the
Inside these OLED modules
Fig.1: the block diagram of the SH1106 and SSD1306 OLED driver controller
ICs. The SSD1306 has a slightly bigger internal RAM, letting it store 132 x 64
pixels (four more pixels horizontally than the SH1106).
The 0.91in (23mm) OLED modules
12
0.91in OLED only has 32 rows, only
half of the Data RAM is used in this
module.
The Display Controller block to the
right of the Data RAM takes data from
the RAM and displays it on the OLEDs
via the page and segment drivers at the
right-hand end of Fig.1.
The MCU can also send commands
to the controller, which pass from the
MCU interface to the Command Decoder block below it in Fig.1. The commands can be used to update the display, turn it on or off, set its addressing
mode, set the column starting address
and adjust the display contrast and
brightness (the latter also determining its operating current).
The SH1106 and SSD1306 devices both come in very thin (0.3mm)
SMD packages with over 260 contact pads. In the modules, they are
mounted directly on the rear of the
OLED screen.
Practical Electronics | September | 2025
0.91-inch OLED screen module
Fig.2: a common circuit diagram for
the 0.91in OLED modules using an
SSD1306 controller.
The module’s circuit
Fig.2 shows the circuit of a typical
0.91in monochrome OLED module
based on the SSD1306 device. As you
can see, it’s very similar to that of the
1.3in OLED module we looked at in
the September 2024 issue, although a
little simpler.
The circuitry to the left of the OLED
provides the power supply and assists
with the I2C interface. These components are all mounted on the rear of
the module’s PCB. Four-pin SIL header
CON1 at far left handles both the power
input and the I2C interface.
REG1 takes the incoming Vcc and
steps it down to +3.3V to run the OLED
and its controller. The +3.3V line is
also used to drive the controller’s reset
circuit (it needs to be reset as soon as
power is applied) and provides the
reference for the 4.7kW pull-up resistors used on the I2C interface lines,
SCL and SDA.
Before we move on to more practical things like driving one of the
modules from an MCU, Fig.3 shows
how the SH1106 and SSD1306 controllers save the display data in their
Data RAM, and how it is shown on the
OLED screen. This is achieved by setting them to what is described as Page
Addressing Mode.
In this mode, the OLED screen is
divided into eight horizontal ‘pages’,
where each page consists of 128 vertical segments eight pixels high. The
pages are themselves arranged vertically, with page 0 along the top
of the screen, page 1 immediately
below it and the remaining pages
descending.
With the 0.91in OLED module,
though, the pages and segments are
used rather differently. In this case,
Practical Electronics | September | 2025
Fig.3: the SH1106 and SSD1306 controllers save their display data into
RAM using column-major order.
The OLED module’s PCB measures just 37.5mm
wide, 11.5mm tall and the module is only
4.5mm deep, making it ideal for compact
designs. You can see it at actual size in the
adjacent image.
13
Low-cost Electronic Modules
Fig.4: how to connect
the 0.91in OLED
module to an Arduino
Uno or similar.
only every second segment byte of each
page is used (segments 0, 2, 4 and so
on), and only four bits are used in each
segment byte (bit 0, bit 2, bit 4 and bit
6). These four data bits are then used
to display the four upper pixels in that
segment of the OLED.
The data for the lower four pixels
of that OLED segment come from the
next page in the controller’s RAM,
which is organised in the same way:
only every second segment is used,
and only the four bits are used in each
segment byte.
I think you’ll agree that this all
seems a bit weird, but that’s the way
data is organised in the 0.91in OLED
modules.
Now we can turn our attention to
what is involved in driving one of
these modules from an MCU like an
Arduino Uno or a Micromite.
Connecting it to an Arduino
Fig.5: connecting the OLED module to a Micromite
Plus Explore 64 are just as simple as an Arduino.
If instead you’re operating the module with a
Micromite Mk2 or BackPack, then the SCL pin of
the module connects to pin 17 of the Micromite,
and the SDA pin connects to pin 18.
An example photo of the OLED module connected to a Micromite via a
breadboard.
The underside of the OLED module shown enlarged for clarity. All components
except for the screen are mounted to this side.
14
Connecting the OLED module to
an Arduino Uno (or compatible) is
quite straightforward, as you can see
from Fig.4.
The GND and Vcc pins connect to the
GND and 3.3V pins om the Arduino,
while the SCL and SDA pins connect to
the Arduino’s A5 (SCL) and A4 (SDA)
pins, respectively.
You can also connect the OLED
module to an Arduino Uno R4
Minima, simply by connecting the
module’s SCL pin to pin 17 of the
Minima and the SDA pin to the Minima’s pin 16.
As for software to drive the OLED
module, if you go to www.arduino.
cc and look at the library listings
for ‘Display’ applications (https://
pemag.au/link/abw5), you will find
quite a few libraries intended to do
this job.
The first one I found was Adafruit’s
SSD1306 library, with the latest version (V2.5.9) able to handle OLED displays with either 128 × 64 or 128 ×
32 pixels. It also relies on using their
GFX library.
The Adafruit library comes with
five example sketches, including
one called SSD1306_128x32_i2c.ino
– which is the one most suitable for
use with the 128 × 32 pixel OLED
module.
When you run this sketch, it gives
you a series of graphics and text displays, including those shown in the
lead photo on page 12. As you can see,
the 128 × 32 OLED’s display is quite
Practical Electronics | September | 2025
0.91-inch OLED screen module
small, but can display a useful amount
of information.
Connecting it to a Micromite
It’s also quite easy to connect the
OLED module to a Micromite MCU.
Fig.5 shows the connections needed
for a Micromite Plus Explore 64 and,
as you can see, they are just as straightforward as driving the module from
an Arduino.
Connecting the module to a Micromite Mk2 or LCD Backpack V1/V2/V3
would be almost the same, except the
module’s SCL pin would be connected to pin 17 of the Micromite and the
SDA pin to pin 18.
As with an Arduino, you also need
some software. It turns out that this isn’t
quite as easy as with the Arduinos, as
it’s much harder to find any Micromite
OLED driver software.
As I related in the October 2023 article, I could write an MMBasic program to display text and simple graphics on the 1.3in OLED module, with
some much appreciated help from
Silicon Chip staff member Tim Blythman. Since the 0.91in OLED modules
use the same SSD1306 controller, I deGET
LATES THE
T COP
Y
OF
TEACH OUR
-IN SE
RIES
AVAIL
AB
NOW! LE
cided to try adapting that program to
work with them.
But that approach didn’t work with
the 0.91in module, even when I tried
quite a few modifications to the program – the OLED’s display remained
stubbornly dark. So once again, I asked
Tim for help (sorry, Tim). And as before,
he provided a lot of help.
Tim searched around The Back
Shed (www.thebackshed.com/forum)
and found some valuable information
I had missed concerning MMBasic
programming of the various OLED
modules.
He found a driver written by MM
Basic programming guru Peter Mather
and soon came up with his own working program by combining elements of
Peter Mather’s driver with a few ideas
taken from my program for testing the
1.3in OLED module.
Tim sent me his new program by
email, and when I tried it out, I found
it worked very well. So I added a few
comments, plus code to display a full
four lines of text instead of the single
line that Tim had provided. You can
see the display produced by this program on page 14 (opposite).
The program is called “091in OLED
TB version.bas” and you can download
it from https://pemag.au/Shop/6/454
As before, it’s a fairly straightforward program, and as it stands it only
demonstrates how to drive the OLED
module to display text and very simple
graphic symbols.
In its present state, it doesn’t let
you type text in via the Micromite
console and display it directly on
the OLED, as that would involve a
fair bit of additional code.
Hopefully it will make it easy for
those who want to display up to four
lines of text and basic symbols on the
screen of one of the 0.91in OLED modules from a Micromite to do so. I’d
like to thank Tim Blythman for help
in producing this MMBasic program
for the Micromite.
Useful links
• Interfacing the 0.91in OLED with
an Arduino Uno: https://pemag.au/
link/abw6
• OLED breakouts: https://pemag.
au/link/abw7
• LCDwiki MC091GX user manual:
PE
https://pemag.au/link/abw8
ON SALE in WHSmith and other
independent newsagents
PRICE £8.99
EE
FR -ROM
CD
ELECTRONICS
TEACH-IN 9
GET TESTING!
Electronic test equipment and measuring
techniques, plus eight projects to build
FREE
CD-ROM
TWO TEACH
-INs
FOR THE PRICE
OF ONE
• Multimeters and a multimeter checker
• Oscilloscopes plus a scope calibrator
• AC Millivoltmeters with a range extender
• Digital measurements plus a logic probe
• Frequency measurements and a signal generator
• Component measurements plus a semiconductor
junction tester
(includes P&P to UK if ordered direct from us)
Teach-In 9 – Get Testing!
£8.99
FROM THE PUBLISHERS OF
PIC n’ Mix
Including Practical Digital Signal Processing
PLUS...
YOUR GUIDE TO THE BBC MICROBIT
Teach-In 9
A LOW-COST ARM-BASED SINGLE-BOARD
COMPUTER
This series of articles provides a broad-based introduction to choosing and using a wide
range of test gear, how to get the best out of each item and the pitfalls to avoid. It provides hints and tips on using, and – just as importantly – interpreting the results that
you get. The series deals with familiar test gear as well as equipment designed for more
specialised applications.
The articles have been designed to have the broadest possible appeal and are applicable
to all branches of electronics. The series crosses the boundaries of analog and digital electronics with applications that
span the full range of electronics – from a single-stage transistor amplifier to the most sophisticated microcontroller
system. There really is something for everyone!
Each part includes a simple but useful practical test gear project that will build into a handy gadget that will
either extend the features, ranges and usability of an existing item of test equipment or that will serve as a standalone instrument. We’ve kept the cost of these projects as low as possible, and most of them can be built for less
than £10.
Get Testing
Three Microchip
PICkit 4 Debugger
Guides
Files for:
PIC n’ Mix
PLUS
Teach-In 2 -Using
PIC Microcontrollers.
In PDF format
© 2018 Wimborne Publishing Ltd.
www.epemag.com
Teach In 9 Cover.indd 1
01/08/2018 19:56
FREE COVER-MOUNTED CD-ROM
On the free cover-mounted CD-ROM you will find the software for the PIC n’ Mix series of articles. Plus the full TeachIn 2 book – Using PIC Microcontrollers – A practical introduction – in PDF format.
ORDER YOUR COPY TODAY: www.electronpublishing.com
Practical Electronics | September | 2025
15
|