Feature Request: Add Screen Capture and Camera Save API for Tab5
Summary
The M5Stack Tab5 has a built-in camera and a 1280x720 display, but UIFlow2 v2.4.4
provides no way to save either the screen contents or camera frames to a file.
This makes the camera essentially non-functional for any practical use case, and
prevents screen capture for debugging, documentation, or sharing purposes.
Device Information
- Board: M5Stack Tab5
- SoC: ESP32-P4 (with hardware image processing unit) + ESP32-C6
- UIFlow2 Version: v2.4.4
- MicroPython Version: v1.27.0-dirty (2026-04-22)
Current Situation
What IS available in M5.Lcd (confirmed via dir()):
['clear', 'close', 'print', 'read', 'write', 'COLOR', 'EPDMode', 'FONTS',
'drawArc', 'drawBmp', 'drawCenterString', 'drawCircle', 'drawEllipse',
'drawEllipseArc', 'drawImage', 'drawJpg', 'drawLine', 'drawPixel', 'drawPng',
'drawQR', 'drawRawBuf', 'drawRect', 'drawRightString', 'drawRoundRect',
'drawString', 'drawTriangle', 'endWrite', 'fillArc', 'fillCircle', 'fillEllipse',
'fillEllipseArc', 'fillRect', 'fillRoundRect', 'fillScreen', 'fillTriangle',
'fontHeight', 'getBrightness', 'getColorDepth', 'getCursor', 'getEpdMode',
'getRotation', 'height', 'isEPD', 'loadFont', 'lvgl_deinit', 'lvgl_flush',
'lvgl_init', 'lvgl_read', 'newCanvas', 'powerSaveOff', 'powerSaveOn', 'printf',
'readData', 'readData16', 'readData32', 'setBrightness', 'setColorDepth',
'setCursor', 'setEpdMode', 'setFont', 'setRotation', 'setTextColor',
'setTextScroll', 'setTextSize', 'show', 'startWrite', 'textWidth', 'unloadFont',
'user_lvgl_flush', 'width', 'writeCommand', 'writeCommand16', 'writeData',
'writeData16', 'writeData32']
What is MISSING:
- No
saveCapture(), saveBmp(), saveJpg() or any equivalent
- No camera capture-to-file API
- No framebuffer access from MicroPython
Why This Is a Significant Gap
1. The camera is a headline feature of the Tab5
The Tab5 is marketed with a built-in camera. Without the ability to save camera
frames to a file, the camera cannot be used for any practical application:
- No photo capture
- No timelapse
- No image logging
- No computer vision with saved output
The camera can display a live feed on screen but the frames cannot be persisted
in any way.
2. All required hardware is already present
The ESP32-P4 contains a hardware image processing unit (ISP) specifically
designed for camera and image processing tasks. JPEG encoding is hardware
accelerated and would be extremely fast and memory efficient.
3. The JPEG codec is already in the firmware
M5.Lcd.drawJpg() already exists and works — proving the JPEG decoder is
present in the firmware. Adding a JPEG encoder path to save images is the
logical complement to this existing functionality.
4. Storage is available
The Tab5 has:
- 16MB internal flash
- microSD card slot
Both are accessible from MicroPython and suitable for image storage.
5. BMP is impractical — JPEG is the right format
A raw BMP screenshot at 1280x720 in 16-bit colour = ~1.8MB per image.
This would fill flash storage in seconds.
A JPEG screenshot of a typical UI at reasonable quality would be
approximately 50-150KB — practical for regular use.
The hardware JPEG encoder on ESP32-P4 makes this entirely feasible without
significant CPU overhead.
6. Pixel-by-pixel workaround is impractical
While readData16 exists, reading 921,600 pixels individually from Python
would take approximately 15 minutes per screenshot. This is not a viable
workaround.
Requested APIs
Screen capture:
# Save current screen contents to JPEG
M5.Lcd.saveJpg("/flash/screenshot.jpg", quality=85)
# Save current screen contents to PNG
M5.Lcd.savePng("/flash/screenshot.png")
Camera capture:
# Capture a single frame from the camera to file
M5.Camera.saveJpg("/flash/photo.jpg", quality=85)
# Get raw camera frame as bytes for processing
frame = M5.Camera.capture()
Impact
This feature request affects every Tab5 user regardless of their use case.
The camera is a core hardware feature of the Tab5 that is currently non-functional
for any practical purpose. Adding save capability would unlock:
- Photography applications
- Computer vision projects
- Screen capture for debugging and documentation
- Timelapse and monitoring applications
- QR code scanning with save
- Any application that needs to persist visual data
Additional Note
This feature request is filed alongside bug report #94 (fatal crash on
sta.scan()). Both issues significantly limit the Tab5's usefulness in its
current firmware state. The Tab5 is capable hardware that deserves firmware
support to match its potential.
Feature Request: Add Screen Capture and Camera Save API for Tab5
Summary
The M5Stack Tab5 has a built-in camera and a 1280x720 display, but UIFlow2 v2.4.4
provides no way to save either the screen contents or camera frames to a file.
This makes the camera essentially non-functional for any practical use case, and
prevents screen capture for debugging, documentation, or sharing purposes.
Device Information
Current Situation
What IS available in M5.Lcd (confirmed via dir()):
What is MISSING:
saveCapture(),saveBmp(),saveJpg()or any equivalentWhy This Is a Significant Gap
1. The camera is a headline feature of the Tab5
The Tab5 is marketed with a built-in camera. Without the ability to save camera
frames to a file, the camera cannot be used for any practical application:
The camera can display a live feed on screen but the frames cannot be persisted
in any way.
2. All required hardware is already present
The ESP32-P4 contains a hardware image processing unit (ISP) specifically
designed for camera and image processing tasks. JPEG encoding is hardware
accelerated and would be extremely fast and memory efficient.
3. The JPEG codec is already in the firmware
M5.Lcd.drawJpg()already exists and works — proving the JPEG decoder ispresent in the firmware. Adding a JPEG encoder path to save images is the
logical complement to this existing functionality.
4. Storage is available
The Tab5 has:
Both are accessible from MicroPython and suitable for image storage.
5. BMP is impractical — JPEG is the right format
A raw BMP screenshot at 1280x720 in 16-bit colour = ~1.8MB per image.
This would fill flash storage in seconds.
A JPEG screenshot of a typical UI at reasonable quality would be
approximately 50-150KB — practical for regular use.
The hardware JPEG encoder on ESP32-P4 makes this entirely feasible without
significant CPU overhead.
6. Pixel-by-pixel workaround is impractical
While
readData16exists, reading 921,600 pixels individually from Pythonwould take approximately 15 minutes per screenshot. This is not a viable
workaround.
Requested APIs
Screen capture:
Camera capture:
Impact
This feature request affects every Tab5 user regardless of their use case.
The camera is a core hardware feature of the Tab5 that is currently non-functional
for any practical purpose. Adding save capability would unlock:
Additional Note
This feature request is filed alongside bug report #94 (fatal crash on
sta.scan()). Both issues significantly limit the Tab5's usefulness in itscurrent firmware state. The Tab5 is capable hardware that deserves firmware
support to match its potential.