Extend pulse for S seconds
Posted: Thu Nov 01, 2018 7:50 pm
Complete:
Constants block:
Circuit block:
Did you ever have a pulse, but what you need is a signal that stays on for S seconds? For example (but not limited to) to enable a train signal and give a train enough time to pass after its state is evaluated at a Stop and determined that it "can" be allowed through. This will do it.
(It might be possible to do this more efficiently, but I could not find such a circuit so I made this)
COMPONENTS:
- Left block = constant generation.
- Right block = actual circuit.
- Top green constant combinator and lamp are for testing only.
USAGE:
- Set the S combinator to the number of seconds you need the signal to stay on.
- Replace the green constant combinator with whatever creates your pulse (right now it is looking for green > 0 to start operating).
- Replace the lamp with whatever you want to control (right now you should use green > 0 as your device condition).
- NOTE: If instead of a pulse you generate an input signal that stays on... the clock will restart at the end of the S seconds, and keep restarting until you turn the input signal off and it ends its cycle.
- If you need multiples of this circuit, you do not need to repeat the constant generation piece. You can place two circuits and feed them the constants using a red wire, and you can even daisy chain them as shown in the screenshot below.
Chained example:
If you can think of a more efficient/compact way to achieve this, or if you find any errors that need correcting please let me know. I will evaluate the changes and update the post with improvements.
Constants block:
Circuit block:
Did you ever have a pulse, but what you need is a signal that stays on for S seconds? For example (but not limited to) to enable a train signal and give a train enough time to pass after its state is evaluated at a Stop and determined that it "can" be allowed through. This will do it.
(It might be possible to do this more efficiently, but I could not find such a circuit so I made this)
COMPONENTS:
- Left block = constant generation.
- Right block = actual circuit.
- Top green constant combinator and lamp are for testing only.
USAGE:
- Set the S combinator to the number of seconds you need the signal to stay on.
- Replace the green constant combinator with whatever creates your pulse (right now it is looking for green > 0 to start operating).
- Replace the lamp with whatever you want to control (right now you should use green > 0 as your device condition).
- NOTE: If instead of a pulse you generate an input signal that stays on... the clock will restart at the end of the S seconds, and keep restarting until you turn the input signal off and it ends its cycle.
- If you need multiples of this circuit, you do not need to repeat the constant generation piece. You can place two circuits and feed them the constants using a red wire, and you can even daisy chain them as shown in the screenshot below.
Chained example:
If you can think of a more efficient/compact way to achieve this, or if you find any errors that need correcting please let me know. I will evaluate the changes and update the post with improvements.