How can I use add_write_callback to change a node value, and then perform a secondary action?
#190
Closed
Remi-Godin
started this conversation in
General
Replies: 1 comment
-
|
Nevermind, I was just being dumb. I had tunnel vision and didn't think of just sending the data inside the same tokio task that was writing it in the first place. I guess my hangup was always returning StatusCode::Good from my callback function, but I can live with that. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Here's what I'm trying to do:
Here's what I managed to do:
But now I don't know if the write to the nodes was actually successful, and the data I send to another service might be "out of sync" with the actual node value.
Is there a better way to do this? Is
add_write_callbacknot the way to go? Is the best way to create an internal opc client to subscribe to my server instead? But that seems a bit excessive.Beta Was this translation helpful? Give feedback.
All reactions