Jump to content

Configurable timer circuit with a reset?


Recommended Posts

So I've been playing a mini base recently (and yes, I've stolen a lot of ideas from Francis John).

This means that I don't have reliable space scanners and I have to manage the steam temps. that arise (and it's useful for power anyway), and I'm constantly changing rocket destinations.

190287654_Minibabybase.thumb.png.d084abc20b9f15fa8132f0733889a160.png

 

I've been launching rockets manually and programming in a timer sensor to open the doors at the right time in case the space scanner doesn't detect the incoming rocket.

However I've got a little tired of this and have been trying to design some automation so that when I flip the switch it will;

  1. Start a timer for the length of the journey.
  2. Open the pod bay doors, Hal.
  3. Let the rocket launch.
  4. Close the doors (done using the signal from the rocket capsule)
  5. Open the doors again just before the rocket returns.

And it'll do all this even if I disable the switch after launch, and also work for flights that last >10 cycles.

I did all this using a memory toggle (to latch the circuit on until the rocket returns) a timer sensor (counting 10/ths of the total trip time, with all but 0.1 cycle of the timer in the green, then 0.1 cycle in red) a signal counter to count up to 10 and then a buffer gate to open the doors for 60s and reset the circuit so that it doesn't keep running.

However this circuit still requires me to remember to reset the timer sensor every time before I launch the rocket, as the timer sensor doesn't have a reset built-in.

1235540789_TimerCircuit.thumb.png.f4a385e73a06ded3d9ba023903ef8be3.png

I was wondering if anyone out there has a timer circuit that can be easily configured for different times and can be sent a reset signal to restart it?

 

 

 

Link to comment
Share on other sites

12 minutes ago, ScreamingPict said:

Would increasing the number of space scanners increase the quality of the signal even though they have no view of space?

The quality no. The chance maybe. With a network quality of 0%, one scanner may detect the object any time between 200s and 0s before it arrives. My understanding is that it's a uniform distribution. Assuming 40s (it's 36-37 I believe) for opening the doors, you have a 40/200 = 1/5 = 20% chance of missing the mark.
It's different with two scanners. The chance of both missing it it's 1/25 = 6.25%. With three, 1/125 = 0.8%.

Link to comment
Share on other sites

15 hours ago, TheMule said:

The quality no. The chance maybe. With a network quality of 0%, one scanner may detect the object any time between 200s and 0s before it arrives. My understanding is that it's a uniform distribution. Assuming 40s (it's 36-37 I believe) for opening the doors, you have a 40/200 = 1/5 = 20% chance of missing the mark.
It's different with two scanners. The chance of both missing it it's 1/25 = 6.25%. With three, 1/125 = 0.8%.

OK thanks. That still makes me want to try a timer-based system if I can get it working :)

Link to comment
Share on other sites

14 hours ago, Slvrsrfr said:

That mini build idea is superb. great for testing the fundamentals. Seen some type of it on twitch, someone's at least. Very nice.

I tried one, it is not for me. I need some space. But anybody looking for a challenge should definitely try these at least once.

Link to comment
Share on other sites

22 hours ago, ScreamingPict said:

I was wondering if anyone out there has a timer circuit that can be easily configured for different times and can be sent a reset signal to restart it?

Yes but I'm not sure you'll like the answer. The solution is a good old water clock. Sort of ironic that space automation in ONI can really only be done reliably with ancient technology.

Link to comment
Share on other sites

On 10/4/2020 at 1:12 PM, ScreamingPict said:

a signal counter to count up to 10

If you connect one counter to another, you can count to 100. Add another and count to 1000. This would take care of those longer trips and provide a more detailed visual of mission completion without opening the space screen.

For example, a 3 cycle mission would equate to 1800 seconds, 1.8 total timer, 0.1 green and 1.7 red.

A 60 cycle mission would equate to 36,000 seconds, 36 total timer, 0.1 green and 37.9 red.

If you AND the timer output with your “ready to launch” signal (ie, when the rocket is offloading cargo and refueling) the counter will not increase. In the most extreme situation (the 60 cycle flight), your rocket may sit idle for 37.9 seconds before it automatically launches and started the counter again.

Link to comment
Share on other sites

If all you want is a reset-able timer, you can connect a buffer gate and a not gate in a loop. The not gate will give a 1 tick pulse each cycle of the buffer. You can "reset" it by applying an external green signal to the not gate input. You can also chain multiple buffers to get a increased timer lengths.

Link to comment
Share on other sites

This is what I use:

1118554575_OxygenNotIncluded2020-10-0615_28_10.thumb.png.9d80219b55b26581b8d3b98ca401ee19.png

The wire at the bottom is connected to a cycle sensor:

1017378044_OxygenNotIncluded2020-10-0615_28_23.thumb.png.878e49d56ee99b36cdcfbee143eba479.png

