Converts a raw Error from modbus-rs into a typed ModbusError.
Uses getModbusErrorCode to classify the error by its internal
error code, then constructs the appropriate Data.TaggedError variant.
Unknown/unrecognized codes fall through to ModbusInternalError.
Converts a raw
Errorfrommodbus-rsinto a typed ModbusError.Uses getModbusErrorCode to classify the error by its internal error code, then constructs the appropriate
Data.TaggedErrorvariant. Unknown/unrecognized codes fall through to ModbusInternalError.