TFT CP23
2.3" - 320x240 Color Touch Display
- Overview
- Commands
- Samples
- On-Module Code
A 2.3" 320×240 full-color TFT display with optional capacitive multi-touch. Render text and graphics with simple text commands over any supported interface, using the engine's Graphics library — the same drawing code works on any DUELink display.
Common uses: handheld instrument readouts, control panels, classroom data dashboards, retro game projects, and custom UIs where size matters.
Key features • Full Color 320x240 Pixels | Resources 📄 Schematics PID: 0x010007 |
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.
The commands below set the display up. To draw on it, use the engine's built-in Graphics library — the same drawing functions (Line, Text, Rect, Show, etc.) render to any display in the DUELink catalog, so the same drawing code works no matter which display you have connected.
| Function | Description |
|---|---|
Init(m,o) | Initialize display m mode (buffered = 0 , direct = 1). o orientation (landscape = 0, portrait = 1). Init(0, 0) automatically called on power-up. |
GetW() | Get display width: 106 in buffered, 320 in direct. |
GetH() | Get display height: 80 in buffered, 240 in direct. |
IsColor() | Returns 1. |
TouchX() | Returns touch x. |
TouchY() | Returns touch y. |
SetDACtrl(s,r,c,b) | Data access control s swapRowCol, r invertRow, c invertCol, b swapBGRSet data access control. |
SetWindow(x,y,w,h) | Sets draw window x display's x value, y display's y value., w display's width value, h display's height value. |
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.
- Script
- Python
- MicroPython
- JavaScript
- .NET
- Arduino
- MicroBlocks
loading...
loading...
loading...
loading...
loading...
loading...
This sample runs in MicroBlocks on a any host board that's connected/tethered to this module, or a chain of modules. This module keeps its official DUELink firmware and module driver and responds to commands from the connected MicroBlocks-running host. New here? See the MicroBlocks page.
There are two ways to use it:
Open the full sample — the complete project (the module's library plus a ready-to-run example) opens directly on the MicroBlocks website.
Add just the libraries to your own project — copy the link, then in your MicroBlocks project click Add Library → Cloud and paste it. This loads this module's libraries into your project without replacing your current work.
Copy Library LinkCode 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 TFT CP23 (No Touch) | GDL-DSTFTCP23-B-NA | $29.95 |
| DUELink TFT CP23 (w/ Capacitive Touch) | GDL-DSTFTCP23-B-CP | $39.95 |