Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RDM Buffer too small - truncated received messages and fails OLA rdm-tests #46

Open
riwalker opened this issue Jan 31, 2023 · 2 comments

Comments

@riwalker
Copy link

I notice that the receive buffer is 60 BYTES ?
// the byte array used while receiving and sending.
byte buffer[60];

RDM allows 231 Bytes, so why set at 60 ?

I noticed this as the OLA rdm-tests fail several tests, like E120_DEVICE_LABEL, > 32char
when set to 60, it truncates the RDM message at exactly 32char (I don't know why a buffer of 60 truncates the RDM Data at 32bytes)?
when i increase the buffer to [231] - we now capture the NACK for > 32 char test

BUT, not that the buffer is [231] it fails 41 instead of 6 !!!
any ideas ?

@peternewman
Copy link
Contributor

I notice that the receive buffer is 60 BYTES ? // the byte array used while receiving and sending. byte buffer[60]; RDM allows 231 Bytes, so why set at 60 ?

Hi @riwalker

This was fixed here:
https://github.com/mathertel/DmxSerial2/blame/98cdfc932de94a096e63033c18560dc69eb9f12c/src/DMXSerial2.cpp#L266-L270

And previously here:
https://github.com/mathertel/DmxSerial2/blame/98cdfc932de94a096e63033c18560dc69eb9f12c/src/DMXSerial2.h#L98

Specifically in e1f293e

You'll need to either use Git or ask @mathertel nicely to release a new version.

I noticed this as the OLA rdm-tests fail several tests, like E120_DEVICE_LABEL, > 32char when set to 60, it truncates the RDM message at exactly 32char (I don't know why a buffer of 60 truncates the RDM Data at 32bytes)? when i increase the buffer to [231] - we now capture the NACK for > 32 char test

The string should always be truncated by RDM at 32 bytes the other test checks for different responses when nacking a message that's too long but fits in the buffer from one that doesn't.

BUT, not that the buffer is [231] it fails 41 instead of 6 !!! any ideas ?

What do you mean by 41 instead of 6? Tests? If so can you list which ones, ideally with debug output. It's probably just more slow EEPROM turnaround time.

@riwalker
Copy link
Author

riwalker commented Feb 3, 2023 via email

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

No branches or pull requests

2 participants