IX30 IO over Modbus TCP

I am trying to read the integrated IO values from an IX30 over Modbus TCP from either the Eth2 port or remotely via a Cellular VPN link using a Modbus TCP Client.

I have enabled the Modbus gateway as per the manual for a socket connection ( setup below) but when trying to connect locally via Eth 2 I get a 0x0A - GATEWAY PATH UNAVAILABLE response error.

The Status page shows a connection but failing.

Debugging info.

Nov 25 03:25:54 Digi IX20 config: (service.modbus_gateway.debug) changing from (false) to (true)
Nov 25 03:25:55 Digi IX20 modbus: loaded 1 server configs
Nov 25 03:25:55 Digi IX20 modbus: loaded 0 client configs
Nov 25 03:25:55 Digi IX20 modbus: apply_client_configurations
Nov 25 03:25:55 Digi IX20 modbus: apply_server_configurations
Nov 25 03:25:55 Digi IX20 modbus: socket_add_listening_socket: 0.0.0.0:502
Nov 25 03:25:57 Digi IX20 modbus: Connected to ubus
Nov 25 03:26:04 Digi IX20 modbus: new_incoming_connection_cb fd 7 events 0x1
Nov 25 03:26:04 Digi IX20 modbus: server_context_enqueue
Nov 25 03:26:04 Digi IX20 modbus: New connection
Nov 25 03:26:04 Digi IX20 modbus: server_socket_handle_socket_connected
Nov 25 03:26:04 Digi IX20 modbus: start_server_socket_inactivity_timer: 60 seconds
Nov 25 03:26:04 Digi IX20 modbus: start_socket_inactivity_timer: 60 seconds
Nov 25 03:26:04 Digi IX20 modbus: start_server_socket_inactivity_timer: 60 seconds
Nov 25 03:26:04 Digi IX20 modbus: start_socket_inactivity_timer: 60 seconds
Nov 25 03:26:04 Digi IX20 modbus: no client found for address: 1
Nov 25 03:26:04 Digi IX20 modbus: creating exception a
Nov 25 03:26:04 Digi IX20 modbus: sending exception type 0xa to serial

So it looks like the DIGI is being a Modbus Gateway for a connected client only, if this is the case then is there some way of creating an internal client which allows access to the IO?

Or are there some other settings I am missing? Possibly an application manual for reading the inbuilt IO?

Any help appreciated.

cheers

Tim.

@0sm0 you’ve run into the same thing we did. It seems the IX30 has physical IO, and a Modbus Gateway, but there’s no link between them.

We ended up writing a python script which utilizes pyModbusTCP and ran it on the IX30. I am not near the IX30 right now to pull the config, but if memory serves, you can pull the values from the physical IO, dump it into registers, then I think we had a custom firewall rule to expose port 502 for the purpose. We disabled the on-board modbus gateway.

https://pymodbustcp.readthedocs.io/en/latest/

I will be back at the office after the weekend and may be able to pull more info if needed. Hopefully this gets you moving in the right direction.

Thanks dgici,

Thought as much. Will have a look into the pyModbusTCP script.

Any help appreciated.

Cheers

Tim.