I bought a Hyundai Kona EV (electric vehicle) back in February. It came equipped with what Hyundai calls a virtual engine sound system (VESS). It makes an cartoon spaceship sound at low speed to alert pedestrians. It’s pretty annoying, so I immediately unplugged it, but it gave me an idea. I wanted to make the car sound like a locomotive instead. I tapped into the appropriate CAN bus and spent a good deal of time mapping the various messages.
Eventually, I yanked the VESS to work out how to operate it on the bench. Here’s a little video of that effort:
I figured the easiest way to generate the locomotive soundtrack would be to use an off-the-shelf sound module and build a CAN to DCC converter. I chose the Phoenix P8 because of its single-ended logic level DCC input.
I first tried using a basic Arduino to do the conversation, but it was nowhere near fast enough. I moved to a Teensy 3.6, which has CAN built in, and it is plenty fast.
Here’s the setup. It’s just the Teensy, the P8, and a buck converter to power the Teensy. The red and black wires are spliced into the CAN bus in the car.
Today, I got everything into the car to test it out on the road, and it works really well. Very smooth.
Right now, the DCC speed packets are generated from the vehicle speed data. However, I will experiment with using the actual power going to the motor instead, as this should correlate better with the load on the prime mover. I can also tie the regenerative braking in the car to the dynamic brake sound. I also plan to have manual triggers for the bell and horn. And of course I can load any Phoenix file into it to experiment with other locomotives.
The Teensy has a lot more horsepower than the P8, and I have an audio module for it. Eventually, I’d like to have it generate the sound itself, but this was a good first step.