Sunday, October 21, 2012

2011 MINI Cooper CarPC Build - DIYMA Car Audio Forum


Old 1 Day Ago ? #1
?

DIYMA Regular

Join Date: Mar 2011

Location: FL

Age: 30

Posts: 681

Thanks: 22

Thanked 71 Times in 49 Posts





This is my first CarPC build since 2003 or so. This project is unique in that the CarPC is designed to be a platform for my custom DSP development. I've been dis-satisfied with all of the commercial off-the-shelf DSP's out there, so I've decided to do everything myself. Here's a link to my build thread if you haven't read it yet, it may explain some of the insanity 2011 MINI Cooper S SQ build - HAT, JL, Alpine, Knu, SecondSkin, SDS, PWK

More on the software in a bit.

Here is the hardware that I decided to go with, for one reason or another:

Computer:

Apple Mac Mini, A1283, circa 2009. This used to be my HTPC back when I had a 100" projector.
Yep, a Mini in a MINI

Storage:

I'll be retrofitting the mechanical hdd with an SSD (solid-state drive), as my car is lowered, and the roads in Florida are crappy, and I wouldn't trust a mechanical hard drive as far as I could throw it. Flash-based drives are finally down to $1 per gig, for example this model, 128 gigs for $99, with VERY positive online reviews.


I topped out the RAM at 4GB, I'll need every byte I can get with the DSP stuff that I'll be doing

Power Supply:

The Carnetix P1900 was an easy choice, as it was designed around the Mac Mini, and is available with all the necessary cables (i.e. the MacPac).

The P1900 provides +19V to the Mac Mini, to replace the power brick, and a +12V output that will power my LCD screen. I opted for the add-on 15-watt +5V regulator, which can provide 5V power to whatever I might need it for...

PC Location:
So I can't really tell you where I'm mounting the PC, because it's a secret.

Don't tell anyone, it's going in the "Secret Compartment" If you're not a MINI owner, you wouldn't understand

Note: The pics above aren't from my car, they're from this thread on NorthAmericanMotoring. I've not started taking my dash apart yet. I'll probably start in the next few weeks..

Next up, the LCD display and user control system...


2011 MINI Cooper S :: [build log]
HAT L6SE, L3SE, L1 Pro R2. 4x Alpine SWR-843D, 2x JL XD700/5, 2x XD500/3, Mosconi 6to8
Neil_J is offline ? Reply With Quote
Old 1 Day Ago ? #3
?

DIYMA Regular

Join Date: Mar 2011

Location: FL

Age: 30

Posts: 681

Thanks: 22

Thanked 71 Times in 49 Posts





Most people that end up with a CarPC go the 7" 16:9 touchscreen route, usually with a 4- or 5-wire resistive touchscreen... Lilliput and Xenarc are the popular brands. I've been frequenting MP3car for the better part of a decade, and have lost count of the number of projects that used these screens... probably in the hundreds or thousands, easy.


(example of the "status quo" carPC, in the wild)

I wanted to go another route.
Why not ditch the touchscreen and go with a simple monochrome LCD and some knobs/buttons?
It is a MINI Cooper after all. No need to check e-mail and weather while driving...
I like to drive for the sake of driving... Minimalism at its best.

My idea was to interface a very simple monochrome 2x40 character LCD to an Arduino, along with a few knobs and buttons for volume, track select, etc. This would allow me to:
(A) keep the philosophy behind the car... motoring, not web surfing.
(B) avoid a lot of the common pitfalls that come with hacking up your dash and installing a non-transflective, 4-wire resistive touchscreen, with a non-standard resolution..
(C) keep costs down.

However, I finally decided to go with the LCD display for a very important reason that I'll explain in a later post. For now, I'll say that there's a very particular software app that I am in the process of developing that basically requires a TFT display... it's pretty awesome, and I can't wait to show it off

Here's the criteria that I used when selecting my display. Keep in mind that I've spent a good part of my career working with a team that designed glass cockpits for aircraft use. I'm very familiar with the technology and know what it takes to make a daylight-readable display.


