Anybus CompactCom B40 EtherCAT Unable to Connect to TwinCAT

In our project we are using the Anybus CompactCom B40 Brick with the EtherCAT protocol. We have implemented the host application code already and have verified that the Anybus and the module are properly moving through the state machine. The handler status is in APPL_RUN and the Anybus status is in the ABP_ANB_WAIT_PROCESS state. Furthermore, I enabled the EtherCAT state so that I can monitor it and once the setup is complete, it is in the INIT state.

I then generated the ESI file using the HMS ESI Generator application and verified that the EtherCAT state transitioned to the PRE-OP state. The ESI file generates with no errors.

We have the connection of the Anybus EtherCAT B40 as a direct connection using an Ethernet cable from the B40 to the PC directly (I have also tried using a switch with the same results). The issue that I am encountering is when using TwinCAT 3 to try to test that the EtherCAT protocol is properly implemented just by sending a simple command to change an ADI value, I am unable to find the Anybus module when scanning for I/O devices.

Are there any configuration settings that need to be made in order for the Anybus B40 to show up when scanning I/O devices in TwinCAT 3? Alternatively, is there other free software available that supports the Anybus EtherCAT connection that we can send an EtherCAT message to change an ADI value?

Thank you in advance!

Hello,

I will be looking into this matter for you.

We do not have an ethercat simulator that can send a message to change the ADI Value.

Goining off of TwinCat3, i did see this.

Troubleshooting

Various effects may occur during scanning.

:black_small_square:

An unknown device is detected, i.e. an EtherCAT slave for which no ESI XML description is available.
In this case the System Manager offers to read any ESI that may be stored in the device. This case is described in the chapter “Notes regarding ESI device description”.

:black_small_square:

Device are not detected properly
Possible reasons include:

–

faulty data links, resulting in data loss during the scan

–

slave has invalid device description

The connections and devices should be checked in a targeted manner, e.g. via the emergency scan.
Then re-run the scan.

https://infosys.beckhoff.com/english.php?content=../content/1033/ethercatsystem/1037001483.html&id=

Kevin,

Thank you for your response. I should clarify and say that the ADIs are mapped to the process data, so we are trying to send an EtherCAT message to access the process data.

image

Above is the response we get when running the Scan feature on TwinCAT.

Regarding your troubleshooting suggestions, I have ensured that the TwinCAT software has access to the ESI file that we generated. In the past we have implemented the Ethernet/IP module and were able to successfully send implicit messages over Ethernet/IP. We have also ensured that we have arrived at a point where we have installed the TwinCAT driver such that it is available in the Installed and ready to use devices as per the Beckhoff documentation sent, but still no I/O devices for the Anybus show up.

Hi pdesai,
I figure I would share my thoughts on this.

Be sure you are issuing the “Scan” operation in the correct context. I suspect you may be running “Scan” when the “Devices” node in the solution explorer is selected. Scanning in this context may produce the window you show. To scan the EtherCAT bus, first select the master node, for instance, if you created one manually, this might be listed as “Device 1 (EtherCAT)” by default.

image

With this node selected you should then be able to scan the EtherCAT network assuming the EtherCAT master has been properly configured. If this is a PC acting as the master, be sure you have assigned a “Realtime Ethernet Compatible” interface for it to use for communication, see the node’s “Adapter” tab “Search…” and “Compatible Devices…” buttons (from your previous post it sounds like you installed the TwinCAT Realtime Ethernet driver for an interface but perhaps it has not yet been assigned to the master “Device 1” yet).

If you continue to have issues we may need a Wireshark capture to see if the TwinCAT project is properly communicating in the network interface connected to the ABCC device. If the ABCC device is reporting WAIT_PROCESS, IDLE, or PROCESS_ACTIVE to the host it should be able to communicate with the EtherCAT master.

Jon

1 Like

Jon,

Thank you so much for your reply. I followed your steps, and it makes a lot more sense to scan the master device than to scan all devices. Unfortunately, we hit another error in the process, but we believe that it is due to issues with our network card. We are ordering a network card and hopefully your advice should work with no issues.

Meanwhile, we were able to successfully make contact with the Anybus using a program called EC-Engineer. I have attached a screenshot below and we were able to successfully read and write the process data.

Thank you Jon and Kevin for your help. I will update you if there are any further issues with Twincat after we try with the new network card.

I am glad Jon was able to assist and provide a definitive answer for you.

Kevin,

We are still waiting on a network card so I can confirm if Jon’s answer was a solution once we get the network card and test it out for ourselves. I will also update you if there are any issues beyond that point.