ProcessTraining

Soft PLC First Scan

3 posts in this topic

Good day.

I am running a OTS, training simulator, using Rockwell RSLogic Emulate soft PLC.s. We have the configuration from the site. This is connected to a Hysys math model that gives us the I/O. We save snapshots of the PLC's and reload when training. The problem we have is when we load snapshots and go to run the PLC does a first scan and intuits a trip/shutdown due to missing/bad I/O or status. Is there a way to eliminate the first scan. Out Controls guy has made work arounds a code but we have to do for every new PID or discrete tag we add?

Any help much appreciated.  

 

Sheldon Patey

Share this post


Link to post
Share on other sites

controller scans logic so scan is integral part of how it works there will be first scan, second scan etc. so cannot change that...

if you have problem with code because of missing IO, one options is to simply restructure your code and remove I/O from the programs - use only internal memory. this completely removes any reset that is associated with outputs on first scan. on a real PLC (that has I/O) you can have call to a sub that transfers data from internal memory to I/O. on a simulator, simply don't call that routine. toggle one bit and no more I/O update... or IO is updated from separate variables.... this makes programs more portable as well so one can use same code on various controllers and adapt connections to real I/O as needed. 

 

Share this post


Link to post
Share on other sites

Intersting, not sure if I fully understand. We do have input/outputs through OPC Server. 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now