Skip to content

d500: add RS2_OPTION_DUAL_RGB_RECTIFICATION for D585 2C USB - #15625

Merged
Nir-Az merged 4 commits into
realsenseai:developmentfrom
Nir-Az:dual-rgb-rectification
Sep 3, 2026
Merged

Nir-Az merged 4 commits into
realsenseai:developmentfrom
Nir-Az:dual-rgb-rectification

Conversation

@Nir-Az

@Nir-Az Nir-Az commented Sep 1, 2026 •

Copy link
Copy Markdown
Collaborator

Overview: Adds a boolean option on D585 2C USB that asks the firmware to rectify the two RGB streams.

Tracked on [RSDEV-13331]

Why

The firmware exposes its dual-RGB rectification toggle only through a custom HWM command, so there was no SDK control for it and callers had to send raw HWM bytes.

Summary

  • New bool option on the Stereo Module of D585 2C USB (PIDs 0x0C04 / 0x0C07), registered from rs5x5_device behind a minimum-firmware check (7.58.46064.14668).
  • Backed by HWM CUSTOM_CMD (0x80) sub-command 0x29. Rejected while streaming — depth and both color pins share the sensor. The value is validated before it reaches firmware.
  • The firmware has no read command, so the option caches the last value set, and the device constructor writes the default (off) once so the reported value matches the device. Temporary until the firmware defines a dedicated XU.
  • If that initial write fails the option is not registered, so it never appears on firmware that rejects it.

Test plan

  • D585 2C proto (PID 0C07, FW 7.58.46075.14610), validated locally: set/query, range default 0, set blocked while streaming, option absent on the 3C PID (0C08).
  • CDC log confirms the firmware receives it: customCmdSetDualRgbRectify: 0/1, ret=0.
  • LibCI

Open items

  • On FW 7.58.46075.14610 the command is acknowledged but IR and color frames are unchanged (off-vs-on pixel diff at or below the off-vs-off noise floor, and the firmware logs identical RGB GDC rectified calibration both ways). Firmware-side wiring is pending.

🤖 Generated by AI

@sysrsbuild-gh-agentic sysrsbuild-gh-agentic left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Automated code review by rs-agentic bot.

Comment thread src/ds/d500/d500-options.cpp Resolved
Comment thread src/ds/d500/d500-factory.cpp Resolved
alexkunin-gh
alexkunin-gh previously approved these changes Sep 2, 2026
@Nir-Az
Nir-Az merged commit cb2a8c7 into realsenseai:development Sep 3, 2026
34 checks passed
@Nir-Az
Nir-Az deleted the dual-rgb-rectification branch September 3, 2026 12:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants