User Tag List

Results 1 to 2 of 2

Thread: Interior Lighting (Footwell) tied to Door Light

  1. #1
    Senior Member
    Join Date
    Aug 2015
    Posts
    215
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)

    Interior Lighting (Footwell) tied to Door Light

    Hey everyone,
    So I managed to wire some Bluetooth controlled RGB lighting strips into the Evo X so that it comes on when the doors open while retaining manual control (via a switch) when there is ACC power as well. (I can post the wiring diagram later. I did use a diode, a resistor and a MOSFET, although any old transistor would do as well...it's just what I managed to scrounge up at home.)

    I am running into one issue though. My light controller doesn't "remember" the setting so it always goes back to this annoying RGB cycle whenever someone opens the door. Has anyone run into this before? I'm suspect it is because the controller expects a sudden on/off but instead, the dome light yellow wire slowly floats "up" as it disconnects from ground.

    Anyone running the remote control RGB variety into the door light and not have this problem? I'm thinking I should go back to something really simple instead of having the fancy pancy Bluetooth.

    Thanks!
    verkion
    Last edited by verkion; 07-07-2018 at 09:39 PM.

  2. #2
    Senior Member
    Join Date
    Aug 2015
    Posts
    215
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Gah...figured it out. For anyone else who is wondering, the yellow wire is actually a PWM signal. I should have realized this way earlier. Ah well. So for posterity sake, in case anyone else ever wants to wire up Bluetooth LED strips you'll need to do the following:

    1) Tap the yellow wire from the dome light, C-316 harness. This wire appears comes from the ETACS and I *think* is actually a PWM signal. When the doors are opened, a switch in the door pulls an I/O pin on the ETACS low. The ETACS then changes the PWM to 0% (ground effectively) on the yellow wire. This is why it looks like it is simply a DC output. That said, I have not checked with an oscilloscope since I don't have one handy.

    2) So, yellow wire goes "low" when car door opens. If you wire LEDs directly, just find a constant power source (i.e. Fuse 10 inside for the Hazard lights), and put the appropriate current limiting resistor in. Things get more complex if you have a "controller" and you expect it to remember settings.

    3) So it seems the RGB LED controllers that are a) remote controlled and b) Bluetooth controlled, expect a "12-15V" ON and "0V" more or less OFF. If voltage floats in between, or is "semi-rapidly" switched, the controllers seem to reset settings to default. In my case, the Bluetooth RGB LED lights default to "disco mode," flashing R then G then B.

    4) So door opens, yellow goes "low." No problem there...however, then you close the door. If you measure voltage, after 10-15 seconds, the yellow wire reads 4.5V or so. Wait longer, then it eventually drifts to 7V or so. (This isn't actually the case remember, this is likely some PWM voltage.) Regardless, the controller based RGB LED lights, don't know what to do with the "in-between" voltage so it resets to default...disco mode. So everytime I closed the door then opened it again it didn't matter what I had set remotely, it reset back. Super annoying.

    5) So, first things first, we need to basically covert PWM to an analog voltage. And RC, low pass filter is used for this. Input is on the left, Output on the right. The values I used were "kind of" arbitrary. They are a combination of calculation and what I happened to have on hand in my drawers of misc. electronics pieces. http://sim.okawa-denshi.jp/en/PWMtool.php has an excellent calculator for this.
    Attachment 4790

    6) So, now that we have a usable analog voltage output, we need to use it to signal the LEDs on or off. Trouble is, the LED controller wants 12VDC so, we need some sort of component to switch it. No problem, that's what transistors, and FETs are for. I did measure the current draw on my particular LED strip before install and max current (when it tries to have White light output) was 500mA. Small transistors can't switch that much so I chose to use a MOSFET.

    7) Now, there's a small problem yet once again because it turns out the analog voltage is "between" the values for turning on and off the MOSFET, restricting current. Great if you want brightness control, not great if you want the controller to do it. That and, the analog voltage is "inverted." Basically, when it is "Low" the LED is supposed to be ON and when the voltage is HIGH, the LED is supposed to be OFF. Also, it turns out the "high" voltage never gets "high enough," only to 7V max.

    8) So we can do one of two things, we can invert the signal and feed it into an N-channel MOSFET, or we can use what is called a P-channel MOSFET. I chose to use the latter because I wanted to have a switch in my car to turn on/off the RGB LEDs when the ACC is on. (i.e. feed the controller 12V when car ACC is on.)

    9) Regardless of which you choose, we need to convert the analog voltage into full 12V on, or 0V out. We can do this using something called a comparator. From the RC Output of the diagram above, we feed that into a comparator which compares the voltage between two inputs. It then either outputs its full supply voltage (12V in this case) or 0V, depending on whether which input is greater.

    10) To set the reference voltage, I used a voltage divider made from resistors. I put the "inverting input" of the comparator in the middle of a 100K and 47K resistor strung between 12V and ground. This sets the "reference voltage" which the comparator uses to compare the other input, to about 3.84V. So, whenever the "analog voltage" goes above 3.84V, the comparator outputs 12V. And, when the "analog voltage" goes under 3.84V, the comparator outputs 0V. For those of you who are wondering, hysteresis isn't really needed in this case unless you anticipate flipping the door switch on/off repeatedly and quickly. Also, there is a resistor on the output of the comparator going to 12V because there is actually an open-collector transistor on the output...basically, it is needed to assure you get the +12V output and not some weird "floaty value" in between.
    Attachment 4792

    11) So, now we have an output that is +12V and 0V, +12V when the door is closed, 0V when the door is opened. We cannot actually feed this into the LED controller without blowing up the comparator because the controller draws too much power. So, this signal is fed into a MOSFET which is a glorified switch/amplifier. I use a P-Channel MOSFET because I want the MOSFET to conduct when the the comparator output is 0V, and not to conduct when the comparator output is 12V. Basically, if the Gate voltage is less than the source (by 2-4 Volts less), it will allow current to flow between the Drain and Source.
    MOSFET.jpg

    12) Normally a current limiting resistor is used (if wiring only LEDs), but the LED controller is a current controlled device so it does not seem to be necessary. Lastly, the switch to turn on the LED controller while the car ACC is on is wired through a switch and a diode (to prevent current from going the other way).

    13) With this layout you have a) RGB control, b) Main On/Off control (if you like, by wiring the +12V constant voltage through a switch), and c) On/Off control for when the car ACC is on. Here's the full circuit diagram and the parts list below it.
    Full Cct.jpg

    14) Resistors and capacitors are already all labelled. Comparator I used was the LM393 which will set you back less than $2. And the p-channel MOSFET I used was the IRF9520. Do put a mini heatsink on it. It will help prevent the MOSFET from getting too hot.

    That's it! Let me know if you need hlep with anything else!
    verkion
    Attached Images Attached Images

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •