0

I need to send a variable via ethernet from a Twincat 3 to a Twincat 2. Is it possible? How could I do that?

Mong Zhu
  • 23,309
  • 10
  • 44
  • 76
JosepB
  • 2,205
  • 4
  • 20
  • 40

2 Answers2

6

You can use Network Variables for this purpose. There's good documentation available on the Beckhoff site: https://infosys.beckhoff.com/english.php?content=../content/1033/tcsystemmanager/fieldbus/rtethernet/tcrtethernet_intro.htm&id=

stevenv
  • 411
  • 3
  • 11
0

Have a look at the tcDataExchange.lib, the FB_WriteAdsSymByName (or FB_ReadAdsSymByName) looks good for your task.

The same library has other FBs that work in a more automatic way, e.g., triggering an update when a value is changed. You might need to make a search for 'tcDataExchange.lib' in both the TC2 help file and the Infosys as they seem - at least on my PC - a little confused about which FBs are available.

pboedker
  • 523
  • 1
  • 3
  • 17