RCA Module

Module RCA is a female jack terminal block for transmitting composite video (audio or video), one of the most common A/V connectors, which transmits video or audio signals from a component device to an output device (i.e., a display or speaker).

Support the following products:

RCAModule

Micropython Example:

 1# SPDX-FileCopyrightText: 2024 M5Stack Technology CO LTD
 2#
 3# SPDX-License-Identifier: MIT
 4
 5import os, sys, io
 6import M5
 7from M5 import *
 8from module import RCAModule
 9
10
11label0 = None
12label1 = None
13module_rca = None
14
15
16def setup():
17    global label0, label1, module_rca
18
19    M5.begin()
20    Widgets.fillScreen(0x222222)
21    label0 = Widgets.Label("Core2", 133, 109, 1.0, 0xFFFFFF, 0x222222, Widgets.FONTS.DejaVu18)
22
23    module_rca = RCAModule(
24        26,
25        width=216,
26        height=144,
27        output_width=0,
28        output_height=0,
29        signal_type=RCAModule.NTSC,
30        use_psram=0,
31        output_level=0,
32    )
33    label1 = Widgets.Label(
34        "RCA", 88, 61, 1.0, 0xFFFFFF, 0x222222, Widgets.FONTS.DejaVu18, module_rca
35    )
36
37
38def loop():
39    global label0, label1, module_rca
40    M5.update()
41
42
43if __name__ == "__main__":
44    try:
45        setup()
46        while True:
47            loop()
48    except (Exception, KeyboardInterrupt) as e:
49        try:
50            from utility import print_error_msg
51
52            print_error_msg(e)
53        except ImportError:
54            print("please update to latest firmware")

UIFLOW2 Example:

example.png

core2_rca_example.m5f2

class RCAModule

Constructors

class RCAModule(port: int = 26, width: int = 216, height: int = 144, output_width: int = 216, output_height: int = 144, signal_type: int = 0, use_psram: int = 0, output_level: int = 0)

Initialize the Module RCA

参数:
  • port (tuple) – The port to which the Module RCA is connected. port[0]: not used, port[1]: dac pin.

  • width (int) – The width of the RCA display.

  • height (int) – The height of the RCA display.

  • output_width (int) – The width of the output of the RCA display.

  • output_height (int) – The height of the output of the RCA display.

  • signal_type (int) – The signal type of the RCA display. NTSC=0, NTSC_J=1, PAL=2, PAL_M=3, PAL_N=4.

  • use_psram (int) – The use of psram of the RCA display.

  • output_level (int) – The output level of the RCA display.

UIFLOW2:

init.png

Methods