RGBMatrix: document constructor arguments

Closes: #8283
This commit is contained in:
Jeff Epler 2023-08-22 10:30:57 -05:00
parent 283889bb57
commit 485924896e
No known key found for this signature in database
GPG Key ID: D5BF15AB975AB4DE

View File

@ -186,7 +186,22 @@ STATIC void preflight_pins_or_throw(uint8_t clock_pin, uint8_t *rgb_pins, uint8_
//| flicker during updates.
//|
//| A RGBMatrix is often used in conjunction with a
//| `framebufferio.FramebufferDisplay`."""
//| `framebufferio.FramebufferDisplay`.
//|
//| :param int width: The overall width of the display in pixels
//| :param int height: The overall height of all displays in pixels
//| :param int tile: In a multi-row display, the number of rows of panels
//| :param int bit_depth: The color depth of the display. A value of 1 gives 8 colors, a value of 2 gives 64 colors, and so on. Increasing bit depth increases the CPU and RAM usage of the RGBMatrix, and may lower the panel refresh rate. The framebuffer is always in RGB565 format regardless of the bit depth setting
//| :param bool serpentine: In a multi-row display, True when alternate rows are rotated 180°, which can reduce wiring length
//| :param Sequence[digitalio.DigitalInOut] rgb_pins: The display's "RGB pins"
//| :param Sequence[digitalio.DigitalInOut] addr_pins: The display's "address pins"
//| :param digitalio.DigitalInOut clock_pin: The display's "clock pin"
//| :param digitalio.DigitalInOut latch_pin: The display's "latch pin"
//| :param digitalio.DigitalInOut output_enable_pin: The display's "output enable" pin
//| :param bool doublebuffer: True if the output is double-buffered
//| :param Optional[WriteableBuffer] framebuffer: A pre-allocated framebuffer to use. If unspecified, a framebuffer is allocated
//|
//| """
STATIC mp_obj_t rgbmatrix_rgbmatrix_make_new(const mp_obj_type_t *type, size_t n_args, size_t n_kw, const mp_obj_t *all_args) {
enum { ARG_width, ARG_bit_depth, ARG_rgb_list, ARG_addr_list,