Jump to content
OMRON Forums

Is WpKey a bit risky?


daves

Recommended Posts

I got caught out setting CaptCtrl by forgetting to set the WpKey on a Gate3 card (My fault, I'm new to Gate3 and the manual does in fairness mention it).

 

What I don't like is the way the code still executes silently but not applying the values leaving in a potentially dangerous condition.

 

In my case a very large piece of machinery carried out its home manoeuvres in the wrong location as it thought some motors had finished their home move due to the incorrect trigger. Luckily this was fine but it is not hard to imagine a situation where something would be very bad.

 

Do you think it would be safe to bail out of a program attempting to set a protected parameter (possibly killing motors) setting a soft WD of "WpError" say?

 

I don't actually see the benefit outside the terminal; if you write code accessing the parameters you know what you are doing, and if you know about the key you put that line in enabling any mistakes you've made in the parameter anyway. Nothing is protected

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Daves,

 

One of the main reasons for implementation of write protected registers are to prevent unwarranted modifications to critical control registers on DSPGate3. These can be unintentional modification by code/user or noise on the data/address bus.

 

While developing a project, it is suggested that you set the Sys.WpKey to $AAAAAAAA to allow the modifications. Since all of the protected registers are SAVED registers, you don't need to set the Sys.WpKey in a commissioned machine. This allows the protection to act as it was designed (for preventing unwarranted modifications to critical registers).

 

If you wish to include some of the critical registers in Power PMAC project, say in one of the global include files, you can set the Sys.WpKey at the beginning of the file, but you must remember to set it back to zero at the end of the file. If the Sys.WpKey is set with the key and left alone, no protection against changes by user/code are provided.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.

×
×
  • Create New...