The 7" LCD display market has pretty much stagnated since 2008. Nothing really new out there, with a few minor exceptions. Transflective and capacitive touch displays are finally readily available. Two sites that stock them: Mobile Computing Solutions - Innovations in Mini ITX and http://motorcitytech.com/.

I opted for the following display:


Motor City Technologies - Capacitive Multi Touch Lilliput 669 HB in Double DIN Frame
It's based on the Lilliput 7" High Brightness HDMI Monitor 669GL-70NP/C-H, and has been upgraded with a capacitive touch kit, that supports multi-touch (the jury is still out on Mac OSX support, we'll see). It's 450 nit LED backlit, and has been installed in a Bybyte Double DIN Frame. It has the Auto Switch mod for reverse camera option, and I'm pretty sure it has the auto-power-on option.. if not, no big deal, it's easy to mod.


Here's the monitor that the kit is based on (Lilliput 669GL-70NP/C-H).
This monitor is used a lot by the live-video Canon 5D / 7D guys. If there was a linear equation with "Cheap" and "Good", I think this LCD would hit the cross-point.


Here's the Double-DIN frame that the LCD comes installed in. It's from ByByte.com, another interesting CarPC niche company.

The display has been ordered, I'll report back here with results on how it performs in the bright Florida sun.

Next up: Software!


2011 MINI Cooper S :: [build log]
HAT L6SE, L3SE, L1 Pro R2. 4x Alpine SWR-843D, 2x JL XD700/5, 2x XD500/3, Mosconi 6to8
Neil_J is offline ? Reply With Quote
Old 1 Day Ago ? #7
?

DIYMA Regular

Join Date: Mar 2011

Location: FL

Age: 30

Posts: 681

Thanks: 22

Thanked 71 Times in 49 Posts





Earlier I mentioned that I've been completely fed up with the various car DSP's out there, both the vaporware ones, and the tried-and-true ones. Here's a quick rundown the features that I would require:
  • More than 8 channels. 10-12 would be nice.
  • Center channel extraction. I need the ability to run a separate center channel in my dash. This is NOT the same as simple "Left+Right"; I'm talking about TRUE center channel extraction here, which requires ACTIVE MATRIX decoding. Left+Right is only PASSIVE MATRIX, which only provides 3 dB of isolation.
  • Rear channel extraction and delay. Same as above. Left-minus-Right delayed 20ms is NOT what I'm looking for here. Active matrix decoding is required, and furthermore, I'd like to tweak the parameters to suit my needs.
  • Linear-phase FIR filters with VERY long taps. This requires a metric shit-ton of CPU processing power. Every single car DSP out there uses IIR filters (with the exception of maybe one), which I consider to be a compromise. I can do some incredible things with FIR filters, given the processor resources needed.
  • An auto-tune that works. More on this later.
  • Double-precision floating point math for the entire processing chain. That is, no integer-based DSP's, as MANY current car DSP's use integer-based math.
  • Ability to use a custom DAC. I'm currently drooling over the ES9018 Sabre DAC by ESS. Something like the Twisted Pear Buffalo III board.
  • The above requirement would allow me to run 8 channels at up to 32-bit, 384 kHz. Not that I have any music encoded at that rate... but might come in useful for something.
  • Ability to run full-digital from my collection of high-bitrate MP3 and FLAC files, through the DSP, right to the DAC. I don't see why I should go from digital-to-analog, to digital and then finally back to analog, as most folks do with their CD player.
  • Complete ability to tweak any/all settings. This clearly excludes the MS-8.

Out of the requirements above, the JBL MS-8 comes damn close. However the last requirement (ability to change/tweak any/all settings) is completely lacking. So it's out like the Monday trash.

