Forums.MrPLC.com: Online status and resetting points after comm loss - Forums.MrPLC.com

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Online status and resetting points after comm loss Rate Topic: -----

#1
User is offline   Tony 

  • Sparky
  • PipPipPip
  • Group: MrPLC Member
  • Posts: 25
  • Joined: 23-December 04
Hi,

I want to show online status by means of indicators in a CXS project which connects to several PLC's
I have been looking for a system point which indicates whether the communication
between CXS and a plc is established or not,but can't find anything.
like nr open PLC's in CX-server's performance monitor.

Also after CXS lost communications with a PLC how can I let the point values drop to their defaults.

Hope someone understands my 2 questions.

Thanx
0

#2
User is offline   Tony 

  • Sparky
  • PipPipPip
  • Group: MrPLC Member
  • Posts: 25
  • Joined: 23-December 04
Ok, online status is solved now, I am using a IsPLCOpen script for that now.

so this leaves me with the pointvalues which hold their last updates value after connection loss,
but I like them to be resetet to their default values as if comms where never initiated.

Thanx again.
Tony

This post has been edited by Tony: 26 February 2010 - 04:27 AM

0

#3
User is offline   PdL 

  • Got Joy in life
  • Group: MrPLC Admin
  • Posts: 2,997
  • Joined: 03-August 04
  • Gender:Male
  • Location:Naarden, NL
  • Interests:Too many...
  • Country:Netherlands
    Netherlands

View PostTony, on Feb 26 2010, 10:23 AM, said:

Ok, online status is solved now, I am using a IsPLCOpen script for that now.

so this leaves me with the pointvalues which hold their last updates value after connection loss,
but I like them to be resetet to their default values as if comms where never initiated.

Thanx again.
Tony


I think you would need to hide your indicators (and perhaps show static text indications) using visibility animation on the IsPLCOpen status. Getting the points to revert to their default values is not possible as far as I know.
Posted Image MrPLC Omron FAQ : websites, manuals, cables software & more Posted Image
*update 06/02/2010 - Added link to Routing table instruction video


check out www.myomron.com - our knowledge at your fingertips
0

#4
User is offline   Tony 

  • Sparky
  • PipPipPip
  • Group: MrPLC Member
  • Posts: 25
  • Joined: 23-December 04
Ok, thanx for confirming Pdl,

I was allready thinking in that direction, just didn't want to code something which might allready be incorporated.

Thanx
0

#5
User is offline   Berti Baker 

  • Sparky
  • PipPipPip
  • Group: MrPLC Member
  • Posts: 220
  • Joined: 26-July 06
  • Country:United Kingdom
    United Kingdom

View PostTony, on Feb 27 2010, 04:43 PM, said:

Ok, thanx for confirming Pdl,

I was allready thinking in that direction, just didn't want to code something which might allready be incorporated.

Thanx

Hi.

Yes I agree with PDL that setting default values isn't the normal way to handle this. Sounds also like you might be interested in the "Display bad Quality as #" option which 'hides' values that have not been read, and also and calculations and expressions using them. This is quite like the Excel "#ERROR" for invalid numbers an is the incorporated way for indicating that PLC values should not longer be used. You can find this setting under Project menu Runtine Settings->Advanced Settings.

Give it a try and hope that does just what you want.
Regards,
BB
0

#6
User is offline   tashinz 

  • Sparky
  • PipPipPip
  • Group: MrPLC Member
  • Posts: 314
  • Joined: 06-December 05
  • Country:Yugoslavia
    Yugoslavia

View PostTony, on Feb 26 2010, 10:23 AM, said:

Ok, online status is solved now, I am using a IsPLCOpen script for that now.

so this leaves me with the pointvalues which hold their last updates value after connection loss,
but I like them to be resetet to their default values as if comms where never initiated.

Thanx again.
Tony


maybe it is better to use PLCCommsFailed function, since this function checks whether there is a communication with plc. as i could have seen, plc must first be opened in order to check communication. if, for some reason, plc is turned off while starting cx-supervisor, plc wouldn't be opened, hence no communication will be established even when you turn on plc. you should then restart cx-supervisor. this all applies for cx-s 1.3 and cx-s 2.1 since i've tested it. so i use the following script (on 5 secs interval):

PLC_Open = IsPLCOpen("CJ1M")

IF PLC_Open THEN
PLC_CommFailed=PLCCommsFailed("CJ1M")
ELSE
PLC_ReOpenTime = PLC_ReOpenTime+5
IF (PLC_ReOpenTime >= 60) THEN
PLC_Open_Status = OpenPLC("CJ1M",PLC_Open)
PLC_ReOpenTime = 0
ENDIF
ENDIF

this should every 60 secs try to open plc if not open (that is in the case plc was off when cx-s started - assummed that the Open Device is checked in Setup Devices dialogue).

and now you can use PLC_CommFailed point to indicate communication status. Also, on the Initialisation script of cx-s you put
PLC_CommFailed = 1

which will be set to 0 if everything is ok after 5 secs when the above script is run.

This post has been edited by tashinz: 11 May 2010 - 07:19 AM

0

#7
User is offline   omronbleah 

  • Newbie
  • PipPip
  • Group: MrPLC Member
  • Posts: 5
  • Joined: 14-June 11
  • Country:Italy
    Italy
bad way, can miss some plc offlines


is better to write an incremental dm,
then plc copy it into another dm
then read the copied dm with supervisor
if they match means pc is online
sorry for bad english !!
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users