R
I need Modbus RTU support for my Linux application running on standard PC hardware. I know various drivers exist, but I need an implementation that accurately adheres to the spec defining a frame as a set of closely spaced bytes followed by 3.5 char times of silence. The various implementations around that identify the frame boundary by inspecting the content of the incoming bytes won't work for me.
Unfortunately, implementing to the dead-time spec is not feasible from outside the Linux kernel. Too much happens from the time a byte arrives off the wire until it's available to an application to accurately time its arrival. So, I believe my only recourse is a custom driver inside the kernel, and tightly coupled to the UART. I know others have posted about a similar need over the years, but I've never seen a solution.
Here's the driver I'm looking for:
1) Receives frames as defined per the 3.5 char times of silence spec, and passes them upwards to the application.
2) Sends frames passed down from the application, insuring that the outgoing bytes are tightly packed per the spec.
3) CRC checking and generation are optional. If not available, I can do it at the application level.
4) Stateless with regards to the Modbus RTU protocol machine. That will happen at the application level.
5) Completely agnostic of the Modbus application protocol.
6) The driver API is TBD, but there's flexibility here.
I'll take any and all suggestions, links, etc.
Thanks
Unfortunately, implementing to the dead-time spec is not feasible from outside the Linux kernel. Too much happens from the time a byte arrives off the wire until it's available to an application to accurately time its arrival. So, I believe my only recourse is a custom driver inside the kernel, and tightly coupled to the UART. I know others have posted about a similar need over the years, but I've never seen a solution.
Here's the driver I'm looking for:
1) Receives frames as defined per the 3.5 char times of silence spec, and passes them upwards to the application.
2) Sends frames passed down from the application, insuring that the outgoing bytes are tightly packed per the spec.
3) CRC checking and generation are optional. If not available, I can do it at the application level.
4) Stateless with regards to the Modbus RTU protocol machine. That will happen at the application level.
5) Completely agnostic of the Modbus application protocol.
6) The driver API is TBD, but there's flexibility here.
I'll take any and all suggestions, links, etc.
Thanks