Hello @devmicha,
The infrastructure looks like this:
IOs -> (SPI) -> ModbusTCP server -> (ModbusTCP) -> Evok -> (REST, WebSockets,...) -> your code
The ModbusTCP server (unipitcp service) is polling the complete status of underlying HW via SPI. This happens very quickly, in less than milisecond interval. The Evok aggregates data from the ModbusTCP server and from the owfs (for 1-Wire devices). Your application can poll data from the Evok in multiple ways (REST, WebSockets,...)As you can see, the Evok doesn't communicate with the HW directly. We discussed the possibility of custom software pulling the SPI in this thread: https://forum.unipi.technology/topic/711/reading-spidev
I fully understand your concerns about infinite polling data over GET requests. This is generally slow and causes high load on the PLC. The WebSocket offers you a way to subscribe to updates of the IO. You can poll the complete status of the PLC at any time and yet you can listen to updates and act accordingly. Check the documentation and example: https://evok-9.api-docs.io/1.08/ubmjnyexu77wxwo4q/websocket.
Martin