On the topic of the center and surround-channel stuff:
Here's a quick rant on why I consider active matrix decoding so important.
(this was an IM that I sent to the lead manager of a car audio company's DSP project... needless to say, I got no response back )

Quote:

Extraction of a center channel requires more than simple L-R or other rudimentary math (ie not possible to implement with the PS8 mixer afiak). Here's a link to a paper that explains it pretty well:

http://decoy.iki.fi/dsound/ambisonic...source/sur.pdf

There are a number of reasons why I think this would be very beneficial for a DSP to support this feature:

- If you use a center channel, both front seats will sound the same and the image will be great for rear seat passengers too.
- Two-seat judging obviously becomes a lot easier for SQ events. More of a "slam dunk", really. More trophies for you guys to take home
- There are a lot of new cars that come with a center channel and side/rear channels (BMW et. al.). Not everyone is an SQ purist, i.e. not everyone would be okay simply disconnecting these channels. I find it hard to believe that the "rich guys" that walk into a shop and want "the works" done to their cars wouldn't want to keep all of their existing speaker locations.
- Seat position and angle become a lot less important for proper imaging. You get a lot more than a simple "sweet spot".. Theaters have known this for years and years now.
- For center channels that with tweeters that go up to 20 kHz, it seriously improves one's chances at getting the center to image properly; I've found it's extremely difficult to match the left and right tweeter to get a proper center image; there's a thread on Diyma I can pull up where Patrick Bateman was experimenting, and found found this out, even linked to some research papers that backed it up with numbers. Again, once this tweaking is done with a two-channel system, it sounds like crap for the other passenger, i.e. a compromise).
- Small cars, like my Mini, are IMO a lot harder to nail with two-channel systems, due to extreme differences in path lengths. There are a lot of people buying small cars these days, which IMO makes nailing T/A and Eq that much harder. Adding a center channel and proper matrix decoding is a very easy solution.
- There are no other processors out there, except for the MS-8 (via L7 active matrix decoding, which is proprietary to Harmann/JBL), that do center and rear fill properly, and everyone knows the MS-8 is a half-polished turd.
- Proper rear-fill (delayed ~20 ms to overcome HAAS effect, and phase-steered and Eq'd) can add to stage "width", although SQ purists would consider this cheating. I've played with this in my car, and absolutely love it.
- Properly mic'd and mixed SQ CD's sound absolutely great with the matrix surround decoding. I run my home system this way, it sounds fantastic, I can give a list of tracks to demonstrate if needed.
- There have been PLENTY of SQ competitors in both IASCA and MECA that have used center channels and proper rear-fill over the years, even if they're completely secret and haven't told anyone... And they've taken trophies for them.


As I've said in other threads, I'm sort of in the vocal minority here, because most SQ purists don't believe the stuff above, and frankly are content with what they have. Well I don't listen to CD's. I frankly don't know how any self-respecting audiophile would (dons flamesuit). I absolutely love what Dolby Pro Logic II and Harman/Lexicon Logic7 can do to the listening experience in my car. So there's not really a market for what I'm proposing above. I understand that, and am actually kind of excited that I get to try to write a DSP myself... they're certainly challenging, so it should be interesting to say the least.

So, here's a quick outline of the method that I will use to implement my own DSP.

First and foremost, I will be writing 98% of the DSP code and user interface with National Instruments Labview.

My reasons for using Labview are as follows:

  • It's what I use at work. I'm very, very proficient at it.
  • It's perfect for designing complex applications with tons of input, processing, and output.
  • It's perfect for Rapid Application Development. In english, this means you can use it to get shit done
  • It comes with a very complete set of mathematical and scientific functions (filters, FFT's, etc). This means you're buying a loaded Matco toolbox, rather than a swiss-army knife.
  • I already own a college edition, and this DSP project will be for purely educational purposes.
  • It includes an excellent library of user interface objects, including XY graphs, plots, buttons, and sliders.
  • Although not truly "Real-Time", Labview is fast enough to keep up with audio DSP stuff. There's even a free set of courses at cnx.org (Rice University) that teaches DSP music synthesis using Labview.
  • Programming is graphical and does not involve writing code and dealing with syntax. This improves readability, and speeds up the coding process considerably.


Propaganda shot from National Instruments, showing the "Power of Labview"


Picture of the Labview block diagram pallette

Here's a list of functions that my DSP will support:

  • Time alignment for each channel. Time resolution will be the reciprocal of the sampling frequency, just as it is for all other DSP's.
  • Linear-phase FIR filters with very long taps... As opposed to IIR filters used by 99% of the DSP's out there. This goes for both crossovers, and equalization, and gives me the utmost flexibility. I'm perfectly able to use IIR or other filter types if I do so choose.. but FIR is the current plan. This should also allow me to change crossovers and equalization without having to re-do TA.
  • Full support to graph out impulse responses, step response, etc from any of the DSP building blocks. Being able to see the filters
  • Full surround sound processing as mentioned above, similar to Dolby Pro Logic II and/or Harmann/Lexicon Logic7. I've basically read the patents, and will be implementing my own algorithm in real-time, which processes the incoming 2-channel data into 5.1 channels (left, right, center, rear-left, rear-right, and subwoofer). I will be writing another thread on this topic at a later date, the patents contain some very cool stuff.
  • I will use FFMPEG and/or other libraries to decode the FLAC and high-bitrate MP3's, and convert them to a two-channel array in memory that will get sent to the DSP algoritihms.
  • I plan on using a CD extraction library, similar to what CD ripping utilities and ExactAudioCopy do, for the times that I must use a CD... like for IASCA and MECA events. The bits will stay in the digital domain from the time they're read by the laser, to the time they're converted and sent to the amplifiers.
  • Once the DSP numbers have been crunched, the floating-point arrays are quantized and output directly to the sound system using a Labview library function.

And another feature that I'm very proud of... The ability to do RTA and log sweep FFT's similar to HolmImpulse and others... all from the CarPC, in Labview. I've already got this code up and running, and it's a lot easier to use than TrueRTA, and it actually works in Mac OSX, no need to boot into Windows. I'll post some screenshots at a later date, when the bugs have been fully ironed out.

Most of my time over the last few weeks has been spent reading various DSP and filter books... Here are two that I liked at lot, as they are both written quite well, and are straight to the point:

Next post will be about the multi-channel DAC that I will be building. Will hopefully get around to that tomorrow.


2011 MINI Cooper S :: [build log]
HAT L6SE, L3SE, L1 Pro R2. 4x Alpine SWR-843D, 2x JL XD700/5, 2x XD500/3, Mosconi 6to8


Last edited by Neil_J; 7 Hours Ago at 06:30 PM.. Reason: added links to awesome books

Neil_J is offline ? Reply With Quote
The Following 2 Users Say Thank You to Neil_J For This Useful Post:
Old 1 Day Ago ? #11
?

DIYMA freshman

Join Date: Jul 2005

Location: SF Bay Area

Age: 25

Posts: 165

Thanks: 11

Thanked 4 Times in 4 Posts





Definitely sub'ed to this one.
Attention to detail so far is awesome.


-Ray

2011 Tundra AudioControl | Connection | Fountek | Helix | Mobile ES | Vifa
1998 S-10 Kenwood | Arc Audio | Aura | Rockford Fosgate

takeabao is offline ? Reply With Quote
The Following 2 Users Say Thank You to thehatedguy For This Useful Post:
Old 19 Hours Ago ? #14
?

DIYMA Regular

Join Date: Mar 2011

Location: FL

Age: 30

Posts: 681

Thanks: 22

Thanked 71 Times in 49 Posts





Quote:

I wish I knew more about this sort of thing. I'll be reading it but not understanding
half of what you have going on. What is cool to me is the amount of eq, xover, and
TA you get out of these things. Prolly the only thing I would ever replace my XES
with.

In my limited experience, the amount of Eq, TA, and such that is needed totally depends on the car. Large cars have more equal path-lengths, for example, you can mount in the kicks. You cannot mount kicks in a MINI, there's no room. You end up with really crazy reflections and weird standing waves in the bass frequencies due to the small dimensions. You're more "near-field" than you would be in a large car, as you're even closer to the reflective surfaces.

So TL;DR is, Equalization and other DSP is not a panacea as many have said... but it might level the playing field in some cars, like mine.

This project is also one of those "what if" kind of things as well, just another challenging project to flex the brain muscles. The state college system is f*cked here, I consider the DIY approach a MUCH better way to learn. It's definitely more hands-on.


2011 MINI Cooper S :: [build log]
HAT L6SE, L3SE, L1 Pro R2. 4x Alpine SWR-843D, 2x JL XD700/5, 2x XD500/3, Mosconi 6to8
Neil_J is offline ? Reply With Quote
Old 18 Hours Ago ? #15
?

DIYMA Regular

Join Date: Mar 2011

Location: FL

Age: 30

Posts: 681

Thanks: 22

Thanked 71 Times in 49 Posts






2011 MINI Cooper S :: [build log]
HAT L6SE, L3SE, L1 Pro R2. 4x Alpine SWR-843D, 2x JL XD700/5, 2x XD500/3, Mosconi 6to8
Neil_J is offline ? Reply With Quote
Old 18 Hours Ago ? #16
?

DIYMA Enthusiast

Join Date: Oct 2008

Location: Flushing, MI

Posts: 1,820

12V Company:
Car Tunes Stereo Center

Position:
Installation Manager

Thanks: 3

Thanked 26 Times in 22 Posts





Wow. I got to your description of the functions you plan to implement and immediately felt like 5 year old trying to do Calculus. You are taking this to a ridiculous level (in a good way.) I can't wait to see where this goes.

I quit programming (BASIC and Assembly on my old Color Computer 3) when my dad bought a PC back in the late 80's. Makes me wish I'd stuck with it.

As much as I love car audio and want to have an exceptional car stereo system, I can't see putting that much effort into it. It doesn't seem like it would over come all of the car-related problems (engine noise, road noise, PLD's, etc) to make it worth while (to me).

If I ever end up back down in FL for any length of time, maybe you can prove me wrong. LOL

Can't wait to see more.

Jay


Quote:

Originally Posted by nadams5755

weeeer wub wub wub weeer wub wub wub waaa

JayinMI is offline ? Reply With Quote
Old 16 Hours Ago ? #17
?

DIYMA Regular

Join Date: Mar 2011

Location: FL

Age: 30

Posts: 681

Thanks: 22

Thanked 71 Times in 49 Posts





Here's a picture of the stock dash in a 2011 MINI Cooper (not my car), just a random internet pic:

Notice how the radio is built into the speedo. FREAKING GENIUS guys This is one of the many reasons why working on MINI's are so challenging. The BMW engineering team certainly had their heads up their collective asses on that one.

So what do us "DIY" guys do when we want an aftermarket radio?? Well, most use the Metra kit for the '08 thru '12 MINI Coopers that allows the installation of a Double-DIN radio:

Take notice of the little piece on the lower-right. That's a "black-out" plate that goes where the speedo LCD and knobs used to be. Great... Now my brand new car looks like this:


(yes, that's actually my car, it's dirty and I've got a lot of work to do).

Notice the Metra "Black Out" panel in the speedo area where the radio controls and display used to be. Yuck.

Here's what I'm going to do to rectify this situation.

  • Take apart the "stock" display and controls that reside in the speedo housing
  • Take apart the "stock" single-DIN radio that resides in the center lower console
  • Try to reverse-engineer the knobs and buttons
  • Try to source an alternate LCD display to replace the existing one (VERY unlikely that I could reverse-engineer the protocol of the existing one).
  • Use an Arduino to interface the LCD and the buttons/knobs to the Carputer.
  • Write some software in Labview that talks to the Arduino via the USB-to-serial bridge. This will allow the CarPC to send text to the display, and read the buttons.
  • While I'm at it, use four extra pins on the Arduino to interface the steering wheel radio buttons: Vol Up, Vol Down, Track Left, and Track Right.
So I ripped apart the stock pieces, here's what I came up with:

The existing LCD is a graphic monochrome type amber-on-black. Hard to reverse engineer... hard to source a replacement.. Hard to program even if I had a spec sheet. Instead, I went with a 40x2 character LCD, the type like you'd see on any niche-based product that didn't have the money to source a "real" LCD..
Here's a picture of a similar LCD to the one I ordered:

The actual LCD that I ordered was from Futurlec, it's red-on-black, but otherwise perfect. Simple parallel TTL interface that I can easily interface to an Arduino. I will likely replace the red LED backlight with an orange-amber to completely match the rest of my interior.
REDLCD40X2BL - 40 x 2 Red on Black Character LCD Display with Backlight

For anyone that doesn't know what an Arduino is, it's the latest boner in the DIY microprocessor scene.

It easily allows average Joe's like me to interface digital inputs and outputs to a computer, and much more. I've already got four Arduino's in the MINI Cooper already, in my amp rack.. check out my build log for more info.

So as complicated as all this stuff is, this will allow me to keep the "stock" look and functionality of my interior. This will make it very easy for IASCA and MECA judges to operate the controls, and will hopefully award some points on the install (getting "all" of the points would be nice too, with the amount of work I'm doing!). Having a monochrome LCD up in the speedo is nice, since it's more readable in daylight, and provides more of a "Heads Up" than the TFT display would be. As I've said before, I'm a knobs-and-buttons kind of guy. Changing the volume on a touchscreen is a pain-in-the-ass. There's simply no way that I could do this build with just the touchscreen controls.

When I'm able to reverse-engineer the buttons and knobs, I'll post that info here.


2011 MINI Cooper S :: [build log]
HAT L6SE, L3SE, L1 Pro R2. 4x Alpine SWR-843D, 2x JL XD700/5, 2x XD500/3, Mosconi 6to8
Neil_J is offline ? Reply With Quote
The Following User Says Thank You to bikinpunk For This Useful Post:
Old 12 Hours Ago ? #21
?

DIYMA Regular

Join Date: Mar 2011

Location: FL

Age: 30

Posts: 681

Thanks: 22

Thanked 71 Times in 49 Posts





Well don't worry.
I am not substituting electronics and DSP algorithms for good acoustics.
My DSP is just ONE TINY PIECE in the whole project... It was never intended to cure cancer and end wars.

I've talked a lot about this in other threads. I agree with most of what you're saying. In a car, being near-field, the reflections will totally screw phase up. I realize that using linear-phase FIR filters will not "fix" the phasing problems that come from a reflective environment. However, I agree with Patrick Bateman, and others, that there is a certain threshold where phase can be heard (there's a chart floating around the internets somewhere). This has been talked about in other threads, I don't want to go in depth about it here. There are other benefits that come with FIR filters, I may go more in depth when I can. FIR filters do not have to be linear phase, but it just so happens that most of the filter types happen to use linear phase, because they can

As for the comment of the MS-8... I know that it gave me a crappy tune because i used my ears. Once I got the Mosconi 6to8 installed, I was able to tweak it to my heart's desire and get a good tune. Now I'm having some fun and learning some stuff, and I'll have a cool DSP to show for it. Don't get me wrong. The MS-8 is great if your expectations aren't high. But you can't exactly walk into IASCA and/or MECA and walk away with trophies with it.

And FWIW, I will be re-locating my mids to be closer to my tweeters, in December. And will be adding various acoustic treatments to my car in the coming months. Lots of work left to do...


2011 MINI Cooper S :: [build log]
HAT L6SE, L3SE, L1 Pro R2. 4x Alpine SWR-843D, 2x JL XD700/5, 2x XD500/3, Mosconi 6to8
Neil_J is offline ? Reply With Quote
Old 11 Hours Ago ? #25
?

DIYMA Addict

Join Date: Dec 2005

Location: ..........................................

Posts: 6,152

Thanks: 105

Thanked 82 Times in 70 Posts





Quote:

I wanted to go another route.
Why not ditch the touchscreen and go with a simple monochrome LCD and some knobs/buttons?

Heh, I did this on several builds around 2000-2002. WinAmp, I remember, had some parallel and serial interface plugins that made input pretty easy, and a lot of players/front ends support multisegment displays. I have a pic somewhere...

Anyway, I haven't read this thread in detail yet, but I look forward to see how you plan on implementing the DSP! I tried the same thing in Simulink, but had a lot of issues with lag, CPU usage, and artifacts (I use it in 2ch mode for other sig proc. applications without much problem, but like you, I need 8+ channels of processing). This is why I went to VST, but that's a tough deal on a Mac. However, there are some linux VST hosts that I see around (Jack?) that might work on OS X, and there are a lot of good plugins that have Mac versions (Voxengo's suite, for example).

Edit: [the Voxengo crossover/EQ I use is FIR too, I believe, which would work for your app...]

&#

Source: http://www.diymobileaudio.com/forum/car-pc-forum/138206-2011-mini-cooper-carpc-build.html

ghost rider spirit of vengeance hornets prince johan friso windows 8 logo anguilla gone with the wind michael jordan

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.