plc - Pointer and reference behavour during online change -
could please me more information how pointers, references , interface references behave during online change?
what have watch out for? understand other answers pointers may dangerous if these not written during each cycle, use interfaces , references.
when online change made, variables, function blocks , other program parts may move in different memory location. therefore, if pointer address old information, might refer memory address containing else.
so if pointers used, should updated regularly adr command, said.
when using references , interfaces, don't see problems online change because system should handle them automatically. in twincat 3, system readdress variables automatically (source: https://infosys.beckhoff.com/english.php?content=../content/1033/tc3_plc_intro/9007199390694027.html&id=) , because codesys based, think same other systems.
when using references, might idea check reference valid. in twincat 3 there function __isvalidref
, should in other codesys based systems.
Comments
Post a Comment