Possibility to read if is PLC restarted after project build

Hello!
I’d like to ask if there is any way to read in code from the PLC whether the project was restarted after a project transfer.

I found that there is a function block, MpComLoggerUI, which can read the logger output, but it seems to be intended for components with a configuration file since the FB requires MpLink. Unfortunately, I couldn’t find whether it’s possible to connect to the System module or any other module.
Thank you

The init_reason output from the SysInfo function block from library brsystem gives information about the reason for the restart.

https://help.br-automation.com/#/en/6/libraries%2Fbrsystem%2Ffbks%2Fsysinfo.html

Thank you for the advice, but I don’t see an option to check whether a project transfer occurred before the restart. :frowning:

Hi,

I think the only way to get the wanted information is to read out the system logger using ArEventLog library and check, if the’re messages inside about project transfer.
Every project transfer enters some info messages the logger that can be identified by their ID number.

Best regards!

2 Likes

A bit of a complicated and clunky solution, and it seems like reading each message almost requires a dedicated function block, but it’s solved!
Thank you.

1 Like