Open ZLLentz opened 4 years ago
It may be useful to have some PLC PVs sourced from the general library that can be used to reboot the PLC, restart TwinCAT, etc:
To reboot the whole OS: https://infosys.beckhoff.com/english.php?content=../content/1033/tcplclibutilities/html/tcplclibutilities_nt_reboot.htm To restart just the TwinCAT process: https://infosys.beckhoff.com/english.php?content=../content/1033/tcplclibutilities/html/tcplclibutilities_tc_restart.htm There are also blocks like https://infosys.beckhoff.com/english.php?content=../content/1033/tcplclibutilities/html/tcplclibutilities_plc_reset.htm but these should probably be called from a separate PLC instance if they are to be useful... since once you reset the PLC it can't start itself again, since it isn't running any code.
I started investigating this for some ads-ioc debugging over here: https://github.com/ZLLentz/lcls-twincat-motion/blob/d7353562c81fb4f06a7b252a95992099d83a38b8/lcls-twincat-motion/Example/POUs/Main.TcPOU#L37
It may be useful to have some PLC PVs sourced from the general library that can be used to reboot the PLC, restart TwinCAT, etc:
To reboot the whole OS: https://infosys.beckhoff.com/english.php?content=../content/1033/tcplclibutilities/html/tcplclibutilities_nt_reboot.htm To restart just the TwinCAT process: https://infosys.beckhoff.com/english.php?content=../content/1033/tcplclibutilities/html/tcplclibutilities_tc_restart.htm There are also blocks like https://infosys.beckhoff.com/english.php?content=../content/1033/tcplclibutilities/html/tcplclibutilities_plc_reset.htm but these should probably be called from a separate PLC instance if they are to be useful... since once you reset the PLC it can't start itself again, since it isn't running any code.
I started investigating this for some ads-ioc debugging over here: https://github.com/ZLLentz/lcls-twincat-motion/blob/d7353562c81fb4f06a7b252a95992099d83a38b8/lcls-twincat-motion/Example/POUs/Main.TcPOU#L37