After Power Cut No Communication


Ampm

Recommended Posts

Hi

We use Daq Factory to set heating times etc in several buildings on site if a PLC in a building looses power due to a power outage even for a few seconds Daq Factory times out and the just Ignores that PLC until Daq Factory is restarted how do I get Daq Factory to check that PLC again and not just ignore it?

Link to comment
Share on other sites

I'm assuming the connection is over Ethernet. That's because the socket gets held open, so DAQFactory doesn't know the device shut down, it just thinks its not responding. To get around that, you can create a little watchdog sequence and reinit the port. Lets say you have a channel called "myChannel" on a PLC, and its on the DAQFactory device called "MyPLC" that is Ethernet (works for serial too). Create a sequence that looks something like this:


while(1)
if (systime() - myChannel.time[0] > 60)
device.myPLC.initComm()
delay(30)
endif
delay(30)
endwhile

[/CODE]

You can adjust the times to suit. This will cause the port to reinit if no data arrives for 60 seconds.

Link to comment
Share on other sites

Also, being turned off and on won't hurt the PLC per se, but if the power quality is such that you have frequent glitches that shut it down, the power quality even while present may not be great. Poor voltage regulation, harmonics, and so on. You may want to add power filters and/or UPS's to your PLCs, just for the sake of better power quality, and then there may also be some software advantages to having the PLC up during an outage or the first portion of it.

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.