Turn an LED on after it automatically turns off by unaccessable timer.

Thread Starter

MFL

Joined Aug 13, 2021
41
You also might be able to pull it off with an LT6700 It comes in 3 different varietes. https://www.analog.com/media/en/technical-documentation/data-sheets/6700123fh.pdf One does both polarities. There is also a one comparitor version of the chip.

You need a resistor to drop some voltage. Lets use 400 mV. So, you need to say if it;s less than 400 mV turn it on. Turning it on will make it >400 mV, so it turns off. There might be a problem as to how long you have to press the button.
So, you would put some resistor that drops >400mV in series with the power negative. or maybe power positive,. Look at the datasheet.
400 mV is the minimum you can set using this part.

You MIGHT need to extend the pulse,
Thanks for the info KISS... I gotta try this 555 chip thing.. it looks like it will work.. and it does look simpler than what you suggest .. your idea may be great... But it's above my understanding.. you would have to work very hard to fill in the blanks... and it might not be worth your time .. please stand by while I try MrSalts idea... thanks much.
 
The idea is pretty simple,but it depends on how long you have to push the button. If you have to push it for 1s, then no it wo;t work. If it uses the edge, then likely it would work

And it's two parts, maybe 3.
A bypass cap (0.1 ceramic)
The LT part. It's open drain. Just what you need.
400 mV is fixed. Probably not a problem.
It would depend on a fixed power supply somewhat.
You need a resistor that drops > 400 mV when the LED is on. R=0.4/15mA = 26 ohms.; check wattage.
Advantage: no big parts.

Say an external 3.6V power supply, A lithium battery would also work.

In fact, it would take about as much room as the switch.
 

Thread Starter

MFL

Joined Aug 13, 2021
41
The idea is pretty simple,but it depends on how long you have to push the button. If you have to push it for 1s, then no it wo;t work. If it uses the edge, then likely it would work

And it's two parts, maybe 3.
A bypass cap (0.1 ceramic)
The LT part. It's open drain. Just what you need.
400 mV is fixed. Probably not a problem.
It would depend on a fixed power supply somewhat.
You need a resistor that drops > 400 mV when the LED is on. R=0.4/15mA = 26 ohms.; check wattage.
Advantage: no big parts.

Say an external 3.6V power supply, A lithium battery would also work.

In fact, it would take about as much room as the switch.
t
Thanks KISS, (I actually did some work for them as a pyrotech.. :)

You are seriously looking at this... The switch is momentary, and the switch blue wire "A" has a low voltage while the lights are on, and a slightly higher voltage when the lights are off. Switch blue wire "B" is common with negative batery. You can hold the button closed for the entire 20 seconds and beyond. The lights go off when expected ... then when button is released... the lights do not turn on... you must press (ground point "A") again. This suggests there's a 555 in the forward section of the sub.. which I can't get to.

Halmark ornaments tech dept. could not find any info on the sub, except battery # LR44, which is wrong .. it's LR41

I'll breadboard MrSalts 555 circuit, and test late Monday, I'm thinking it cold work using the NPN as the button. The original button is removed, and the ship is submerged and mounted in mineral oil and powered by the LED lighting system of the sealed tank ... which is 12 VDC There will have to be some adjustment after breadboarding to accommodate the 12v supply, I can add a small 5 VDC power supply the takes 12VDC main

you say "No big parts" .. I really like that. but, remember I can only supply DC voltage to the sub, there is no button anymore. Also, there is no practical way to get to the circuit that controls lighting time. I must simulate the button by just applying DCV and electronically, the "button" is being pressed about every 1/2 second. Please draw a diagram of what you are proposing. Thanks much, Regards, Michael
... some background can be found at microoceans.com

PS: if the lights blink or dim a bit now and then... that would be great! .. it's probably having reactor problems.
 
Try something: "Very quickly" try to activate the switch with a wire. Just "flick" the wire across the terminals, one side soldered.

