Skip to content

Conversation

@hideakitai
Copy link
Owner

Close #125

Experimental support for RDM

@hideakitai hideakitai self-assigned this Jun 1, 2025
@hideakitai hideakitai mentioned this pull request Jun 1, 2025
@hideakitai hideakitai marked this pull request as draft June 1, 2025 06:16
@hideakitai hideakitai requested a review from Copilot June 1, 2025 06:20
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Adds experimental support for RDM (Remote Device Management) over Art-Net, including new APIs, example sketches, and documentation.

  • Introduced RDM/TOD send/receive APIs in Sender.h and Receiver.h
  • Added WiFi and Ethernet example sketches for RDM device and controller
  • Extended README with RDM section and updated API reference

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
examples/WiFi/rdm_example/rdm_example.ino New WiFi RDM device example demonstrating subscribe/send flows
examples/WiFi/rdm_controller/rdm_controller.ino New WiFi RDM controller example for discovery and device commands
examples/Ethernet/rdm_example/rdm_example.ino New Ethernet RDM device example
README.md Added RDM section, examples, and send/subscribe API documentation
Artnet/Sender.h Added sendArtRdm*, sendArtTod* methods
Artnet/Receiver.h Added subscribeArtRdm*, unsubscribeArtRdm*, and OpCode handling
Artnet/ArtRdm.h Introduced RDM, RDMSub, TOD request/data/control packet formats
Comments suppressed due to low confidence (2)

Artnet/ArtRdm.h:199

  • [nitpick] The field name add_count is ambiguous; renaming it to address_count or addr_count would improve clarity for consumers of this metadata.
uint8_t add_count;

Artnet/ArtRdm.h:46

  • [nitpick] Consider adding unit tests for RDM metadata parsing and packet serialization functions (generateMetadataFromOpRdm, setMetadataToOpRdm, etc.) to verify correct behavior and prevent regressions.
inline Metadata generateMetadataFromOpRdm(const uint8_t* packet) {

case OpCode::TodRequest: {
if (this->callback_art_tod_request) {
art_tod_request::Metadata metadata = art_tod_request::generateMetadataFromOpTodRequest(this->packet.data());
this->callback_art_tod_request((uint16_t*)(this->packet.data() + art_tod_request::ADDRESS), metadata.add_count, metadata, remote_info);
Copy link

Copilot AI Jun 1, 2025

Choose a reason for hiding this comment

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

Casting raw packet bytes to uint16_t* may cause unaligned memory access on some platforms; consider manually parsing each 16-bit address into a local uint16_t array before invoking the callback.

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

RDM?

2 participants