Skip to content

Added broadcast for (extended) accessory commands #445

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

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

reinder
Copy link

@reinder reinder commented Mar 28, 2025

This PR adds broadcast commands <y a ...> for accessory and <y A ...> for extended accessory. Similar to the <l ...> command for engines/locomotives.

Without these broadcasts it is impossible to track these accessory command when multiple clients are involved.

Closes #444

@Asbelos
Copy link
Contributor

Asbelos commented Mar 29, 2025

This or introduces a pervasive change to the standard parsing algorithms which treat letters after the opcode as uppercase regardless of the case used. Thus the client side parsers can't distinguish between <y a and <y A.

It's important to consider the wider implications before implementing an apparently simple modification.

@Asbelos Asbelos closed this Mar 29, 2025
@Asbelos Asbelos reopened this Mar 29, 2025
@Asbelos
Copy link
Contributor

Asbelos commented Mar 29, 2025

Didn't mean to close this...
But requires further consideration.

@reinder
Copy link
Author

reinder commented Mar 29, 2025

This or introduces a pervasive change to the standard parsing algorithms which treat letters after the opcode as uppercase regardless of the case used. Thus the client side parsers can't distinguish between <y a and <y A.

Sorry, I wasn't aware of that, we can change the A to a E for extended. I choose to use one opcode, because there aren't many opcodes left.

…s uppercase.

Extended accessory now uses an E instead of an A.
Copy link
Contributor

@Asbelos Asbelos left a comment

Choose a reason for hiding this comment

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

Please see my friend request on discord (ukbloke) where we can discuss more easily.

@reinder
Copy link
Author

reinder commented Mar 29, 2025

We've made contact on Discord.

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.

[Feature Request]: Add broadcast event for accessory control
2 participants