What my idea depends on is IF software contact debouncing is used. https://www.embedded.com/my-favorite-software-debouncers/ e.g. The input has to be stable for 20mS. The comparator will give you a sharp edge, but switches bounce and many times it the edge and not the level that causes the trigger.

The LT parts have a 400 mV reference and either both - inputs, both + inputs and one of each. The input includes ground.

Put a 25 ohm resistor in the (-) lead of the battery and connect the side toward the circuit to the to the inputs() of both comparitors. one of the outputs to the non-ground side of the switch should work. Add a 0.1 uf bypass cap and your done.
I used 15mA and 3.6 V supply which would be 3.2V with 400 mV dropped across the resistor. That gaurantees > 400 mV across the resistor.

You can buy protoboards from digikey and www.proto-avantage.com. Th later company will mount the part for you for a fee.

If it works, you can march yourself over to www.easyEDA.com, and design using the web a small PCB. You can even have it assembled if you pick the right parts.

I'll just mention mounting holes or mounting something. It could be two solder pads.

I'm in "stress" mode right now.
 

MrSalts

Joined Apr 2, 2020
2,767
There is no need to denounce anything on this device. Any contact of the switch and it will activate and the switch doesn't do anything for 20-seconds (even if the user keeps the switch held in). The 555 with an NPN "switch" is the way to go here. Super simple and, most important, the OP understands the solution. It can be made with a simple protoboard - no EasyEDA needed.
 

Thread Starter

MFL

Joined Aug 13, 2021
41
There is no need to denounce anything on this device. Any contact of the switch and it will activate and the switch doesn't do anything for 20-seconds (even if the user keeps the switch held in). The 555 with an NPN "switch" is the way to go here. Super simple and, most important, the OP understands the solution. It can be made with a simple protoboard - no EasyEDA needed.
I believe you are correct MrSalts, thank you both for thinking about this... the solution will need to be quite small in size .. there will not be a "circuit board".. everything must assemble in a "blob" like a 3D sculpture of minimum wiring, and be stuffed into the battery compartment of the sub ... it's gonna be tight! there may be a little epoxy bonding once the circuit is "formed" to fit .. no need for any insulation.. the mineral oil is almost as good as air .. might be even better ... (like transformer oil.)

had to order some NE555P .. be here tomorrow ..
I did do the flick test.. extremely fast wipe of Point "A" with minus battery (ground potential) using a probe from the VOM meter.. easy to control .. the meter is set for current (some resistance .. not much) from ground to the probe. This would somewhat simulate the NPN.. methinks at most, a 1 ms pulse .. the lights came on. :)
 
@MrSalts My idea is dependent on their debounce time, if any, inside the hallmark device.

@MFL thank you for the flick test, so likely my idea would work. There might not be any perceivable OFF time either.

You don't really want to combine both circuits, but they could be.

I gather it's not a "one of" either". It can be made smaller. Three tiny parts. Really only two. The 267 ohm resistor is in series with the GND power lead. The bypass cap is a "suggested" component.
 

Thread Starter

MFL

Joined Aug 13, 2021
41
@MrSalts My idea is dependent on their debounce time, if any, inside the hallmark device.

@MFL thank you for the flick test, so likely my idea would work. There might not be any perceivable OFF time either.

You don't really want to combine both circuits, but they could be.

I gather it's not a "one of" either". It can be made smaller. Three tiny parts. Really only two. The 267 ohm resistor is in series with the GND power lead. The bypass cap is a "suggested" component.
KISS ... Please be a little more specific. there is yet much I don't understand about your idea. Would you please provide a circuit diagram and specific component identities.

So far .. there's mention of a 267 ohm resistor. and something like an IC chip described in your post #45