When the rocket is returning, the doors are open for about 10 seconds ( not counting opening and closing duration ), but this can be fine-tuned to even less.

Note: you have to set the duration of the round-trip in cycles when your rocket is landed, and let the circuit launch the rocket, or it will crash through your bunker doors on its way back.

Link to comment
Share on other sites

9 hours ago, ghkbrew said:

If all you want is a reset-able timer, you can connect a buffer gate and a not gate in a loop. The not gate will give a 1 tick pulse each cycle of the buffer. You can "reset" it by applying an external green signal to the not gate input. You can also chain multiple buffers to get a increased timer lengths.

Ah- but that's where things get interesting- the NOT gate isn't instant, so if you have, say, the buffer gate set to 10s, you don't get a pulse every 10s, you get a pulse every 10-and-a-bit seconds... which messes up the timing. 

Other than that- yes that's the best way I could think of to make a resettable timer.

On 10/5/2020 at 4:10 PM, Saturnus said:

Yes but I'm not sure you'll like the answer. The solution is a good old water clock. Sort of ironic that space automation in ONI can really only be done reliably with ancient technology.

Very true. However the timer sensor can now at least do a lot of what the water clock could.

20 hours ago, yoakenashi said:

If you connect one counter to another, you can count to 100. Add another and count to 1000. This would take care of those longer trips and provide a more detailed visual of mission completion without opening the space screen.

For example, a 3 cycle mission would equate to 1800 seconds, 1.8 total timer, 0.1 green and 1.7 red.

A 60 cycle mission would equate to 36,000 seconds, 36 total timer, 0.1 green and 37.9 red.

If you AND the timer output with your “ready to launch” signal (ie, when the rocket is offloading cargo and refueling) the counter will not increase. In the most extreme situation (the 60 cycle flight), your rocket may sit idle for 37.9 seconds before it automatically launches and started the counter again.

Now *this* is the inspiration I needed. I had been using the timer sensors in cycle mode with only one counter dividing it by 10, meaning that if I enabled it mid-cycle it might take a while before the rocket actually launched. Additionally I had the door control *either* from the rocket-ready signal *or* from the timer.

If instead I use the timer in seconds mode, ramp up to several counters and, more crucially, have the door control *only* from the sensor then the rocket won't take off until it's at the right part of the cycle and it won't be sitting idle for multiple cycles waiting for the launch window.

Thanks everyone!

Link to comment
Share on other sites

5 hours ago, rulerofthehuns said:

This is what I use:

1118554575_OxygenNotIncluded2020-10-0615_28_10.thumb.png.9d80219b55b26581b8d3b98ca401ee19.png

 

When the rocket is returning, the doors are open for about 10 seconds ( not counting opening and closing duration ), but this can be fine-tuned to even less.

Note: you have to set the duration of the round-trip in cycles when your rocket is landed, and let the circuit launch the rocket, or it will crash through your bunker doors on its way back.

Oh! I love the way you use counters to get to 48 cycles- holding the 8 cycle counter in reset until you get to 40- that's genius! I've always assumed I could only usefully count to 10/100/1000 etc.

The one thing I don't understand is the 50 second filter that delays re-opening the doors. Surely your initial 48-cycle counter starts, 44s later the bunker doors have finished opening and the rocket launches, meaning that your 48 cycle timer is exactly 44s ahead of the time the rocket will return, so if you wait 50s to open the doors after the timer completes you'll be too late?

Link to comment
Share on other sites

1 minute ago, ScreamingPict said:

The one thing I don't understand is the 50 second filter that delays re-opening the doors. Surely your initial 48-cycle counter starts, 44s later the bunker doors have finished opening and the rocket launches, meaning that your 48 cycle timer is exactly 44s ahead of the time the rocket will return, so if you wait 50s to open the doors after the timer completes you'll be too late?

You have to start the delay after the rocket disappeared above the map, and the 48 cycle delay ends a bit before the rocket appears above the map.

The 50s delay comes from these, and door opening time.

Link to comment
Share on other sites

5 minutes ago, rulerofthehuns said:

You have to start the delay after the rocket disappeared above the map, and the 48 cycle delay ends a bit before the rocket appears above the map.

The 50s delay comes from these, and door opening time.

I did not know that. I assumed the full 48 cycles was ground-to-ground time, rather than off-screen to on-screen time. Thanks! I've learned a tonne from this thread!

Link to comment
Share on other sites

I think an idea i had a while ago could be what you're looking for, since it should be not much bigger than what you already have and should keep track of time for up to 66 cycles, but i'll have to build it to see if it actually works, and it might not be "easily configured", unless you're willing to do a bit of math when setting it up. However, that will have to wait until tomorrow, since it's 3:30 am here, and i should have turned the pc off a while ago. I'll get to it first thing in the morning.

