github.com/AdamSLevy/modbus (go): Package modbus implements a threadsafe modbus library.  Start by initializing a valid ConnectionSettings object and passing it to GetClientHandle. If successful, the error will be <nil> and you can use ClientHandle.Send(Query) to transmit Queries.  The ClientHandle can be used in multiple goroutines concurrently as long as ClientHandle.Close() has yet to be called. To allow for each goroutine to call ClientHandle.Close() asynchronously, multiple ClientHandles for the same ConnectionSettings can be acquired using repeated calls to GetClientHandle. The clients are hashed by their ConnectionSettings.Host string, and ConnectionSettings must match exactly for multiple ClientHandles to be returned.  After all ClientHandles for a given client with the corresponding ConnectionSettings have been closed, the client is automatically shutdown.  The RTU, ASCII and TCP Packagers implement the modbus protocol and can be used directly to send Queries. This is intended to allow more flexible use of the underlying modbus library, such as in simple programs that don't require concurrency.
Keywords: go|golang|modbus|modbus-client|modbus-library|modbus-master|modbus-rtu|modbus-serial|modbus-tcp|thread-safety|threadsafe