Audi A5 Forum & Audi S5 Forum banner
1 - 9 of 11 Posts

Registered
Joined
62 Posts
Discussion Starter · #1 ·
Hello guys,

Ever since I got the car, I always wanted to have some additional ambient lighting in the door card trim.
I have been tinkering with it for some time now and finally i have something to share. I hope I can get peoples opinions on it.
Pictures say a thousand words so what I would like is ambient light in the places marked in red:
Vehicle Automotive design Motor vehicle Personal luxury car Vehicle door


I would like to make it very subtle, so not very thick, just a small thin stripe of light.
And my goal is to make it look like it came from factory like that. I think that otherwise it would look like a hack/cheap.

THE LED STRIPS
Everyone is probably familiar with the LED strips, they are used everywhere and are quite cheap, but they are quite big for this application.
I managed to find an LED strip that is much smaller and also comes with frosted plastic body to diffuse the light and make it light up evenly throughout.
Here is a picture comparing the two and showing the light diffuser:

Gesture Finger Thumb Natural material Font


At the bottom of the picture you can see the smaller strip taken apart showing how small the LEDs actually are. The white piece is the light diffuser. The whole thing is wrapped in black tape that is reflective on the sticky side so the light is bounced back and is more intense. Pretty sweet. The small strip is 8mm wide and 2mm thick and can be cut to length.

And I forgot to mention, its also an RGB strip, meaning you can apply a different voltage to Red, Green and Blue lines separately, which allows you to mix colours and choose the one you like. It has 3 power inputs for the 3 colours and a common ground. The colour lines can be powered by 12v for max brightness.

I will only use red colour though, as it matches the light of console buttons in the car.

POWER SOURCE
The idea is to power the strip from the same power source as the inside door handle illumination. It's a 12v source that dims together with the cluster brightness adjustment.
This source can be used also on cars that don't currently have the door handle illumination in which case the pin for it is still there in the door ECU and needs to be turned on via VCDS
This is pin 3 on the front doors and pin 1 on the rear doors ECU. The brown wire is ground in both doors.

TEST PIECE
So far, I have built a small routing table with a rotary/dremel tool mounted to it.
This will be used to cut a 2mm groove/slot in the door trim so that the LED strip can sit in flush.
I then cut a piece of acrylic using it as a test piece, and fitted a small length of the LED strip into it. Here is how it looks:

Table Rectangle Wood Drawer Desk
Table Wood Flooring Wood stain Floor
Brown Wood Insect Flooring Wood stain
Wood Table Rectangle Wood stain Plank
Sensitive content, not recommended for those under 18
Show Content
Hand Wood Finger Gesture Bumper


Wood Rectangle Grey Flooring Floor
Wood Floor Flooring Bumper Automotive exterior


NEXT STEPS
My own door trim has the brushed aluminium finish, but I am not willing to risk cutting it up so I bought a cheap second-hand door trim set out of an A4 (A5 and A5 share these parts). The set I bought is a basic trim level set - just plastic and no aluminium or other inserts in it, so that its easier to route the grove in it. The plan is to wrap it in brushed aluminium vinyl later on, to get the original look.
The A4 also has an additional trim piece on the passenger side, above the glove box, so I will use that as my next test piece.

Dishware Wood Rectangle Publication Tableware


---------
I got my inspiration from this link, although it is in Spanish and the man used the larger LED strip which was a more invasive method, and I think he needed to cut up the door card from the inside to get it to fit.
 

Registered
Joined
62 Posts
Discussion Starter · #3 ·
Here is a picture with the light in the room turned off.
Its hard to show it properly on camera, so there is a backlit keyboard on top of the picture to compare the brightness to something else.
I think that if anything, it will need to be dimmed down when its in the car, and that's currently shown driven at 5v and not 12v, so it can be even brighter.

Automotive lighting Computer keyboard Peripheral Input device Space bar
 

Registered
Joined
62 Posts
Discussion Starter · #4 ·
So using the routing table I made, I went ahead and cut a slot on top of the passenger side A4 trim piece that I decided to sacrifice as a test piece.
I did a few passes until I got the right depth as I kept test fitting the LED strip. I then sanded the trim surface slightly and degreased it before wrapping.

The wrapping vinyl I got turned out not to be the best quality, as for example it is not perforated so some trapped air bubbles occurred.
I also managed to get some pieces of dust stuck between the trim and the wrap so they are visible in the bottom left corner. But its just a test piece so it will have to suffice.
I am not a wrapping pro, but apart from the issues above I think it turned out acceptable, and looks quite close to actual brushed aluminium.
I think if you didn't put the wrapped and real thing side by side, you wouldn't be able to tell. I have my centre console wrapped already and it went well with the stock door trims with real brushed aluminium.