Link to comment
Share on other sites

So here's what i came up with:

915337684_asyncclock.thumb.jpg.df6c55cc0e8b07890f5b1e660efcfeef.jpg

The on on the left is my attempt at making it more compact, while the right one is more easy to follow.

This clock works using two out of sinc clocks (A and B), waiting for them to sync up for a single tick. Given that a filter gate can go up to 200s (plus 1 second becuase of the buffer gate + the time taken by the automation ticks when the clocks cycle), and that the time it take for the whole clock to tick is the product of the two clocks, it should be able to go up to 201x200=40200 seconds, or exactly 67 cycles, times ten thanks to the signal counter C, so 670 cycles. The two problems are that for this to work A and B have to be coprime, so you have to take care when setting it up, and that the precion of the clock goes down a lot for long time intervals, up to 2000s or around 3.6 cycles at the max (i.e. you can pick 670 cycles or 666.4, but nothing in between). This might be solvable with a third out of sync clock, but i haven't tried to make that work yet.

However for rockets launches, since they take at most 54 cycles it should be able to keep the timing errors always below 20s in the worst case scenarios, which can be easily compensated with the output buffer (needed anyway since the output is a pulse), or if you need more precision you can put a filter after the buffer to have the clock pulse early and delay the activation of the hangar doors.

So, as a quick summary, here how to use it (since i realized it may not be too clear from the explanation):

You can set this clock to output a pulse at any time T= A x B x C, where A and B are the time of the two filters plus one, and must not share any common factors, (so you can't use A=20 and B=45, since they are both divible by 5, but you can use A=20 and B= 99, and to do so you set the two filters at 19 and 98) and C is the number the counter is set to reset at. You use a pulse at the start sot start the clock and can stop it at any time with a pulse at the stop (i just used buttons), otherwise it stops automatically when it ends. The pulses don't have to be short, but can be just 0.1s. The start overrides the stop, and if it's still on when the clock finishes it doesn't stop and restarts instantly.

So, if you want the clock to tick at 8.1 cycles ( 4860 s), and open the doors for 60 seconds, we can see by factorizing 4860 that it is 4 x 5 x 243 (which is 3^4), so we can use A = 20, B=81 and C=3, so we set the two filters at 80 and 19, the counter to reset at 3 and the output buffer gate at 60.

Link to comment
Share on other sites

6 hours ago, Onairda said:

This clock works using two out of sinc clocks (A and B), waiting for them to sync up for a single tick. Given that a filter gate can go up to 200s (plus 1 second becuase of the buffer gate + the time taken by the automation ticks when the clocks cycle), and that the time it take for the whole clock to tick is the product of the two clocks, it should be able to go up to 201x200=40200 seconds, or exactly 67 cycles, times ten thanks to the signal counter C, so 670 cycles. The two problems are that for this to work A and B have to be coprime, so you have to take care when setting it up, and that the precion of the clock goes down a lot for long time intervals, up to 2000s or around 3.6 cycles at the max (i.e. you can pick 670 cycles or 666.4, but nothing in between). This might be solvable with a third out of sync clock, but i haven't tried to make that work yet.

A great idea that has been posted a few times before on the forum. However, it and all other purely automation based solutions suffer from being both lack of precision and reliability in an actual survival game. The water clock method however gives you on the second precision. At worst it's +0s/-1s over any number of cycles, be it 10s, 100s, or 1000s of cycles.

Link to comment
Share on other sites

simple 24 hour clock

 

simpleclock.png

 

and this holds clock till activate signal send and stops again after selected time

simpleclockwith.png

 

and this how i would make the different time selection 

simpleclockwith_new.thumb.png.b379783e3cc37c6d6d164ab8ebe1731d.png

 

and most compact version what come to my mind with 4 different timers

simpleclockwith_new.thumb.png.ae2e1930a0e950c4b3cea6a29e157585.png

for make it more accurate add more counters and set timer sensor for smaller time

Link to comment
Share on other sites

Hi, this is what i use.

oni2.thumb.png.e98abc0388106e969b3e53b02ceca769.png

How it works.

The two digests on top ... does NOT show how many cycles you need. If what to delay your rocket with 20 cycles you need to set the first one to 4 and the second one to (4*5 = 20) or what ever combination you like.

Switch 3 is used only to start the fueling of the rocket when it lends, if you have non stop fuel transfer you don't need it.

Switch 1 and 2. Both are need it for the first start of the rocket. 

1- bypass the counter

2- is use to auto launch the rocket whenever the counter sends green signal and the rocket is full with fuel.

I think the rest is explanatory :)

I do hope someone find this useful.

Sorry for my English :(

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

Please be aware that the content of this thread may be outdated and no longer applicable.

×
  • Create New...