-
|
I could use some guidance on how to handle reads from remote devices in a non-blocking manner. I'm quite inexperienced with OPC-UA in general, so it's possible I'm approaching this completely wrong. Here's what I'm trying to do: I have a number of devices connected to the OPC-UA service I'm building. Typically, the devices are connected via MODBUS/TCP or MODBUS/RTU. The goal is to provide a unified way for OPC-UA clients to read registers from these devices without having to know or care about the underlying protocols. What I'm unsure about is how to perform these reads without blocking the service: I would like to fetch values directly from the device at the time the OPC-UA request is made by the client. In my experimental version, I use Another alternative would be to keep a list of "hot" registers and continuously refresh them in the background. However, this approach is more complex and still has the same issues: the first request (which tags the register as "hot") will not have any value, and subsequent requests may be outdated. It can also result in a lot of unnecessary fetches when no clients are actually reading the data. I haven't started looking into subscriptions or monitoring yet. Could you provide some hints how this is typically implemented? This seems like a very common use case, so I'm a bit surprised that I haven't found a straightforward way to handle it. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
|
Hi, you've run into one of the many limitations of the See advanced_server.md and the node-managers sample. If you look at In really general terms, what you want to do is have an implementation of the |
Beta Was this translation helpful? Give feedback.
Ok, thanks! I'll try that!