Skip to content

DIY VVVF Inverter

Okay, so now that I had the power electronics sorted out, it was time to create the PCB that would drive the board and control the timings for switching.

Truthfully, I'm more of a software person than hardware, so this was well outside of my area of expertise.

Regardless, I forged ahead by installing KiCad, an open-source PCB design/layout tool.

I'm going to skip over much of the design process here, because it's been a few years as I write this since when I actually did this and I therefore don't remember much of what I did and why, however I'll still go through the schematic below.

Note

All design files for the hardware will be available for download at the bottom of this page - I love open source and hope you can make something cool with them!

Schematic

I wanted to break my design into two boards, since I didn't have that much space to work with. This lead me to start by making the connectors that mated the boards together, so I could plan around this split-board design.

Eventually, this wound up looking like this:

Image

The lower board supplies power and is where the fans are connected, while the upper board will handle gate drive, and have the arduino that controls the whole system.

To start, let's look at the bottom board.

Image

This is a very simple design, it just consists of a bunch of power supply modules on the bottom board, and a connection to the main rectifier to power them all.

I then added some indicator LEDs to ensure all the power rails are good, and then that's about it. The fans are then connected to the 12V power rails, and signal lines (like tach and pwm) are passed up to the arduino.

Okay, let's move on to the top board, where it gets a bit more complicated.

Image

So, in this top board there's quite a bit more going on. Firstly, there's the arduino mega shield - I wanted to use the beefiest arduino they had in case I needed to have more hardware timers, since the Arduino Mega is capable of more hardware timers than the Arduino Uno. Luckily for me, KiCad came with an arduino shield out-of-the-box, which was fantastic. I just had to plop down a shield footprint and that was that.

There was one caveat - the shield meant the arduino would be upside down, and as such, the reset button is not accessible. Therefore I placed an extra button wired to the reset lines so the arduino can be reset without having to power it off and on again.

I also added two LEDs for status indication, but I never got around to writing the code to do anything with them.

Next, I placed a connector for a OneWire temp sense, which I would mount on the heatsink. This should allow for dynamic fan speed control according to the temperature of the heatsink so they're not cranked at 100% speed constantly.

There is also a connector for a motor speed sensor, which I again never used, but would theoretically allow the arduino to check if the motor is actually spinning at the speed that is desired. If it's not, then it would stop powering the motor as something probably isn't going right.

Lastly, there's the inverter gate drive, and this is of course the complex bit. Let's dive into that part more.

Image

Okay, so there's a bit going on here - and truthfully this section still has some issues. For example, I believe that I undersized the gate drivers for the IGBTs that I have since it takes a while for those IGBTs to turn on - and the gate drivers get pretty warm when switching.

Anyway, I wound up finding an IC that does the actual hard parts of gate drive - so the three repeated sections on the right of the image are for the three phases: U, V, and W. Most of the components in those sections are also just there to support those chips, and are from the reference design.

On the left, we have a the logic controller, which takes the arduino's phase signals and creates an inverted copy, so that it is never possible to have both high-side and low-side IGBTs on at the same time. For obvious reasons that would be really bad.

Image

This was just done with an op-amp, really nothing special here. It is worth noting that I was careful in adding pull-down / pull-up resistors basically everywhere because you really don't want the IGBTs turning on/off unexpectedly. So if the arduino boots up after power is applied, you want all the power transistors to default to being off.

Additionally, the resistor and diode pairs on the right are to make the high-side transistor turn on a bit more slowly than it turns off. This is to make sure the low side is totally off prior to the high-side turning on.

That just about covers the schematic - let's dive into the layout.

Layout

Okay, so since I was doing a split board design, there are obviously two boards, a top and bottom one. If you recall from earlier, the bottom board handled power delivery and the top board is responsible for control and gate drive.

That lead to this layout.

Image

The power board is mostly just taken up by power supply modules, so there's really not a lot of room for anything.

On the right is the interesting parts - the gate driver. There's loads of stuff going on here, towards the top is the arduino shield, and below that is the hardware high-low side inverter. Underneath that is the gate drive stages, one for each phase. At the bottom are the connectors for each gate on each IGBT.

That's just about it for this page, so in the next section, I'll show what this looks like all assembled and installed, and show it working (and discuss some mishaps.)

Data

In case you want to download the KiCad files, here's where you can do so.

File Description
Schematic / PCB Layout Tarball of the KiCad project files