Flip "on" status of LED?

Started by lars-musik, September 17, 2018, 09:56:42 AM

Previous topic - Next topic

lars-musik

Dear Forum,

after some fruitless tries I finally got Mictester's Relay Bypass working. Unfortunately I didn't look close enough at the datasheet of my relay and flipped the bypassed and the activated status. That in itself is of no consquence, but the LED now lights up when the effect is off (and that is really confusing...).
Is there a simple way to flip the led on-status in that circuit  (I had ten boards fabbed and would like to use them still)?

Thanks!


amz-fx

Move the R3 connection from pin5 to pin 6 of IC1C. I doubt that the extra load on the output will impact the action of the circuit.

regards, Jack


duck_arse

.... or .... connect the LED anode to R3, and the kathode to ground.
don't make me draw another line.

ElectricDruid

Quote from: duck_arse on September 17, 2018, 10:34:52 AM
.... or .... connect the LED anode to R3, and the kathode to ground.

Just what I was going to say, Duck. Flip the LED and take it to ground not +9V.

Great minds think alike, but unfortunately for us fools never differ either. ;)

lars-musik

I love this forum! Thanks to you all.

anotherjim

Are the unused inverters really wired out like that? Think about it.


ElectricDruid

Quote from: lars-musik on September 17, 2018, 03:18:39 PM
Quote from: anotherjim on September 17, 2018, 02:02:09 PM
Think about it.

Mmmmh...  Me or you?

He means if you tie the inputs low, the output go high. So then tying the outputs low too is going to mean the outputs are fighting against ground.

I dunno whether that's safe or not, but I see the potential problem AnotherJim's pointing out. What happens in that situation?


PRR

> What happens in that situation?

The 40106 runs hot.

Looks to me like 3* 13mA. 40mA.

As you could buy a non-latching relay of 40mA need, you saved nothing.

Tying outputs to ground is NEVER (hardly ever) the right thing to do. Get your small sharp axe and snip those 8 10 12 traces.
  • SUPPORTER

lars-musik

Quote from: PRR on September 17, 2018, 08:42:59 PM
> What happens in that situation?
Get your small sharp axe and snip those 8 10 12 traces.

Will do that and report back.

diffeq

Quote from: PRR on September 17, 2018, 08:42:59 PM
Tying outputs to ground is NEVER (hardly ever) the right thing to do.
Would that still be a problem if inverter input was tied high?

anotherjim

If you tied the output low and input high, it would run cool, but during power-up, there might be a very short period (nano-seconds!) of disagreement between the internal stages until they obey the logic and there is a momentary high current flow in the output stage of each inverter. I don't believe it would be fatal. I've never seen an internal equivalent scheme of the 40106, but it is a buffered multi-stage inverter, unlike the 4049U or 4069U. You can see apparently crazy, non-logic use of those other two, but not the 40106.
For unused logic, tie the inputs high or low to suit the easiest pcb trace runs but never connect the outputs to anything.

In this design, it looks like inverter IC1c supplies the current pulse for the positive relay operation. It could be given some help by wiring one or more (all 3 if you like) of those spare inverters in parallel with the c inverter - that way at least they are doing something. But you say you have already made pcbs....

lars-musik

Quote from: anotherjim on September 18, 2018, 05:22:32 AM
But you say you have already made pcbs....

Well, it seems that the room for improvement keeps adding up, so I guess a new version would be in order.

The hex inverter chip is a SMD, so the small sharp axe PRR was talking about needs to be tiny indeed.....




So, now that we're into it, would this look better?




Fender3D

4 inverters vs 1 tiny transistor...
it's unfair!
You might as well use 1 or 2 inverter(s) to drive the LED thus further decoupling it...
"NOT FLAMMABLE" is not a challenge

lars-musik

Quote from: Fender3D on September 18, 2018, 06:16:57 AM
4 inverters vs 1 tiny transistor...
it's unfair!
You might as well use 1 or 2 inverter(s) to drive the LED thus further decoupling it...

If only I'd know how. Honestly, I want this thing to work. Like me, it has to funtion reliably but need not necessarily be elegant.

Fender3D

with the correctly connected relais simply pick 2 out the 3 leftover inverters, connect them in series then the 1st inv.'s input to U1.2 pin 4 and the 2nd inv. output to R3's pin 2
with the flipped relais just connect one inverter instead of 2 in series.
"NOT FLAMMABLE" is not a challenge

anotherjim

Well, honestly I wasn't calling for a total redesign...
I think the use of the BJT transistors to provide the reverse latch action of the relay was out of concern that an inverter might be damaged by high flyback voltage from the relay coil.
However, I think the 4 inverters in parallel like that could directly drive the +plate of C3. Concern about coil flyback could be dealt with by a pair of protection diodes in the usual way, like ...

...might want to breadboard that first, although it should work.
Then drive the LED from that too after checking what polarity it wants to agree with the relay function.

That said, if you were on a plane that's about to land, do you want the pilots "wheels down & locked" indicator to work off the undercarriage mechanism or from the control lever? I'd prefer the former. You want to indicate what it's done, which may not be the same as what it's being told to do. Latching relays can be out of step with the control, but you probably would need another contact set on the relay to do that.

merlinb

Quote from: lars-musik on September 18, 2018, 05:45:06 AM
The hex inverter chip is a SMD, so the small sharp axe PRR was talking about needs to be tiny indeed.....
Can you just snip through pins 8, 10, 12 with some fine clippers? Or melt the solder and lift them off the board?

R.G.

You're getting good advice. The general rule with CMOS is that you can leave outputs open and unconnected, but never, never leave an input open. An input must always be tied to either ground or the + supply or the input will happily accept random electrical fields in the air as inputs. and never tie the output of a gate to the input of the same gate, unless you are deliberately trying to bias it into linear conduction for an amplifier. Overheating and/or oscillation, depending on the gate, can easily happen.

But you are already using one CMOS hex inverter and two transistors. Why not go for a latching relay? For about the same parts count, you can do this:

It uses the same flipflop with a momentary switch, but it uses the rest of the inverters to convert that flipping into a momentary pulse to a latching relay. This lets the relay flip stage and then quit using current until the next time you want it to flip.

I must admit that I am mildly addicted to MML (Mickey Mouse Logic) done with spare CMOS gates.   :) 
R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.

duck_arse

Quote from: lars-musik on September 18, 2018, 05:45:06 AM

Well, it seems that the room for improvement keeps adding up, so I guess a new version would be in order.
.......

So, now that we're into it, would this look better?




what was the original question, again?
don't make me draw another line.