Skip to content

[G6] Drop setColorDepth controller command — SWITCH_GRAYSCALE (0x06) is dropped on G6 #28

Description

@mbreiser

Summary

setColorDepth maps to the controller opcode SWITCH_GRAYSCALE (0x06), which is dropped on G6 (the G6 firmware rejects it). On G6, grayscale (GS2/GS16) is a property of the .pat / SD-card header, not a runtime controller command. We just hard-dropped it from the web tools (see below) and should do the same in maDisplayTools so a G6 protocol carrying setColorDepth errors rather than silently emitting a dropped opcode.

Firmware basis

LED-Display_G6_Firmware_Arena/src/CommandProcessor.cpp returns an error for SWITCH_GRAYSCALE ("dropped for G6"); the opcode is absent from the G6 command surface.

MATLAB references to address

  • experimentExecution/CommandExecutor.m:109case 'setColorDepth'arenaController.setColorDepth(gs_val)
  • utils/validate_protocol_for_sd_card.m:690 — protocol validation accepts setColorDepth (should reject for G6)
  • controller/PanelsController.m:803 and controller/PanelsControllerNative.m:739setColorDepth() sends 0x06
  • examples/oldButFunctional/G41_Commands_Demo.m:148 — demo reference

Suggested handling

Treat setColorDepth as an unsupported/error-generating command for G6 protocols (the SD/.pat header carries grayscale). If G4.1 still accepts 0x06, gate by generation rather than removing the method outright — maintainer's call.

Cross-reference

Done on the web side in webDisplayTools PR reiserlab/webDisplayTools#101 (LAB-97): dropped from the controller palette (js/plugin-registry.js), flagged "unsupported" in the v3 editor, and errored-then-skipped by the arena runner. Filed from that work per the LAB-97 brief.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions