Light Sequencing

I think daba was talking about not using counter or a timer or it would need to be more than 2 just for them


Yah I got that, but even w/o timers (e.g. STI - no timer instruction), everything I've thought of so far needs a rising edge, and generating that rising edge will use a third instruction, no?


even if I user timer.ACC as an indirect address, I still need a third instructon to reset the timer.
 
Last edited:
Since you are using an Allen Bradley... one rung and one instruction

Move S42 to your output word

1100flasherout.png
 
Two lines of SCL code (ok wrong platform, but you get the idea). Code is run in a timed interrupt set at 1 sec.

lamps1.jpg
 
Here ya go, two instructions:
Not really, so if the OP uses it, they will get a failing grade because it does not meet the assignment goal.




Oh, I finally got it: the OP assignment does not have the light cycling; they just run through that sequence one time. Yeah, two instructions can do it.
 
Nope. S42 increments every 2s in MicroLogix. And 30 is not a multiple of 12.

Just depends on the sequence they are looking for, looks like yours turns them all on at once and the move that I use will cycle one at a time, you can also use a mask move to give a different one

drbitboy said:
There it is, as beautiful and simple as I knew it would be.

Yep LD will run circles around most of us... but using the timer and counter like the homework ask for I still like my first one, you have more control and you can change it as needed, I dont think two rungs is possible using both timers and counters
 
Just depends on the sequence they are looking for, looks like yours turns them all on at once and the move that I use will cycle one at a time, you can also use a mask move to give a different one



Yep LD will run circles around most of us... but using the timer and counter like the homework ask for I still like my first one, you have more control and you can change it as needed, I dont think two rungs is possible using both timers and counters

If you use a PLC that supports the CPT block and a long enough expression including modulo, you can probably do this with one instruction and get the sequence correct.

Throw a dummy timer and counter in there to meet instructor requirements, and now we're at three instructions...
This is something I would do in a classroom setting just to be contrarian...

In real life, I'd use indirect addressing and a handful of rungs...adjustable time interval, change the bit table for new patterns, maximize flexibility.
 
even with STI we still have to generate the edge.
You're thinking the right way, just keep thinking. Why do we have to generate the edge? And how does the instruction know we've generated it?

I won't spoil it for you, you're a smart cookie ;)
 
Lets keep it real guys, the OP wants some guidance on writing a program with certain criteria, this is turning into a competition of who can write the smallest code and ignoring the OP's dilemma. Modern PLC's have plenty of memory and generally fast enough for most scenarios Let him start with baby steps and keep it to the point.
 

Similar Topics

Hi there, I'm having trouble with a task I was given on Siemens S7. I have to sequence one light with one PB. You press the button once, the...
Replies
22
Views
5,025
Hello everyone. I am working on designing a call light/alarm system I have roughly 20 stations that will each have their own call switch. Then...
Replies
10
Views
108
Hi Guys, I have a 1769-L24-QBFCB1 that has the OK light flashing on the embedded counter module. The manual states it is a resettable fault, but...
Replies
0
Views
98
Hi to all. On our Siemens PLC power supply, the battery light is showing amber. If we do not immediately change the batteries, will we lose the...
Replies
3
Views
129
Hi all, I have a question about light towers, the way I have always used them and the way I was taught is like indicator lights, i.e. Green...
Replies
8
Views
345
Back
Top Bottom