2
\$\begingroup\$

I tried hooking up a Raspberry Pi (+Hifiberry needs 12 V to 18V input voltage) to my classic car (to be used as music player, radio, BT speaker, no screen, only 2 rotary encoders to navigate through spoken menu). It functions great when connected to an AC/DC convertor connected to the mains, also built in the car when connected to the car battery with the engine off, but with the engine on it starts to behave strange (cutting out music, not responding correct to the rotary encoders). When I turn off the engine all problems dissapear.

As a test I tried it built in the car, with running engine but with power from the AC/DC converter from the mains (so not connected to the car battery/ground at all) and then all is OK.

I already had a buck/boost convertor in my configuration to provide a stable 12V during start and charging from the alternator. I measured the voltage with running engine and its stays at 12V so the buck/boost convertor is working ok. I also did an additional test with a higher output voltage from the buck-boost to 16V and let the Hifiberry regulate it from there, but that also didn’t solve the problem.

So my guess is that the DC power from the car with running engine is not clean enough for the Pi and electrical noise caused by the engine is messing things up and apparently the buck/boost isn’t correcting that either. At the moment I do not have an oscilloscope to measure the signal to see what is going on.

My guess is that I have to put a capacitor in my system to filter out the noise. I thought about making a low pass filter with a resistor in the positive and and a capacitor in between the positive and the ground but as the audio system pulls about 36W max it could draw 3A causing a massive voltage drop over that resistor so I don’t think that would work.

I did find this wiring scheme suggested to use in a car environment (other type of voltage regulator): use of capacitors to reduce noise

I think I will try to use the large capacitor this way but I’m wondering why there is no resistor in series with the capacitor (both in between positive and ground) to limit the charge current. Wouldn’t this scheme lead to a very high charge current at t=0, blowing the fuse? Or would the time be too short for that?

Any other suggestions what could be causing the issues with the audio system?

Thanks for your time.

\$\endgroup\$
11
  • \$\begingroup\$ Read this about the cleanliness of a typical automotive supply - concentrate on superimposed alternator noise. There is also this that is worth a read too. \$\endgroup\$
    – Andy aka
    Jul 20, 2020 at 13:22
  • \$\begingroup\$ Capacitor charge current won't last long enough to blow a slow-blow fuse. There may also be electrostatic coupling directly into signals (NOT via power supply) from ignition systems : a screened box may help. \$\endgroup\$ Jul 20, 2020 at 13:30
  • \$\begingroup\$ The switching frequency of the Class D Amp and stability of the boost mode is compromised by dynamic load current audio. You can measure AC voltage after regulator maybe or improve with lower ESR caps. But Amp's PSRR is only rated for 50,60Hz. \$\endgroup\$ Jul 20, 2020 at 13:56
  • \$\begingroup\$ You mean interference caused by e.g. nearby wires from the car? That is why I did the test inside the car with running engine, but with power adapter from the mains. To exclude vibration or "in-the-air" electric causes. There was no problem in that case. Good to know about the fuse. I think I have a fast fuse, if that one fails I can put in a slow one. \$\endgroup\$
    – AndreP
    Jul 20, 2020 at 13:58
  • \$\begingroup\$ Probably layout/grounding/decoupling issue.Can you descibe the noise in more detail? Does it change with engine RPM? \$\endgroup\$
    – winny
    Jul 20, 2020 at 14:10

1 Answer 1

4
\$\begingroup\$

Ok, some time has passed by now and I got it working. I thought to share my modifications with you, so maybe somebody else in the future will find the answer for his/her problem here on this page.

The changes I made to the system:

  • Added a 2200uf capacitor before the buck/boost convertor (1000 uf probably would have been enough, but I had this one laying around and space wasn't a problem)
  • Added a 100 uf capacitor after the buck/boost convertor
  • Included an NTC resistor before the 2200 uf capacitor to limit the peak charging current during start charge of the 2200 uf capacitor to protect the fuse (maybe not necessary, but I had space for it)
  • Added a ferrite core clamp on the incoming and outgoing power line of the system
  • Changed my wiring from the rotary encoders to the raspberry Pi. Before I used seperate wires for all encoder pins and to limit the number of wires I combined all ground pins together near the rotary encoders so I would only have to run one ground wire back to the Pi. Now I used 0,5m long UTP network cables, which have twisted pairs. For each pin I used a seperate pair with one wire from the pair to the encoder pin and the other one connected to ground. So every pair has at least one ground wire. This should help to reduce interference. Near the Pi all ground wires are combined again and connected to the ground pin of the Pi. This change made the encoders work perfect, also with running engine and during driving.
  • Move all my music files from the USB to the micro SD of the Pi. There is also a bluetooth dongle connected to one of the other USB ports and apparently that can cause problems with continuous playback of the music when on the USB because of some internal limit inside the Pi. Removing the USB from the system as storage for the music files solved this problem.

I installed it all yesterday and had a great drive with a perfectly working music system. Life is good.

Thanks all for your time to help me out.

\$\endgroup\$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.