I then glued the LED strip in place and the results are below. Personally I really like it.
The only negative I can see is that the profile of the LED strip does not match the curve of the top edge of the trim, so the corners stick out 1mm or so.
But I think the door trim pieces top edges have a sharper corner rather than a radius like this one, so it should be less visible and not stick out as much.
There is a piece of the LED strip wrapped around the back of the panel, that obviously will not be there, I just did it like that for the test and to power it in the easiest way possible.

Wood Rectangle Automotive exterior Tints and shades Bumper


Rectangle Wood Flooring Bumper Hardwood
Rectangle Wood Bumper Flooring Composite material
Gadget Rectangle Communication Device Wood Office supplies
Line Font Rectangle Pattern Aircraft


Rectangle Wood Grey Font Material property
Grey Audio equipment Gadget Wood Rectangle


Light Rectangle Line Bumper Floor
Bumper Rectangle Vehicle door Automotive exterior Tints and shades
 

Registered
Joined
62 Posts
Discussion Starter · #5 ·
I also found another version of this small LED strip which has individually addressable LEDS, WS2812 exactly.
Whereas the current one has RGB LEDs all connected together, which means they all have to be same color and brightness.
These are very popular and Arduino libraries exist so it's easy to use and program. This allows me to make small animations with the LED strip.

I was playing around with it and so far, I came up with the following idea:
When the car is unlocked via fob, the strip gets power and turns on, first it does a startup animation which will be a swipe of light in both directions (kind of like a loading bar) and then dimms down to a set brightness.
Then when opening the doors, it will swipe one way and when closing it will swipe the other way.

The plan is to have the brightness really low for nighttime, so it's not distracting, and bring the brightness up during the day so that its actually visible. The input signal for distinguishing between these 2 modes can be taken from the door button illumination line. ON = nighttime and OFF = daytime.

 

Registered
Joined
62 Posts
Discussion Starter · #7 · (Edited)
I do agree its a very fine line. I checked what is out there and considered my options.

There is a light fiber that you light up from one end, but from what I saw it doesn't light up evenly throughout, and it is kind of a press fit into the gap between trim pieces, so that looks like a half-arsed job in most cases, as it doesn't sit flush with the trim.
Also in most cases the points where the light strip starts and ends look like the strip is a cheap add-on and not part of the car originally, so and that is something I'd like to avoid.
Example here: Video 1
Another example here: Video 2

You can also buy a set of trim for the B8 that is very similar to what I am trying to do (incorporates the light strip into the trim neatly and tries to make it look somewhat OEM) but the only ones I could find come in carbon look, and it clearly looks like fake carbon at that. It's also very expensive as the only option I found is a kit with other lights like door pockets etc.
Video 3

Here is my main inspiration, although me using thinner light strips will make it more subtle and better, I think.
Video 4

Speaking about tacky:
Car Vehicle Speedometer Steering wheel Motor vehicle
 

Registered
Joined
62 Posts
Discussion Starter · #8 ·
Hello,

I ordered more aluminium look wrapping vinyl with air release pinholes so hopefully that's better quality.
I have to wait for it to arrive so I moved onto the electronics side of things.

I used an Arduino microcontroller to drive the animated LED strip from the video above, but I chose to use the ATtiny85 for the real deal. It's very small and can be glued with double sided tape to the underside of the door trims.
Circuit component Hardware programmer Finger Thumb Electronic component


The arduino is a much more capable MCU compared to it, but in this project it does all I need it to do (not a lot to be honest) and the small size is a plus.
It also has an on-board voltage regulator so it can be powered by the cars 12v system even though it's made to run at 5v.

Like I said in the first post, the plan is to power it with the same supply that powers the internal door handle illumination. This means it will power ON when unlocking the car, and still stay ON for a few seconds after locking the car.
The only issue with that might be that the door handle light supply might be pulse width modulated to control brightness. I'm not yet sure if the ATtiny can be powered with a PWM signal, even at higher duty cycle. I'll have to check that out first.

Next is the issue of sensing when the door is open/closed or when to turn on day/night mode.
Door open = puddle light ON
Night mode = buttons illumination ON

