diff --git a/pymodbus/server/simulator/http_server.py b/pymodbus/server/simulator/http_server.py index 761687fc3..44e452fc5 100644 --- a/pymodbus/server/simulator/http_server.py +++ b/pymodbus/server/simulator/http_server.py @@ -157,6 +157,7 @@ def __init__( if "device_id" in server: # Designated ModBus unit address. Will only serve data if the address matches datastore = ModbusServerContext(slaves={int(server["device_id"]): self.datastore_context}, single=False) + del server["device_id"] else: # Will server any request regardless of addressing datastore = ModbusServerContext(slaves=self.datastore_context, single=True)