Debouncing is fascinating stuff... When the Museum of Science and Industry opened its new, massive re-modeled hall for the exhibit "Science Storms" (google it} One of the elements wasn't working well.. it was very intermittent. Because I was there assisting with the Tsunami Tank (which I helped design) I was asked to take a look at the Electromagnetic Ring Launcher that fires an aluminum ring about 60 feet up to hit the ceiling. I took a look at the guts.. and saw a mechanical relay that initiated the current inducing pulse which would launch the ring when the resulting counter-current in the ring produced a counter magnetic field .. and off it goes ... there's a fine wire guiding it's path to the roof... which is hit with a resounding "ring" and falls back to the touchscreen controlled machine with another clang! ... you can hear it all over the hall, even in youtube videos of the place.

Anyway.. I remembered I had the same problem with a relay in a large Tesla Coil, the latching circuit wasn't working ... so, replaced the ring launcher's relay with a hefty solid-state relay, and it's been working fine for 11 years... (methinks solid state relay contacts don't bounce) Sooooo, I understand where you are coming from .. I just don't understand how you are making the lights stay on in Nemo's boat.

I'm quite dim without pictures ... also.. check out microoceans.com .. that's just me ... never made any money selling the idea of a CNC for making waves. I had to learn a lot to build that wave-generating system .. and an enormous amount of help came from the forums for LinMot, Delta Motion Computers, Red Lion HMI and Omron NJ CPU's .. Methinks Covid will Kill any future for these things ... but that's off topic. Thanks much for your help.
 
Last edited:
I'm in a really bad time-crunch mode right now, to either make a schematic or scan it, but here we go.

Datasheet: https://www.analog.com/media/en/technical-documentation/data-sheets/lt6700-6700hv.pdf

This (My figure 1):

1629129385997.png



is from page 1 and this

1629129480768.png

My figure 2, from page 10. Note that the 6700-1 part has the reference applied to a non-inverting and an inverting input, so it can detect if a voltage is <400,mV or >400 mV

The 0.1 uF capacitor is the "bypass capacitor". Nearly all IC's need them. In figure 1, there are two levels tested >1/6 and ?2V.
The output is "open drain" so it basically looks like a switch to ground. In the first picture, they voltage divide the battery voltage so that 400 mV = 2V and 400 mV = 1.6V and you can use high value resistors.

The two 1M resistors are known as "pull-up resistors". This makes the output the battery voltage or zero rather than an open circuit or a closed circuit to ground. In the circuit you use, the 1M resistors will go away. The output and ground will be your "switch" contacts.

Now, that I looked at it a bit more, it would probably be better to put the resistor that measure current in the +supply lead to the hallmark device. It needs to drop say 400 mV at 15 mA In any event, >400 mV. So, if you used a REGULATAED 3.6V sourxe that dropped > 400 mV, so set the voltage at <3.2 V.
So you want 3.2V divided down to 400 mV using high value resistors.

So, you need two resistors that have a ratio of 3.2/0.4 or 8 that has a sum < than ~ 2 Megohms. So, using https://jansson.us/resistors.html you get 330K and 1M and your off by 4.5%.

An LT3042 breakout board such as this: https://www.ebay.com/itm/164919042920 would make a lot of sense.
3.3V is a common voltage, so that makes more sense than the 3.6 V I used.

You need to re-do the calculations for a 3.3V supply and 3.3-.4 or less than 2.9V

At 15 mA which is greater than your 20 mA, I get 0.4/15e-3 or 26.6 ohms and > 6 mW, so a 1/4-1/2 W resistor would be fine.

The E? series resistors is basically based on tolerance.

Your not likely to work on battery power, but a Lithium cell voltage is virtually flat, so it might work battery powered.
You just need to work out the details.

The LT6700 comes in various packages and not all are available. www.proto-advantage.com can buy and mount the part for you.

I think there is about 6.5mV of hysteresis with the setpoints.

If you pick the LT6700-1 part, which has one of each. The reference connected to + and -. One of the output will work.

before you commit, you can use a pull up resistor of say 500K. The output would be 0V when you want the switch to be on.
You can use a resistor or LED and and resistor to simulate the card and two resistors to simulate <10 mA AND >15 mA until you know it works.

