Thanks all for the replies. Sorry I did not specify, I was interested in the mode where the master directly creates Ethernet frames with Ethertype = 0x88A4, not the UDP version. After I posted, I found the following reference that may help, or may just add to the confusion:
https://wiki.wireshark.org/Protocols/ethercatThis includes a Wireshark capture dump of ~5 seconds of EtherCAT traffic. It seems like the source address is set to the MAC of the master, and the destination is broadcast, as @ajb pointed out above. If the source address is the only one modified, then inserting a switch into the traffic should not impact the operation, right?
If you use open mode (Master - Switch - n slave chains), then the destination MAC is the MAC of the first slave of the chain being addressed.
Hmm - in this case, how would the master know the MAC addr of the first slave node? In IP networks this is done with the ARP protocol (whose Ethernet frames are broadcast) - what's the equivalent in EtherCAT? Sorry, it seems like the spec document ETG1000.3 is paywalled...
My design uses a set of EtherCAT servo drives attached to an SBC with a direct connection. The drives and SBC, along with a high-speed data acquisition system need to communicate through a shared fiber-optic link that traverses a rotary joint. In 'normal' operation, no EtherCAT frames need to traverse the shared link (I send the SBC a command via a TCP socket on another network interface, it serves as the EtherCAT master and tells the servo drives what to do and sends status back via TCP). I would like to have EtherCAT available through the fiber link for 'commissioning' the servo drives (doing the initial tuning, maintenance etc) so I was wondering if I could use a VLAN on a managed switch on the fiber link to allow both EtherCAT frames and TCP to share the same link. Performance/latency is not so critical here so it seems like this might work since each VLAN has a separate broadcast domain. The limitation is the servo drive commissioning software only uses the 'direct mode', and does not support UDP tunneling.