Switch Between 2 inputs - Relay? - Audio, Electrics and Lighting - uk-mkivs

Jump to content


Photo

Switch Between 2 inputs - Relay?

Other

  • Please log in to reply
50 replies to this topic

#1 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 27 June 2020 - 06:18 PM

I have 2 wires with the same output +5v.

Basically there is either 0v in both wires (when off), when item is on - wire 1 has +5v and wire 2 has 0v, or vice versa. Neither wire has +5v at the same time. They “share” the power so to speak.

Currently I have a Manual switch and I flick between the 2 wires depending which wire has the +5v to power my accessory.

Can I use a relay whereby which ever input has +5v it switches and continues my circuit? and which one will I need?

I don’t understand why there is 5 pins?

Am I right thinking: COMM - connect to my device? NC - wire 1 and NO - wire 2? But unsure on 2 inputs??


#2 Imagewerx

Imagewerx

    I'm not the 'droid you're looking for.

  • Moderators
  • 50116 posts
  • Crawley,West Sussexcestershire
  • Bus Stop Backwards Roof Fire -190PS

Posted 27 June 2020 - 09:52 PM

I don't understand what you mean by this.....

 

Basically there is either 0v in both wires (when off), when item is on - wire 1 has +5v and wire 2 has 0v, or vice versa. Neither wire has +5v at the same time. They “share” the power so to speak.

 From what you say,it's random as to which wire has 5 volts and which one is grounded? Or do they alternate each time you operate it? It also might help to know what the function is you're trying to do here.



#3 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 28 June 2020 - 12:24 PM

5 pins, no idea what you're doing/what it's supposed to, what the accessory is...


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.


#4 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 28 June 2020 - 01:48 PM

I will explain.

I have a bmw with idrive. I need an illumination wire for a boost gauge. There is no 12v fused supply for this. However there is an led above the ashtray that comes on with the lights. It has 3 wires going into it, 1 is ground and other 2 are positive depending what light setting you have selected on the idrive (Classic - red led or sport - white led).

I have stepped up the voltage from this supply to around 7v to the boost gauge (otherwise it doesn’t recognise any input) which all works fine. However, the boost gauge is currently being supplied by the sport - positive wire and if classic was selected and the lights are on then the boost gauge will not dim as its being supplied from the other wire. So, only 1 wire has the supply at one time. I would like to somehow pair them up and switch automatically to feed the boost gauge illumination wire depending which one is live.

I tried running together but then both the red and white is on at the ashtray.

Does it make sense? I am thinking of a relay but unsure on which one and how to wire it.

Edit: the voltage from led live is actually 2v (not 5v). So I need to step it up for a relay to work as most need at least 5v like my dimmer.

#5 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 28 June 2020 - 06:15 PM

Two transistors should be fine, driving the output high when an LED is on.  No need for relays.


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.


#6 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 28 June 2020 - 06:20 PM

Two forward facing diodes.

Diode 1 - Anode to classic LED positive. Cathode to boost gauge.

Diode 2 - Anode to sport LED positive. Cathode to boost gauge.

So diodes cathodes are wired together leading to boost gauge.

Simple one :)

Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#7 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 28 June 2020 - 06:23 PM

Whoa double post 😲

Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#8 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 28 June 2020 - 06:33 PM

The LED's are sitting at ~2v minus a half-volt drop over the diode, so it won't drive the dimmer circuit at 1.5v.  Don't think that would work.


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.


#9 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 28 June 2020 - 07:42 PM

I am misunderstanding what the OP wants?

Boost gauge illumination to be powered from either LED?

Via existing boost converter?

:)

Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#10 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 28 June 2020 - 07:58 PM

Could do what you're suggesting but I don't think a boost converter will boost from 1.5 to 12?  I think it just needs to see 12v signal to dim the gauge.


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.


#11 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 28 June 2020 - 08:08 PM

The wires he is attaching to are 5V, topside feed to the LED, in first post?

So he's doing 5V to 12V via boost converter. Not sure he wants dimming, just wants rid of manual switch?


:)

Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#12 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 28 June 2020 - 08:11 PM

The wires he is attaching to are 5V, topside feed to the LED, in first post?
 

 

Edit: the voltage from led live is actually 2v (not 5v). So I need to step it up for a relay to work as most need at least 5v like my dimmer.


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.


#13 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 28 June 2020 - 08:21 PM

The wires he is attaching to are 5V, topside feed to the LED, in first post?

So he's doing 5V to 12V via boost converter. Not sure he wants dimming, just wants rid of manual switch?


:)


I thought about diodes. But didn’t quite understand which ones I needed.

I have to step up the voltage from 2v to 12v as the 2v is not enough for the boost gauge to recognise an as an illumination input. I have managed to step it up fine. Just either need a relay or diodes but which diodes do I need and should I put them before or after the step up module?