If you use you LED load, you can use the outputs and turn the hallmark card on.

You can make sure all of the parts work without committing to the hallmark card.

Generally, one would measure the differential voltage across the resistor. Your going to have to fix the power supply before the resistor.

The LT3042 is essential.

So, the idea is to sense when the circuit is drawing significantly < 15mA and "push" the button. It will then start drawing >15 mA and the button would get released.

We also "Hope" that the card plays when the button is pressed rather than released and that's likely.

So, the LT6700-1, 2 resistors for the divider, 1 sense resistor and a bypass capacitor.
and a low noise voltage regulator breakout board probably set for 3.3V.
The sense resistor needs to drop more than 400 mV when the hallmark device is on.

I always get messed up on open collector/open drain comparitor operation.

The LT6703-? https://www.analog.com/en/products/lt6703.html#product-overview is the single channel version. That is available in a 2mm x 2mm package. Meaning really tiny. If you use the 6700-1, one of the outputs would work.

The input bias current is +-10nA, so that's why you can get away with high value resistors.

I'm sure this
Power SuppliesThe comparator circuitry operates from a single 1.4V to 18V supply. A minimum 0.1μF bypass capacitor is required between the VS pin and GND. When an output load is connected to the supply rail near the part and the output is sinking more than 5mA, a 1μF bypass capacitor is recommended. In instances where the supply is relatively “soft” (such as with small batteries) and susceptible to load steps, an additional 47Ω series decoupling resistor can further improve isolation of supply transients from the VS pin.

applies to the 6700 parts as well.

Bypass caps are generally connected really close to the IC power pins. They compensate for trace inductance and are usually ceramic.

You probably don't have reverse polarity protection. It's something you could include. See: https://www.ti.com/lit/an/slva139/s...37288&ref_url=https%3A%2F%2Fwww.google.com%2F

If i were making a PCB, I'd probably include that.

First, you need to see if it works.

if you use a pull-up for testing, a + voltage means the switch is off. Generally 0V is not attainable.

Conceptually, I hope it makes sense at least. Build on a big scale and the miniaturize and only final test when it passes the smoke test and it will activate the switch using some other load than the module.
 

Thread Starter

MFL

Joined Aug 13, 2021
41
GADZOOKS! That's quite a reply. what happened to Keep it Simple? :)

As it turns out the 555 works fine at triggering the NPN to turn on and off a LED
Point A.jpgReplacing the LED point A, and the sub to + & - .. works great!
Keep the lights on.jpg
If I could include a video.. the lights would go out and turn on in about 1/2 second... Must get the 555 to cycle a bit faster .. perhaps 4 HZ instead of 1 Hz... otherwise, working fine... Now to shove all those parts into the battery compartment... I think there's room .. perhaps I'll use a surface mount electrolytic... :)
 

MrSalts

Joined Apr 2, 2020
2,767
Or instead of running just power to the sub, run three wires to the sub and have the 555 on a circuitboard outside of the tank.

Last question (I should have asked first. Does the sub light up one cycle when you first apply power to it? That is, without applying power. Now that the button is removed. You can just connect A to ground and plug it in. If it does make the first cycle on its own, you could just power the sub directly with the 555 output snd ground. That is, the 555 outside of the tank and two wires to the sub.
 
GADZOOKS! That's quite a reply. what happened to Keep it Simple?
it is simple.

There is one thing I learned a long time ago, but it's generally rejected my management early, but it's a good technique. I did see it later described in a profession publication of the ISA (International Society of Automation).

You basically throw all of the ideas at a problem initially no matter how bad they are. Sometimes you can use pieces of the ideas.

The other idea is:
a) design the circuit as if you have infinite resources.
(tiny, reverse polarity protected)
b) What do you absolutely need.
(quick and dirty - works)
c) Add "hooks" for future enhancements.
(reverse polarity could be a future enhancement)

With software it's a different issue. You can design things so the enhancements can easily be added later without a re-write.

