Host Engineering Forum

General Category => Do-more CPUs and Do-more Designer Software => Topic started by: PLCwannabe on July 19, 2019, 12:29:09 AM

Title: BRX PLC Clock/timer
Post by: PLCwannabe on July 19, 2019, 12:29:09 AM
Been trying to find a clock instruction on Do-More 2.6.  with a BRX PLC. I want to schedule an event 7 times a day with a specific start and stop times. I can't find any timer that would work for this. Is it even possible that a PLC would exist without this function? Any suggestions?

Thanks for any help. 

Title: Re: BRX PLC Clock/timer
Post by: b_carlton on July 19, 2019, 12:46:30 AM
The Do-more has calendar and clock variables specifically in SDT0 (also called $NOW)

It also has comparison instructions.

Here is an example rung turning on Y0 from 6 to 10


Title: Re: BRX PLC Clock/timer
Post by: BobO on July 19, 2019, 12:54:11 AM
Been trying to find a clock instruction on Do-More 2.6.  with a BRX PLC. I want to schedule an event 7 times a day with a specific start and stop times. I can't find any timer that would work for this. Is it even possible that a PLC would exist without this function? Any suggestions?

Thanks for any help.

As Bernie mentioned, it isn?t an instruction, it?s a time and date structure containing the current time. You can build whatever comparison logic you want to trigger events.

We have talked about doing a scheduler instruction, but just haven?t gotten around to it.
Title: Re: BRX PLC Clock/timer
Post by: PLCwannabe on July 19, 2019, 09:45:52 PM
Thanks for the help guys. I got it figured out but still think it would be a good idea to add a scheduler instruction. Now, this setup brings up a different question. How can I set up my Cmore HMI so I can set hours and minutes with the same numeric entry object rather than having one numeric entry for hours and a different one for the minutes?
Title: Re: BRX PLC Clock/timer
Post by: Bolt on July 20, 2019, 12:09:14 AM
It would require some math instructions to interpret, but you could represent time with a number, hhmm, like 1437 represents 2:37 PM. But using two 2 digit number selectors on the Cmore is no big deal to represent hh and mm separately
Title: Re: BRX PLC Clock/timer
Post by: Controls Guy on July 20, 2019, 04:22:02 PM
That's what I do, use a four-digit time on the HMI, but not much math required.  I just maintain a four-digit time in the PLC and do compares with that.
Title: Re: BRX PLC Clock/timer
Post by: Bolt on July 21, 2019, 01:43:57 AM
I just maintain a four-digit time in the PLC and do compares with that.
Doh! I forgot that I do that to in all my click plc projects.
Title: Re: BRX PLC Clock/timer
Post by: plcnut on July 22, 2019, 09:11:33 PM
Regarding time setting with C-more, it is not too hard to have a time display, and then add up/down buttons that will increment/decrement hours, ten minutes, and minutes.