#14 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 28 June 2020 - 08:30 PM

You'll lose half a volt over a diode.  Will the boost converter go from 1.5 to 12?


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.


#15 Imagewerx

Imagewerx

    I'm not the 'droid you're looking for.

  • Moderators
  • 50116 posts
  • Crawley,West Sussexcestershire
  • Bus Stop Backwards Roof Fire -190PS

Posted 28 June 2020 - 08:35 PM

Any regulator diodes will do,such as 1N4001 etc.You won't get a relay that works at less than 5volts,so as Adam has said you'll need a single transistor to switch a 12volt relay.Like this......

https://sites.google...r-for-solenoids

 

This switches when it goes high by as little as 0.1 volts.If you wanted it to switch when it goes low,you'd use a PNP transistor.Also,if there's any residual voltage at all on those wires (they don't rest at exactly 0.000000000volts!) it'll pick that up and will stay switched all the time.If that is the case,you'd have to connect a 10K (or there abouts) pull down resistor between those two wires and ground to keep it sitting at exactly no volts.The resistance is high enough that it won't affect the normal operation of the circuit.



#16 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 28 June 2020 - 09:05 PM

Ah didn't notice the edit.

That makes it much harder.

The current limiting resistors for the LEDs are obviously in the cars convenience module. So you are reading the LED forward voltage when you measure.

You need a super sensitive input that will steal almost zero current from the LEDs and 'power' your boost converter. A two stage NPN transistor circuit would do it but you are making life really hard for yourself. Basically you need to nick maybe 100uA and drive a transistor. DC gain of a single transistor (200-400 typical) probably wouldn't be enough, you would only get 20-40mA of collector current, barely enough to drive a relay coil. Two stage would easily do it.

My advice, find a better source.

:)

Edit: You could steal more current for a transistor base drive but you will start to affect LED brightness if you're not careful. Hence a two stage solution IMHO.
  • vwgtiking likes this

Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#17 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 28 June 2020 - 09:26 PM

The circuit imagewerx linked to will steal 140uA (with no wired OR diodes).
It might be enough to drive a relay coil.

Max relay coil current would be 28mA assuming 200 gain. Normally you would factor in at least a 4:1 safety margin. The 10k resistor would have to be decreased to 2k7. This would steal 519uA and would dim the LEDs slightly on the car.

You would need a relay with quite a sensitive coil (lots of windings).

Still marginal IMHO.

:)

It still depends somewhat on the internals of the module driving these LEDs. Wish I could sketch circuits here to show the issue.

Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#18 Imagewerx

Imagewerx

    I'm not the 'droid you're looking for.

  • Moderators
  • 50116 posts
  • Crawley,West Sussexcestershire
  • Bus Stop Backwards Roof Fire -190PS

Posted 28 June 2020 - 10:03 PM

A further thought is they could be driven by a PWM circuit,so could make things a whole lot more interesting.


  • NooNoo likes this

#19 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 28 June 2020 - 10:10 PM

Yes, true. Is the dash dimmable and these LEDs follow?

The relay solution is so marginal, you could use a Darlington transistor but it's still not great.
Looked on eBay for a sensitive input relay switching PCB, none found.

Best solution is a better source 😉

Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#20 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 28 June 2020 - 10:39 PM

Currently I have both of the wires wired up to a switch. Position 1 and 3, with position 2 as the out put. Then the output is stepped up to 12v. I can switch manually between position 1 and 3 depending which wire is “turned on” and my boost gauge dimms.

Just looking for an automated way of switching between the 2 lives.

Will try a relay with step up modules and if that doesn’t work then I may go with a a safe manual version. Using an ignition live with a switch.

Tbh you guys are loosing me with the electronic jargon. Lol

Type in bmw f30 illumination wire in google. There isn’t one. lol

#21 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 28 June 2020 - 10:43 PM

This is the 12v step up I have used


https://www.ebay.co....tm/184334002595

#22 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 29 June 2020 - 07:03 AM

Surely the BCM that controls the lights drives the rear/front lights with a 12v signal, just tap into that? 

On the E39 there is a dimmed illumination in each door, I used for handles.  For reverse, I tapped into the reverse light at the BCM at the front.


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.


#23 Imagewerx

Imagewerx

    I'm not the 'droid you're looking for.

  • Moderators
  • 50116 posts
  • Crawley,West Sussexcestershire
  • Bus Stop Backwards Roof Fire -190PS

Posted 29 June 2020 - 07:07 AM

The relay driver will work,trust me as I've used it dozens of times.You don't need the step up module as the relay will switch full supply voltage.

 

These components are needed and will 100% work...........

1N4001 diodes   X3

NPN transistor   X1

12volt relay   X1

10K 1/4 watt resistor    X1

 

