Deadtime on a digital signal

You just need to break things down in to bite sized pieces.

1) What instruction would you use for timing the 20 seconds from the button being pressed to the output turning on?

2) What instruction would let you keep the output on for X amount of time and then turn the output off? I'll give you a hint on this one, because many people get this wrong. The TOF instruction is a tool of Satan and should never ever be used. People who say otherwise, likely hate the Packers, brats, and puppies. Don't be that person.

Sort those two issues out, and post the code you came up with. From there we can help get the rest of the issues sorted out.


Bubba.
To be fare. I like brats.
 
AB ladder solution

An RA/AB ladder solution is here: https://github.com/drbitboy/plc_deadtime_fifo; ZIP archive file is attached.

It only needed one TON timer running at 1Hz; the output hold is driven by that timer.

This approach could be refactored with minimal effort to use no timers and instead use the RTC:0.SEC word if an upper limit of 59s for deadtime was acceptable; even a limit of 86,399s would be straightforward. N.B. Using the RTC with MicroLogix 1100 PLCs would drop the resolution to 2s; the RTC-based approach will not work with Emulate500.


Caveats and limitations

  • Deadtime is limited to a range of [5:125] in 5s increments in this implementation
    • It could be [1:127] in 1s increments with the HMI proposed by the OP
    • The 2**n and ((2**n)-1) size limitations can be removed via actual modulus calculations and other busier coding techniques, instead of the bit-wise AND shortcuts used here.
  • The accuracy of timing is 1s or so
    • This could be improved by decreasing the time base of the TON timer to 0.01s (100Hz), but that might result in some missed transitions.
  • The RSS file in the .ZIP archive is configured for a MicroLogix 1100 Series B on ethernet with IP=172.16.240.240*
* It also works with RSLogix Micro Starter Lite/Emulate500
 
Last edited:
In case nobody noticed, the OP hasn't made a post since the initial one on this thread. Time well spent... o_O

I did notice. It probably was homework as sussed by Lare in the first response.

That said, it was a decent learning exercise for me.

I am unsubscribed now; I'll move on to the sine thread soon, but I have to use a Chebyshev because I only have ML1100.
 
Last edited:

Similar Topics

I am trying to impliment some pH control logic on a wastewater treatment system. We are useing 93% sulfuric acid and 57% magnesium hydroxide as...
Replies
5
Views
3,017
I want to study the PIDAT instruction autotuning in Omron CJ1M PLC. For that I want to simulate a process with deadtime and first order lag...
Replies
0
Views
4,156
Question to anyone with ideas about my thoughts on upgrading a very vintage timer, which is being used to switch between 2 5hp domestic water...
Replies
14
Views
430
I have a PLC type PM856 from ABB with some I/O modules and I get an error from the Digital Inputs model type DI801. The unit status shows error...
Replies
0
Views
261
I am monitoring two BMXDDO3202K digital outputs for their behaviour, they are each for opening and closing, and so the on time affects how far the...
Replies
1
Views
278
Back
Top Bottom