I can tap into these wires and use them as inputs to the microcontroller to determine what to animate on the LED strip. However these are 12v and I need 5v input signals, otherwise the ATtiny will break.
The solution is to use a voltage divider circuit. Since it's a car and we care about safety, we should use an automotive style voltage divider that has clamping diodes as a protection during higher voltage.
At 12 V, the circuit will deliver 3.6 V to the Arduino pin which is a clean HIGH input signal. This circuit is principally for automotive use where the voltage input may routinely be as high as 14 or even 15 V.

Rectangle Slope Font Line Material property


The safety feature here works like this, when the voltage is so high that after R1 it is more than 5.7v, D1 starts conducting (most diodes need 0.7v to turn on) and lowers the potential at that node, making it safe again.
From my testing, when Vin was 15V, the voltage at the anode of D2 was 5.12V, so still not enough to turn it on, so this protection kicks in at even higher voltages, e.g. voltage spikes.

I designed a PCB that has two of these automotive voltage dividers on it. The ATtiny will sit on top of it, and it will also have 2 connectors, one with 4 pins for connecting to the car (power, gnd and the 2 inputs) and a 3 pin connector to connect the led strip (5v data and gnd)
To manufacture 5 of them costs 3USD on JLCPCB so it's not expensive, but I will get it ordered when I confirm that the ATtiny can work with the cars supply.
If it turns out that the supply is PWM and can't power the ATtiny, I will look into it and probably add stuff to it to make it work.
The PCB is 45mm x 25mm in size, and most of it is empty space for the ATtiny. It's only 8 components after all.

Slope Rectangle Font Parallel Pattern
Rectangle Font Parallel Screenshot Engineering
Circuit component Rectangle Font Hardware programmer Engineering
 

Registered
Joined
62 Posts
Discussion Starter · #9 ·
Hello,

Last weekend I managed to take the door card off and tap into the signals that I am interested in, and route cables to do some testing.
I prepared the circuit and the microcontroller on a breadboard before i order the PCB and tried testing it out.
I confirmed that the voltage dividers are dropping the voltage to a usable level, so the microcontroller will be able to tell when the door is open/closed or will know if its night mode when the switch backlight is on.

Unfortunately it appears that the door module is limiting current for the inside door handle (I planned to use this to power everything), because as soon as I connect the circuit, the handle light switches off and there is a fault when the car is scanned. The light comes back next time you unlock the car.
It works when powered via the puddle light - of course that only works when the door is open.

So the plan now is to use a relay of some sort, to get power from somewhere else (the door control module must get a constant 12v somewhere) but still use the inside handle light to trigger the relay.

Another issue is that the inside door handle light is powered with at PWM signal. So it still needs to be smoothed out, otherwise it will cycle the relay really quickly.
Maybe a low pass filter circuit or putting a decoupling capacitor between that signal and ground will work. That's some more experimenting i need to do.

Gadget Communication Device Audio equipment Electronic instrument Display device


Here are the pinouts of signals on the door control modules:

FRONT:
handle light - pin 3
ground - pin 5 (brown)
switch backlight - pin 4
puddle light - pin 16

REAR:
handle light - pin 1
ground - BROWN cable
switch backlight- pin 2
puddle light - pin 12
 

Registered
Joined
62 Posts
Discussion Starter · #10 ·
Hello again,

It has been a while, but I found a suitable relay, and have a smoothing method for the PWM signal so that it can be used to trigger the relay. The whole setup is getting closer and closer.

The relay I selected is an OMRON G3VM-61VY3 , it is a solid state relay, MOSFET based, rated for 60V and 700mA. It's a surface mount chip that will go on the PCB, it's also very small which is great.
Datasheet is here: https://www.farnell.com/datasheets/2614461.pdf

I couldn't find if it's rated for 700mA in general, or for 700mA at 60v, which would imply it can take more current at lower voltages.
Either way, I won't be exceeding 700mA anyway. Below is a breakdown of current draw in different situations.

Current draw is mostly based on the number and brightness of the LEDs, the more LEDs and the brighter they are, the more current is drawn.
With the strip I am using, 52 LEDs are needed to cover the full length of the door trim panel, so I tested the current draw with 52 LEDs.

brightness 65 (day mode) ----------------------------------------- 110mA
brightness 20 (night mode) --------------------------------------- 95mA
max current at door open/close swipe animation --------------- 115mA
max current at startup animation (brightness up to 200) -------- 245mA momentarily
current at max (brightness 255) ----------------------------------- 315mA

