DuePi
Raspberry Pi HAT Adapter
- Overview
- Commands
- Samples
- On-Module Code
A Raspberry Pi HAT that adds DUELink to any Raspberry Pi — fits all Pi models including Pi Zero (the breakable Holey section trims the board down to Zero size). The top half plugs into the standard 40-pin RPi header; the bottom half is a 5 mm-pitch grid for mounting DUELink modules right on the same board.
Built-in peripherals on the HAT — a 0.96" graphical OLED display, two user buttons, and a piezo buzzer — drive directly from your Pi with simple text commands over any supported interface. The OLED uses the engine's Graphics library, so the display becomes part of your DUELink draw pipeline rather than a separate Linux framebuffer.
An on-board 800 mA regulator powers the Downlink chain independently, keeping load off the Pi's 3.3 V rail. A USB-C connector is available for firmware updates — leave it disconnected when the Pi is the host.
Pins on the terminal block are DUELink GPIO, not Pi GPIO — so they can handle real-time tasks like driving servo motors and addressable LEDs (WS2811/WS2812 strips) that are notoriously hard from a Raspberry Pi alone, where Linux's lack of real-time scheduling makes PWM jitter and timing glitches unavoidable without specialized hardware.
For a basic, lower-cost adapter without on-board peripherals, see RPILink.
With the USB connector and the on-board regulator, DuePi can also run as a standalone microcomputer without a Pi attached.
Key features • Attaches to Raspberry Pi or Pi Zero Header | Resources 📄 Schematics PID: 0x0A0004 |
Modules ship without cables to reduce waste. Some specialty boards include a USB cable; for the rest, see Cables to add cables to your order.
Commands this module accepts. See Samples for runnable code in popular host languages.
| Function | Description |
|---|---|
GetW() | Get display width: 128. |
GetH() | Get display height: 64. |
IsColor() | Returns 0. |
BtnA() | Returns 1 if button A is pressed. |
BtnB() | Returns 1 if button B is pressed. |
Buzzer(f,d) | Plays buzzer to f frequency(50 to 15K) for d duration in milliseconds. |
DVer() | This driver version. |
Peek under the hood
The script below is this module's driver — it teaches the hardware how to respond to the commands listed above. It ships pre-loaded from the factory; most users never need to open it.
loading...
Example code that calls this module's commands from popular host languages.
New here? See Get Started to connect a module and send your first command.
- Python
- JavaScript
- .NET
loading...
loading...
loading...
Code that runs directly on this module's MCU. See how On-Module Code allows modules to run standalone.
- Script
- Arduino IDE
This example runs using the default DUELink Internal Engine using its Scripting Language, and it expects the module's driver to be loaded first, see the Commands Tab.
loading...
See Arduino IDE page for more info.
loading...
Ordering Info
| Product | Part Number | Price |
|---|---|---|
| DUELink DuePi | GDL-ADDUEPI-B | $14.95 |