Zeal 0 Posted July 14, 2020 I AM USING AZEOTECH SCADA V16.3. I AM CONNECTING 4 NOS OF PLCS. WHILE I AM NOT CONNECTED WITH ANYONE PLC THE SCADA SOFTWARE IS HANGGING TOO MUCH. SO THAT I HAVE WRITTEN THE BELOW SCRIPT. while(1) if (device.PLC1.Connected) device.plc1.ClearBypass() else device.plc1.SetBypass() endif if (device.plc2.Connected) device.plc2.ClearBypass() else device.plc2.SetBypass() endif if (device.plc3.Connected) device.plc3.ClearBypass() else device.plc3.SetBypass() endif if (device.plc4.Connected) device.plc4.ClearBypass() else device.plc4.SetBypass() endif endwhile THE ABOVE SCRIPT IS ON AUTO START MODE. ISSUE IS WHEN I AM DISCONNECTING THE NO.1 PLC(PLC1) THE SCADA APP CRASHES AFTER 20-30SECONDS. AND THE ERROR CODE IS AS BELOW. RESOLUTION NEDDED IS:- IF I WANT TO CONNECT 4 PLCS THEN WHAT IS THE CODE I HAVE TO PUT.(WHICH WILL NOT CAUSE SCADA HANGGING ISSUE OR APP CRASH.) Share this post Link to post Share on other sites
AzeoTech 0 Posted July 14, 2020 I'm not completely sure it is causing the crash, but you have a while(1) loop with no delay in it, so that sequence, when run, is going to run as fast as the CPU will allow and use all the CPU power of one of your cores. I would add at least a delay(0.1) before the endwhile and see if that helps. If it does not, then you should consider upgrading to the latest release. Share this post Link to post Share on other sites