So the whole system draws 315mA at full brightness, (this will never be used as it's just too bright) which is below the limit.
At normal day mode usage it's going to be 110mA at most, and while doing the animations it goes up to 245mA very briefly, so it's still well below the limit



When it comes to smoothing the signal, I saw that simply adding a decoupling capacitor between the signal and ground does the job.
For example if you have a 9V PWM signal at 50% duty cycle, a large enough capacitor will smooth it out and give a linear voltage of roughly half of the input.

You can see an example of this here:
circuit 1 - just decoupling capacitor

And what happened when I put the circuit together:
Gadget Communication Device Audio equipment Gas Display device


The issue here is that the signal I want to use to trigger the relay is also driving the inside door handle illumination LED.
It will still work, but this smoothed voltage that is now averaged to about half of its original value, will cause a drop of brightness in that LED, compared to when driven by PWM.
To avoid that, I saw that we can split the signal into two lines and add a diode on one branch, so on the first branch the door handle LED gets the original PWM signal, and whatever is after the diode on the second branch is smoothed out and can be used as relay input.

This circuit is illustrated here:
circuit 2 - diode and capacitor
I find it works quite well and a much smaller capacitor is needed.

Simulations are one thing and real life is another, but they are close. In my testing I used an Arduino board to generate the test PWM signal, however the Arduino is capable of generating PWM of 5V at 490Hz, so a bit different than the 9.3V at 156Hz coming from the car (I was expecting 12V but saw 9.3V on my oscilloscope shown in the last post, so I'm going with it and not questioning it), meaning the real capacitor value will need to be selected while testing on the car itself.
The picture below shows the original input PWM signal in yellow and the smoothed output signal in blue. Output voltage is a bit lower as the voltage drop across the diode is 0.7V
Light Product Gadget Audio equipment Oscilloscope



The voltage of the output signal doesn't matter (as long as it's not too low), but an appropriate resistor needs to be selected to drive the relay input at around 5-25mA of current.
I noticed that the button illumination signal is also PWM, so a similar smoothing will be needed, so that the attiny85 can properly sense this signal and switch between day and night mode.
This signal needs to be between 3.5V - 5V, to give a logic 1 to the attiny85, so I might need to have the smoothing circuit followed by a voltage divider to drop it down.

Both PWM signals will have their duty cycle vary with the backlight brightness adjustment. I need to take that into account as well, so that smoothing works throughout the whole range.
The puddle light signal to detect door open/closed is not PWM so the original plan of using a voltage divider will work here


I noticed that the voltage regulator on the attiny85 that I have gets warm when powered with 12V, I looked it up and saw that it is a 78L05 and it's rated for only 100mA.
I ordered a different version of the attiny85 board with a 78M05 regulator rated for 500mA instead. Again that will be a safe margin, as you can see from the picture the regulator is quite a bit different.
Circuit component Passive circuit component Hardware programmer Electronic component Font


I have yet to identify a constant 12V source at the door to use at the other side of the relay, but I have pictures from when i took the door card off, and it's probably going to be one of these:
Automotive tire Motor vehicle Automotive design Grey Electrical wiring
 

Registered
Joined
62 Posts
Discussion Starter · #11 ·
Hello again,

I did some more testing of the new smoothing circuit on the actual car this time. It works. (y)

I still didn't tap into the constant 12v, so for testing I am using the puddle light as a 12v power source, so the door needs to be open for it to work.
That's why in the video below you see the system turns on once the door is opened.
Already I can tell that the day mode brightness is too low but that's not an issue, as it can be adjusted any time in code.


I was worried that the smoothing will have to be done at a wider duty cycle range of the PWM signal, but it turned out that MIN value was about 65% and MAX is 100% so the range is quite small.
If MIN value was more like 20% then there would be issues, as the capacitor would not have enough ON time to charge up and output a smoothed signal with a load on it.

At the MIN value, the current driving the input side of the relay is 4.24mA at and 4.68mA at MAX. The relay turns on fully at 0.5mA and the max recommended current is 25mA, so that's all good too.
The smoothed waveform is actually identical to what i saw on the sim done on falstad linked above, so that's pretty cool.

The picture below shows the input and output signals on the actual car. The yellow is the original input, the blue is the smoothed output that's driving the relay.

Textile Denim Bag Electric blue Electronic device


Next I need to do something similar for the button illumination signal, as it is also a PWM signal, and I intend to use it to switch between day and night mode (button illumination ON = night mode).
However the smoothed output in this case can't be more than 5v while the input is 12V PWM, so I think a voltage divider or a clamping circuit of some sort after the smoothing circuit will do the job.
 
1 - 9 of 11 Posts
Top