Car Pi (hardware)

To keep the post (reasonably) short I’ll break it into 2 pieces, mostly hardware related and mostly software related, and apologies for lack of additional pictures, will add them when I pull the unit out to work on it again (probably this weekend)

The idea of having a touch screen in your car has always been high on my tech bucket list. Also, I love to build stuff, I like the idea of taking pieces of tech and strapping them together to make something that’s more than the sum of it’s parts, and learning something in the process. I also have a constrained budget, I like to reuse and recycle parts as much as possible.

So to start, here’s my list of parts (and reasoning):

A Raspberry Pi 3 B+, I wanted the on board wireless to eliminate an additional USB dongle, and the Bluetooth for later projects.

A Raspberry Pi 7″ Touchscreen, I had used this as a wall mounted dashboard for my home automation project, but wasn’t really used so purposed it for this.

A HiFiberry DAC+ Pi HAT, the audio from the Pi is not known for it’s awesomeness, wanted a Pi HAT to solve this and give me RCA audio out.

The PiJuice HAT, for … reasons:

  • Remove any possibility of the unit draining the car’s battery while giving me the ability to gracefully shutdown the Pi. Yes, I’m aware there are other options I could use by using a combination of the ignition and constant power from battery, but that would involve using the Pi’s GPIO ports and no solution I could think of would absolutely guarantee no parasitic battery drain, except complete isolation.
  • I liked the “smarts” of the PiJuice, essentially it was not just a battery but a battery that gave you hook points into the various states the battery could be in (charging, not charging, battery level etc.), and then allowing you to respond accordingly (there’s more to it than this, but this was enough)
  • The battery was large enough (in theory) to keep the Pi running for a while, particularly if I wanted to have it synchronize with my home network when in range and allow me to remotely do things on it. Plus, if I wanted to I could put a larger battery in.

A 2 channel amp to power the speakers, I was not looking for epic sound here, just to re purpose the existing front speakers for acceptable sound for music / podcasts / navigation. I went with a cheap one I had lying around, I think I picked up from AliExpress, labelled “500W” but actually more like 20w per channel if you’re lucky. Still, did the job.

A USB sound card, but only for the mic in part, not the audio out. I needed this for the hands free / speech to text of Android Auto. I originally thought the phone would act as the input but it doesn’t, the unit needs an audio in.

A ground loop isolator (RCA version) to eliminate the inevitable grounding issues.

A line level control (attenuator), with RCA in/out to allow externalized volume control. After stripping the plastic casing off this (so it would fit) I realized I paid a bit much for what was just a rotary switch with RCA cables attached, could’ve probably built this myself. And so we learn…

A lapel microphone to hook into the USB sound card, for audio in. Find something with a long enough cable so you can mount it somehow close to your head. Depending on how much background noise you have you may find it challenging using the voice commands.

An adapter radio wiring harness for my car. I had no intention of making this a wire splicing hack job into the car. I wanted to be able to plug into the existing radio harness and have it easily removable again. This was hard to find, I ended up finding a generic one for mounting a 3rd party radio to the car and modding it. The one I found was awesome because the wires were labelled (speakers, ground, constant power, ignition power), making the wiring to my unit easy.

Wire-in Adaptor 12V to 5V USB Micro/Mini for powering the PiJuice (and from that the Pi, DAC and screen). I thought of using one of the many buck converters I had but none of them were as neat as this solution was.

A type a male to female USB cable, needed this because the Android Auto implementation I used needed the phone wired into a USB port to work. It has a wireless option but I didn’t like it, hopefully it improves. Also, having an external USB port into the Pi is useful for future use (like dropping in a USB radio tuner should I get bored of the Android Auto)

A replacement fascia for my car that would expose a double din bay. As luck would have it AliExpress had one, once I could figure out what to search for, not knowing it was called a “fascia”.

A tactile switch, needed to externalize the override kill switch for the PiJuice outside of the dash internals. Important if everything is “hanging” and you’re not keen on the battery draining before it turns off.

I believe that was the entire parts list.

As for the assembly, once the radio had been removed and fascia swapped out:

  1. Soldered the external kill switch to the PiJuice on a rather long cable.
  2. Stacked the Pi, Pi Screen, PiJuice and DAC HAT’s together.
  3. Fitted the amp to the cage (it’s a small amp), connected the two USB cables (sound card for audio in and USB extension cable) and connected the lapel mic.
  4. Powered the PiScreen from the Pi, the Pi from the PiJuice, and the PiJuice from the car (via the 12v > 5v converter). The amp is powered directly from the car’s “ignition on” power.
  5. For the audio out: DAC > Volume Control > Ground Loop Isolator > Amp > Car (via harness)
  6. Fitted all of this into the cage as neat as I could (probably could be neater, maybe in version 2).
  7. Raised the screen exactly 1cm above the cage to be flush with the fascia.
  8. Ran the USB cable out the bottom of the dash allowing you to plug a phone in via cable.
  9. For the volume control and kill switch, drilled two tiny holes under the dash in an out of sight, but well within reach area, and mounted them there.

Bolted the cage back in and reassembled the car fascia and done.

More in the second post on the software (coming soon) …