Modbus TCP server: listens on a port, serves each connection from the shared DB, and optionally notifies the owner of parsed requests.
Summary
Functions
Returns a specification to start this module under a supervisor.
Returns the raw DB map currently held by the server's shared model.
Starts the TCP server GenServer. params must include :model and may include :port, :timeout, :active, :fc_map, and :sup_opts.
Stops the TCP server GenServer process.
Reads or writes the server's local DB using a frame tuple. Validates the frame against the fc_map and returns the result or {:error, :efun} for unknown function codes.
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
Returns the raw DB map currently held by the server's shared model.
Starts the TCP server GenServer. params must include :model and may include :port, :timeout, :active, :fc_map, and :sup_opts.
@spec stop(pid()) :: :ok
Stops the TCP server GenServer process.
Reads or writes the server's local DB using a frame tuple. Validates the frame against the fc_map and returns the result or {:error, :efun} for unknown function codes.