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

Suppress M261.1 Modbus comm error when V passed #1035

Open
wants to merge 1 commit into
base: 3.6-dev
Choose a base branch
from

Conversation

benagricola
Copy link

Quick overview on the forum - but in short, it is already possible to check the status of the Modbus request by checking that the value of the variable is not null.

The error message output by M261.1 on Modbus communication failure is unnecessary for reads where the null result ends up in a variable anyway, and just ends up spamming the console when using the command programmatically.

src/Platform/Platform.cpp Outdated Show resolved Hide resolved
@benagricola benagricola force-pushed the 3.6-dev branch 3 times, most recently from 318db3a to 0ccba92 Compare August 21, 2024 19:38
@benagricola
Copy link
Author

Whoops, capitalisation error in the previous commit (nullPtr != nullptr 🤦) - fixed now, should be good to go.

@benagricola
Copy link
Author

@dc42 Anything else that needs doing to get this merged?

Modbus error reporting is problematic if you're calling M261.1 from inside daemon.g, as the error will cause daemon.g to exit as well.

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.

2 participants