Notice: Function _load_textdomain_just_in_time was called incorrectly. Translation loading for the health-check domain was triggered too early. This is usually an indicator for some code in the plugin or theme running too early. Translations should be loaded at the init action or later. Please see Debugging in WordPress for more information. (This message was added in version 6.7.0.) in /var/www/wp-includes/functions.php on line 6114
Raspberry Pi Pico with OLED Display - Electric DIY Lab

Raspberry Pi Pico with OLED Display

OLEDPICOThumbnail

Hello,

In this article we are going to interface OLED display with Raspberry Pi Pico

If you are new to Raspberry Pi Pico and wants to get started then click here.
here you can learn the basics of how to start with raspberry Pi Pico.

List of required components is given below.

Video

Required Components

Raspberry Pi Pico

OLED Display

Jumper Wires

Bread Board

Schematic Diagram

Schematic Diagram Raspberry Pi Pico OLED Display

Follow this schematic diagram and make connections.

GND Pin of display with GND Pin of Raspberry Pi Pico

Vcc Pin of display with 3.3V Pin of Raspberry Pi Pico

SCL Pin of display with GP9 Pin of Raspberry Pi Pico

SDA Pin of OLED display with GP8 Pin of Raspberry Pi Pico

Coding

To write and upload program here i used Thonny IDE. You can download from here.

Here i write code in micropython.

There are two files for code. One is a library for OLED display and another is a main code file.

Main code is given below

import machine
import ssd1306
import time

oled = ssd1306.SSD1306_I2C(128, 64, machine.I2C(0))

oled.text("Hello everyone", 0, 0)
oled.show()
time.sleep(2)
oled.text("Welcome to my", 0, 10)
oled.text("channel", 0, 20)
oled.show()
time.sleep(2)
oled.text("Thank You", 0, 30)
oled.show()

Save this code in Raspberry Pi Pico and name it main.py

Now press run button.