NETIO UDP Discover

From wiki.netio-products.com
Revision as of 10:38, 3 October 2019 by Bbakala (talk | contribs) (Receive Discover response:)
Jump to navigation Jump to search

NETIO Discover uses UDP broadcast transmission.

Send Discover message:

Destination: Broadcast (eg. 255.255.255.0)
Protocol: UDP
Destination Port: 4000
Data(HEX): 504345646974020000000000000000000000000000000000000200000000000000000200000000000000000000000000000000000000000000000000000000

Receive Discover response:

NETIO devices response with UDP broadcast message with destination port 4000. So listen on port 4000 and parse messages according to table below. Data are sent as datastream with flags inside. If you pass the end of known field types, ignore rest of data in datastream.

Listen protocol: UDP
Listen on port: 4000
Data(HEX):

Format: 0x02 0xXX 0xXX F_TYPE F_LENGTH B0 B1 B2 B3 F_TYPE F_LENGTH B0 B1 B2 B3 B4 B5 F_TYPE F_LENGTH ...
Example: 0x02 0xAB 0x6B 0x03 0x04 0xC0 0xA8 0x65 0x23 0x09 0x06 0x4E 0x65 0x74 0x69 0x6f 0x34 ... ...
Meaning: Response magic magic IP 4 bytes 192 168 101 35 PRODUCT 6 bytes N e t i o 4 ... ...

Field types:

F_TYPE code Description Data Interpretation Data Length
0x01 FIRMWARE_VERSION ASCII variable
0x02 MAC INT 6
0x03 IP INT 4
0x04 NETMASK INT 4
0x05 HOSTNAME ASCII variable
0x06 DHCP INT 1
0x07 SETUP STATE INT 1
0x08 RESULT INT 1
0x09 PRODUCT ASCII variable
0x0A MANUFACTURER ASCII variable
0x0B PLATFORM ASCII variable
0x0C VARIANT ASCII variable
0x0D TIMEOUT INT 1
0x0E GATEWAY INT 4
0x0F DNS INT 4
0x12 PRETTY_PLATFORM_NAME ASCII variable
0x13 DEVICE NAME ASCII variable