Stage programming and a total run timer

I have written a program using stages (using Do-More) for the first time. The machine performs a repetitive task and the program is working great.

The program consist of three stages. The initial stage 0, I tasked it to empty the machine without permitting any fill operations. This is because I have no way of knowing the level of the tanks. It then transitions to stage 1 which allows tank 1 to fill and tank 2 to empty. A count down timer is started and when finished it moves to Stage 2. This stage empties tank 1 while filling tank 2. When finish it transitions back to stage 1. This continues until the machine is turned off or a e- stop is activated which reverts back to stage 0.

I have also programed a C-more panel. Within the monitor, I have included a total cycle counter as well as a total run timer. This is where I am having an issue.

Also X25 and X26 are coming from the touch panel.

Will the counter/timer work the way it is written?

Thanks Steve

SBPLC.png


​
 
Assuming stages S3 and S4 are enabled then it appears the counter and timer should behave as you describe. Using the simulator they appear to continue to count/time after reaching the preset (even when the preset is zero). What 'issue' are you having?
 
For one thing: Don't use X's as inputs from a touch screen. X bits are written to by physical Inputs on each scan. Also I am not sure what Y13 is, But it 'appears' you may be using Y13 just as a bit for running the timer. If Y13 is also being used as a physical output, then what you are doing is probably fine.

You need to use C bits for all internal Coils and contacts.
Use X's only for Physical inputs, and Y's only for physical outputs.
Hope this helps.
:D
 
Thanks guys....

I found out the hard way that the x bit did not work from the screen. I changed them to c bits and the resets work fine.

Also, when I read the instructions on programming the timers with stages, it led me to believe I needed to address the the contacts as $Main.S0, but that didn't work. I changed them to just S0, S1, S2 and the counters and timers worked as they should.
 
Also, when I read the instructions on programming the timers with stages, it led me to believe I needed to address them as $Main.S0 but that didn't work. I changed them to just S0, S1, S2 and the counters and timers worked as they should.
$MAIN.S0 is referencing the bit for Stage 0 in the program block MAIN.
When you type S0 inside a program block it automatically references that Program blocks own stage bits (ie: $Process_Run.S0)
Glad you're making progress.
 

Similar Topics

After reading all about the advantages the Stage programming could have, finally I come to the practical question: where are the stage instruction...
10
Replies
5,268
Views
So I've decided to start branching out a bit more and look into another PLC programming package. Based on the popularity of it, I decided to try...
6
Replies
4,762
Views
Does anyone with experience on Automation Direct/Koyo PLCs know what classification that "Stage" programming falls under? I have used these tings...
8
Replies
2,656
Views
Ok, to me this would be considered a firmware bug. I use stage and block programming heavily in my programs. I always assumed all stage bits in a...
0
Replies
3,632
Views
I'm just starting to learn AD stage programming. (newbbie-ish) Fanuc ladder programming mainly. While I see MAJOR advantages with using stage, I...
19
Replies
10,663
Views
Top