I kinda do a "thinking out loud" and when I did that, putting a resistor in the ground lead didn't make sense.

When iterating again, 3.3V made more sense for a power supply than 3.6V.

I've done some pretty big projects on my own. I maintained a Scanning Electron Microscope to the component level. No training at all. Someone taught me how to do laboratry glass blowing in a few weeks and I taught that skill to my replacement 6 weeks later. I sealed stuff under vacuum, attached a round quartz tube to a square quartz tube and sealed it. I made controlled leaks in a quartz tube. It helped a lot that I could silver solder/braze, solder, weld (tig, mig and stick).

Pointing a chimney (bricklaying) was fun, but I had help on the ground from a bricklayer. He mixed the mud and provides some tools and expertise. Designing a drainage system proved to be fun too. It's not 100% complete.
 
Last edited:

Thread Starter

MFL

Joined Aug 13, 2021
41
Or instead of running just power to the sub, run three wires to the sub and have the 555 on a circuit board outside of the tank.

Last question (I should have asked first. Does the sub light up one cycle when you first apply power to it? That is, without applying power. Now that the button is removed. You can just connect A to ground and plug it in. If it does make the first cycle on its own, you could just power the sub directly with the 555 output snd ground. That is, the 555 outside of the tank and two wires to the sub.
The answer is probably yes. However, it does light up quickly when power is applied now.. with the button removed. The cap is 10uf, R1 is 390 ohms and R2 is 3 K ohms .. downtime is about 21 milliSec. and freq is about 23 hz .. there is a hint of a blink at each re-light.. barely noticeable. and yes.. I could run 3 wires .. but the fun part will be making the clump of a 3D sculpture out of the components to fit inside. Failing at that... I'll run 3 wires ... sigh! OR...

If you are correct.. with "A" grounded, The sub should light when powered then cycle ground with the 555 remote... nice!

Too late.. my mind is fixed on stuffing all the parts inside and just applying power .. power which will appear faulty... :)PS: The NPN is doing the switching nicely.. but, you don't think it's needed?
 

MrSalts

Joined Apr 2, 2020
2,767
The answer is probably yes. However, it does light up quickly when power is applied now.. with the button removed. The cap is 10uf, R1 is 390 ohms and R2 is 3 K ohms .. downtime is about 21 milliSec. and freq is about 23 hz .. there is a hint of a blink at each re-light.. barely noticeable. and yes.. I could run 3 wires .. but the fun part will be making the clump of a 3D sculpture out of the components to fit inside. Failing at that... I'll run 3 wires ... sigh! OR...

If you are correct.. with "A" grounded, The sub should light when powered then cycle ground with the 555 remote... nice!

Too late.. my mind is fixed on stuffing all the parts inside and just applying power .. power which will appear faulty... :)PS: The NPN is doing the switching nicely.. but, you don't think it's needed?
I think it is the safest bet. I checked my notes and I used a small npn or small n-channel Mosfet when I was setting up some pop-culture museum pieces with similar on-switches.
 

Thread Starter

MFL

Joined Aug 13, 2021
41
I think it is the safest bet. I checked my notes and I used a small npn or small n-channel Mosfet when I was setting up some pop-culture museum pieces with similar on-switches.
I do like it.. Ya know... I could have just pushed the button down, added a little super-glue to keep it down, and soldered two wires to the battery terminals screwed the battery cover back on, and would have been good to go in a few minutes... sigh!

sooooo, could you be more specific about how this would work... wouldn't You have to close the circuit and "keep it closed" for about 20 seconds, then open it and close it again for the same time. I guess one could add a pot and tune the "on time" to be only a few milliseconds longer than the lighting "on time".. but then there's that charging cap in the light control timer..?

The way it works now... the flicker of darkness at the re-start.. is barely noticeable. 555 is running about 23 hz
 

Thread Starter

MFL

Joined Aug 13, 2021
41
it is simple.

