Back: Home

Seeing the Digi One IAP’s trace – a form of “event log”

This applies to Digi One IA, Digi One IAP, Digi TS1 to 16 products

The Digi One IAP or any other Digi running the "Industrial Automation Engine" has the ability to show you an event trace of transactions as they pass though. Telnet to the Digi One IAP on the default TCP port of 23. Note that Hyperterminal under Windows XP SP2 is defective when used for WinSock or telnet connections, so use the Command Window’s telnet command - this line connects to the Digi at IP address 192.168.1.20, plus saves all text seen in a file called "log.txt":
telnet -f log.txt 192.168.1.20
You should see a login prompt; factory default user is “root” and password “dbps”. Enter the “set trace” command as shown below. To stop tracing, either close the telnet window or press Ctrl-C (^C).

Example: ControlLogix polling a Modbus/TCP Slave

login: root
password:
> set trace state=on mask=ia:i
22:54:22 IA INFO: eip:m05 cmd:Req/Rsp Data
22:54:22 IA INFO: cip cls:pccc srv:76 inst:1 attr:0
22:54:22 IA INFO: eip:m05 recv req 34670
22:54:22 IA INFO: mbtcp:s04 Snd Req(34670) Seq:0x58ee Len:6
22:54:22 IA INFO: mbtcp:s04 Slv:1 RdRegs:4x30001 Cnt=6
22:54:22 IA INFO: mbtcp:s04 Rcv Rsp(34670) Seq:0x58ee Len:15
22:54:22 IA INFO: mbtcp:s04 Slv:1 Rd Bytes=12 (0000 0000 0000 3F80 +)
Above is an example of a ControlLogix polling a Modbus/TCP slave. The “eip:m05” events are from an incoming Ethernet/IP master connection – the number 05 is a dynamic index so expect your number to vary. The “cls:pccc srv:76” is how a ControlLogix talks to SLC5 and PLC5E with CIP. The “mbtcp:s04” events are from an outgoing Modbus/TCP slave connection – the number 04 is a dynamic index so expect your number to vary. “Slv:1 RdRegs:4x30001 Cnt=6” shows the Modbus being generated from the Rockwell request – here the ControlLogix is using a PLC5 Typed Read of N310:0 to generate a poll of the 30,000th Modbus holding register. Since the Digi One IAP uses a fixed formula to calculate the Modbus request, you can use this trace feedback to confirm that you properly understood how to setup your Rockwell PLC MSG block.

To successfully trace, you need to slow down or limit your polling. If the Digi One IAP is too busy it will create trace lines faster than TCP/IP can move them back to you, so the Digi One IAP just discards some lines to prevent a backlog from building up. You’ll see just the single line “TRACE lines skipped“, which masks the events and defeats the purpose of the trace.
22:54:22 IA INFO: eip:m05 recv req 34670
************** 20 TRACE lines skipped ***
22:55:11 IA DEBG: Ok[006] 01 03 75 30 00 06
If you want even more information to be traced, add the “D” and “W” to the trace command. The “I” shows information, while “D” show more verbose debug details and “W” shows normal operational warnings. When you specify the “D” option, it will be useful to reduce your poll sizes to a few registers since when the Digi One IAP traces all of the protocol bytes in a large 100+ register Modbus response you have a high probability of seeing “TRACE lines skipped“.
> set trace state=on mask=ia:i+d+w
22:55:11 IA INFO: eip:m05 cmd:Req/Rsp Data
22:55:11 IA INFO: cip cls:pccc srv:76 inst:1 attr:0
22:55:11 IA DEBG: PCCC request
22:55:11 IA DEBG: SbFnc:68 By:12 F:310 O:0
22:55:11 IA DEBG: Converting pccc request to IADB
22:55:11 IA INFO: eip:m05 recv req 34675
22:55:11 IA DEBG: Converting IADB request to modbus
22:55:11 IA DEBG: Ok[006] 01 03 75 30 00 06
22:55:11 IA INFO: mbtcp:s04 Snd Req(34675) Seq:0x58f3 Len:6
22:55:11 IA INFO: mbtcp:s04 Slv:1 RdRegs:4x30001 Cnt=6
22:55:11 IA DEBG: 1 3 75 30 0 6
22:55:11 IA INFO: mbtcp:s04 Rcv Rsp(34675) Seq:0x58f3 Len:15
22:55:11 IA INFO: mbtcp:s04 Slv:1 Rd Bytes=12 (0000 0000 0000 3F80 +)
22:55:11 IA DEBG: 1 3 c 0 0 0 0 0 0 3f 80 0
22:55:11 IA DEBG: 0 0 0
22:55:11 IA DEBG: Converting modbus response to IADB
22:55:11 IA DEBG: Ok[015] 01 03 0C 00 00 00 00 00 00 3F 80 00 00 00 00
22:55:11 IA DEBG: Converting IADB response to pccc
22:55:11 IA DEBG: Ok[022] 00 01 4F 00 86 82 99 09 0D 42 00 00 00 00 00 +

Example: IA "Custom" Protocol

This is an example of a Digi IA "Custom" master using either TCP/IP or UDP/IP to query a serial slave in half-duplex poll-response fashion. The "INFO:" lines show the actual ASCII code, which are truncated if longer than 1 line. You can see the "+" at the end of the line "...QRS+" which shows how this works.
> set trace state=on mask=ia:i+d+w
00:37:08 IA DEBG: cus:m04 trans from <idle> to <rcv>
00:37:08 IA DEBG: cus:m04 start message; max_size=2048
00:37:08 IA DEBG: cus:m04 End of msg detected by gap (chrtout)
00:37:08 IA DEBG: cus:m04 trans from <rcv> to <end>
00:37:08 IA DEBG: cus:m04 send req:38 to decoder
00:37:08 IA DEBG: cus:CH01 New Request
00:37:08 IA DEBG: slave_Tmr.start 1018 msec
00:37:08 IA INFO: cus:CH01 req#38 "0123456789:;<=>?@A"
00:37:08 IA DEBG: cus:CH01 trans from <wait> to <1stChar>
00:37:08 IA DEBG: cus:CH01 trans from <1stChar> to <rcv>
00:37:08 IA DEBG: cus:CH01 add rsp to message!
00:37:09 IA DEBG: cus:CH01 End of msg detected by gap (chrtout)
00:37:09 IA DEBG: cus:CH01 trans from <rcv> to <end>
00:37:09 IA INFO: cus:CH01 rsp#38 "0123456789:;<=>?@ABCDEFGHIJKLMNOPQRS+"
00:37:09 IA DEBG: cus:CH01 rtn msg, status=0
00:37:09 IA DEBG: cus:CH01 trans from <end> to <wait>
00:37:09 IA DEBG: cus:m04 rsp#38 "0123456789:;<=>?@ABCDEFGHIJKLMNOPQRS+"
00:37:09 IA DEBG: cus:m04 end message #38!
00:37:09 IA DEBG: cus:m04 trans from <end> to <idle>