pdf-icon

UIFlow Guide

UIFlow 1.0 Blockly

Event

Unit

UIFlow 1.0 Project

Timer Camera

Function Description
Timer Camera will capture images at specified intervals and upload them to the server after burning timer firmware. Other devices in UIFlow can use Timer Camera function to get the latest frame and display it on the screen, and configure the same token as the device to get the image content of the corresponding device.

Example

from m5stack import *
from m5stack_ui import *
from uiflow import *
from MediaTrans.TimerCam import TimerCam

screen = M5Screen()
screen.clean_screen()
screen.set_screen_bg_color(0xFFFFFF)

cam = TimerCam('08d1f96ae2f0bc54b4998407c937e99d', 0, 0, 320, 240)
cam.show()

API

from MediaTrans.TimerCam import TimerCam
cam = TimerCam('08d1f96ae2f0bc54b4998407c937e99d', 0, 0, 320, 240)
  • Initialize the TimerCAM image display service, and pass in the device token.
cam.show()
  • Enable image display
cam.hide()
  • Image hiding
cam.delete()
  • Release TimerCAM Image Display Service
On This Page