The CANbus Sniffer enables you to monitor CANbus communications.
To use the Sniffer:
Create a Data Table dedicated to the CANbus Sniffer. To provide the column structure, select a CAN Sniffer struct.
Enable CANbus sniffer in PLC Communications> Physical> CANbus.
Link the dedicated Data Table.
Link a tag to control the CANbus Sniffer Operating Mode.
Use these codes to activate the Sniffer in the desired mode: 0 - Disable Rx/Tx 1 - Enable Rx 2 - Enable Tx 3 - Enable Rx/Tx |
![]() |
The Sniffer writes data to the rows sequentially. When the table is full, the Sniffer overwrites the rows. |
The CAN Sniffer Struct provides the data shown below.
Description |
|
Time (ms) |
Update interval |
Identifier |
This is the ID of the device being monitored |
Type |
Shows the CAN Identifier type:
|
Flags |
The code shows the mode being monitored. 0 - Rx/Tx Disabled 1 - Rx Enabled 2-Tx Enable 3 - Rx/Tx Enabled |
Data Size |
Shows the number of data bytes that are being sent/received. |
Data |
This shows the data contents of the messages being sent/received |
Occupied |
This shows that the data table row contains data. The user must reset this bit. |
When you configure CANbus, in Properties, you can enable the CANbus Sniffer filter and add ranges of IDs that yo do not want to see in the sniffer data table.
Values entered in that window are saved at the project level.