How to program to repeat timer output?

Just an aside, you can reset the timers in a CLICK by Copying a zero directly into the timer's accumulator register. For example, to reset Timer1 to the beginning where it starts over, simply execute a Copy instruction to write a zero to the TD1 register. The Done bit (T1) will automatically be reset and the timer will start counting from zero.

y8p
 
SC are in the Click are System Control Relays. If you go to the hlpe menu and search for the System Control Relays it will explain the use.
To look up the SC area goto the address picker in the software and select SC.

Regards,

SC Help.jpg SC address picker.png
 
ryangriggs, thanks for your insight.




SC are in the Click are System Control Relays. If you go to the hlpe menu and search for the System Control Relays it will explain the use.
To look up the SC area goto the address picker in the software and select SC.

Regards,

Garry, how interesting it is that I just commented on one of your YouTube tutorials and hadn't even realized that its you commenting on this thread! For the record your videos have helped a lot when getting to know the click.


But the system control relays. I haven't messed with them yet but I did review the documentation you provided. So they are special bits that behave according to how CLICK has designed them to? To save time, i assume? For instance, SC5 would turn on then off every 50ms? This would save a lot of hassle with generating a basic pulse for different alarms and lights.

Thanks!
 
I've never used an AutomationDirect PLC, but can't you create a one second or 500ms self rearming timer then on rising edge increment a byte or word and use the bits in that byte/word for the different frequencies that result from it?
 
Picking up on what cardonsocea has mentioned. We could use the math function to add 1 to a hexadecimal register every 1 second. We then mask the word so we will only look at the first 4 bits of the word. The math instruction will do this for us using the AND operation with the value of F hex.
Our register will now count from 0 to F and then repeat.
We can then use eight compare statements in parallel to trigger the output. This will create our flicker circuit.
Values 0 and 1 = "On", Values 2 and 3 = "Off", Values 4 and 5 = "On", etc
Note: We only need the on conditions to trigger the output.

Regards,

Repeat Timer using a Math mask.jpg
 
System Control Relays frequencies are fixed in the Click PLC.

The S7 has a CPU Clock you can configure in Hardware & then you can use the Pulses directly that you don't need to create (1 Sec ON, 2 Sec etc..) These pulses can then be use to toggle depends on required frequency.

Each controller has its own positives and negatives. This is a nice feature in the Siemens S7.
 
Here is one more way to program this flicker. Use a shift register.
You will see that there are several ways to accomplish the same thing in a PLC. This is why documentation is so vital.

Regards,

Repeat Timer using a Shift Register.jpg
 

Similar Topics

My program is initiated by a N.O. input and once it is closed, it stays closed until the end of the program cycle (program is still running in PLC...
Replies
15
Views
4,122
I have a small problem with getting my machine to repeat a sequence if a switch is closed. Basically this is a mcahine which takes a basket of...
Replies
1
Views
5,057
Can we use a Simotion D455 ethernet port x127 as a gate, to access S7-1500 plc Tia Portal program ? In the Simatic manager, we used Netpro to do...
Replies
2
Views
73
Hi all, I am having issues accessing my Cimplicity software - the site code changed after re-install and I am no longer able to attain a new key...
Replies
10
Views
158
Posted this to Reddit with little success, so I figured I would share it here as well. Very new to PLCs, but figured I would give it a shot to...
Replies
0
Views
115
Back
Top Bottom