There is one thing I learned a long time ago, but it's generally rejected my management early, but it's a good technique. I did see it later described in a profession publication of the ISA (International Society of Automation).

You basically throw all of the ideas at a problem initially no matter how bad they are. Sometimes you can use pieces of the ideas.

The other idea is:
a) design the circuit as if you have infinite resources.
(tiny, reverse polarity protected)
b) What do you absolutely need.
(quick and dirty - works)
c) Add "hooks" for future enhancements.
(reverse polarity could be a future enhancement)

With software it's a different issue. You can design things so the enhancements can easily be added later without a re-write.

I kinda do a "thinking out loud" and when I did that, putting a resistor in the ground lead didn't make sense.

When iterating again, 3.3V made more sense for a power supply than 3.6V.

I've done some pretty big projects on my own. I maintained a Scanning Electron Microscope to the component level. No training at all. Someone taught me how to do laboratry glass blowing in a few weeks and I taught that skill to my replacement 6 weeks later. I sealed stuff under vacuum, attached a round quartz tube to a square quartz tube and sealed it. I made controlled leaks in a quartz tube. It helped a lot that I could silver solder/braze, solder, weld (tig, mig and stick).

Pointing a chimney (bricklaying) was fun, but I had help on the ground from a bricklayer. He mixed the mud and provides some tools and expertise. Designing a drainage system proved to be fun too. It's not 100% complete.
KISS
Hi again, You have a fine philosophy of problem-solving, thanks for sharing. It's not surprising the varied and often amazing projects people have experienced. None of that is known with the brief encounters we have. I appreciate learning some brief history too.. thanks again.

What do you think of gluing the switch "on" (keeping point "A" at ground potential) and cycling the power to keep the lights on .. with barely noticeable flicker?

Also... I am studying your message #50 "the care and feeding of the 6700" .. I will get back to you on this :)

What you are wanting to do.. is originally what I wanted to do .. monitor the LED current, and control the power to "turn it back on" essentially.
The only way to do that was to re-connect point "A" to ground as quickly as possible, when the LED current drops every 20 seconds.

Because your reference was related to de-bouncing technology .. I didn't first "get-it" I didn't appreciate the nature of the 6700 and the regulated power supply required... more studying required... (I am not an electronics engineer ..by the way ... I just play one in my lab.)
 
Last edited:
Because your reference was related to de-bouncing technology .. I didn't first "get-it" I didn't appreciate the nature of the 6700 and the regulated power supply required... more studying required... (I am not an electronics engineer ..by the way ... I just play one in my lab.)
There are a few things:
a) Activate on press or activate on release.
b) De-bouncing can be done in hardware or software. But the idea is you get one press per push.
c) Triggers can be on edges or levels. Sometimes the edges have to be steep.

Current
Generally, you would measure the voltage across a resistor, so you have "high side sensing" and "low side sensing". Low side sensing means the reference can be 0V, but it messes up other stuff. High side sensing means it's in the non common side. So, with the 6700, the voltage measured has to less than the supply and not affect the operation of the circuit. e.g. 3.3V source, 2.8V to the Hallmark device when on. A lithium battery is a relatively flat voltage source, but you won't use one anyway.
 

MrSalts

Joined Apr 2, 2020
2,767
I do like it.. Ya know... I could have just pushed the button down, added a little super-glue to keep it down, and soldered two wires to the battery terminals screwed the battery cover back on, and would have been good to go in a few minutes... sigh!

sooooo, could you be more specific about how this would work... wouldn't You have to close the circuit and "keep it closed" for about 20 seconds, then open it and close it again for the same time. I guess one could add a pot and tune the "on time" to be only a few milliseconds longer than the lighting "on time".. but then there's that charging cap in the light control timer..?

The way it works now... the flicker of darkness at the re-start.. is barely noticeable. 555 is running about 23 hz
You are right, this version (using 555 output to power the sub) would be difficult to control the flicker after each cycle vs the npn version.
 
Top