This will give you a 12 volt on/off controlled by your dashboard illumination that you will need to drop using a series resistor if you're driving an LED with it.The other alternative is the sidelights output from what ever you have in that car that controls the external lighting.Either an LCM (Lighting Control Module) for earlier cars ot FRM (Footwell Module) for later cars.



#24 Earl_C

Earl_C

    Just grazing

  • Full Members
  • PipPip
  • 271 posts
  • Shropshire
  • Other Models

Posted 29 June 2020 - 03:22 PM

wire straight to the battery. Works everytime. Won't do your car any good mind xD


Amateur build thread : https://uk-mkivs.net...-green-machine/ Now deceased, see here for parts  https://uk-mkivs.net...howtopic=649256

Crisis Car: https://uk-mkivs.net...er-life-crisis/

 As Dan FR once said "If you don't like the answers you get, don't let the door hit you on the way out"


#25 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 29 June 2020 - 03:32 PM

I still think that relay will be lazy! 10K would need lowering IMHO. 2K7 would do it with the right relay.

 

NGEBOlh.jpg

 

This would work as you can set the threshold voltage to 1V. You still need the 2 diodes. 2 x 1N4148 would be sufficient.

 

https://www.ebay.co....qkAAOSwhEhcHGD~

 

:)

 

2K7 base resistor revised calcs. hFE = 200.

 

Ib = 296uA.

Ic max = 59mA.

 

With an Ic of 59mA that is a relay with a coil power of 12v x 0.059 = 0.71W. This is a more healthy relay coil drive current :)


Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#26 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 29 June 2020 - 03:39 PM

The relay driver will work,trust me as I've used it dozens of times.You don't need the step up module as the relay will switch full supply voltage.

These components are needed and will 100% work...........
1N4001 diodes X3
NPN transistor X1
12volt relay X1
10K 1/4 watt resistor X1

This will give you a 12 volt on/off controlled by your dashboard illumination that you will need to drop using a series resistor if you're driving an LED with it.The other alternative is the sidelights output from what ever you have in that car that controls the external lighting.Either an LCM (Lighting Control Module) for earlier cars ot FRM (Footwell Module) for later cars.

Thank you. How is it wired?

Which transistor will I need?

2 wires, diode on each, into the transistor, 3rd connection on transistor- output to diode to the relay? Where does the resistor go?

#27 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 29 June 2020 - 03:41 PM

I still think that relay will be lazy!

NGEBOlh.jpg

This would work as you can set the threshold voltage to 1V. You still need the 2 diodes. 2 x 1N4148 would be sufficient.

https://www.ebay.co....qkAAOSwhEhcHGD~

:)


It has extra connections? What is it for?

#28 vwgtiking

vwgtiking

    Hang on like this MKIV thing

  • Full Members
  • PipPipPipPip
  • 4956 posts

Posted 29 June 2020 - 03:42 PM

What’s the difference between the diode you both advise?

#29 NooNoo

NooNoo

    NooNoo

  • Full Members
  • PipPipPipPipPip
  • 9360 posts
  • Leicester
  • Golf IV GTI 1.8T 20v AGU 150PS

Posted 29 June 2020 - 03:55 PM

Not much really, the 1N4148 will drop more like 0.5V and are classed as signal diodes. The 1N4001 would work with a little more voltage drop, perhaps a little OTT.

 

:Y:


Golf 1.8T AGU | 232Bhp | Rtech | k03s | Blueflame turbo-back exhaust | K & N panel | SFS / Forge hoses | TurboRevs SMIC | VR6 Clutch | SMF | Saikou Michi catch can | Bilstein B14s | S3 upper & lower braces | Eibach 25mm ARBs | All SuperPro bushes | 312mm/256mm brakes | 18" BBS RCs | Rline rear | R32 front | Hoefle skirts | OEM Xenons | Retrofit heated seats | One touch demister | W8 Interior light | Sunroof | TT Hubs | TT wishbones | TT quick rack |


#30 adam-

adam-

    VR6 GT35 4mo

  • Full Members
  • PipPipPipPipPipPip
  • 10757 posts
  • Glasgow
  • Golf IV GTI 1.8T 20v AUM 150PS

Posted 29 June 2020 - 03:57 PM

The diagram NooNoo has provided is how to do it. I was going to do similar using two transistors, but two diodes/one transistor does it fine too.  


facebook.com/adamforbes92, ig:@adam_g4fku, Adam's Anthracite Grey 1.8t Build Thread...

Best way to lose weight is not drinking mayonnaise/cheese/beer everyday.






Also tagged with one or more of these keywords: Other


uk-mkivs.net is an independent Volkswagen enthusiast website owned and operated by VerticalScope Inc. Content on uk-mkivs.net is generated by its users. uk-mkivs.net is not in any way affiliated with Volkswagen AG.