# High power 100 kW+ SiC inverter



## Tony Bogs (Apr 12, 2014)

Recently high power silicon carbide mosfet modules have become available.
The advantages are obvious. Higher frequency (no audible noise), better efficiency (smaller battery pack), no need for liquid cooling (weight saving) and lower overall cost.
The only disadvantage I've come across so far are gate voltages that differ from IGBT.
But that's an easy fix (simple voltage converter).

Overdimensioning an IPM power stage as a protection measure might work for low power (test) puposes.
For higher output power levels a more advanced protection mechanism is needed.

Desaturation detection is as far as I know the only reliable method for on-state overload protection of IPMs that are used near the load limits.

Here are links to Avago (formerly HP) desat optocoupler driver technical documents:
http://www.avagotech.com/docs/AV02-0803EN
Broadcom Inc. | Connecting Everything

The layout for a printed circuit board for the SiC gate drive circuit is attached. First layout for testing purposes.
The circuit diagrams and final pcb layouts will follow when the testing is done.

Components have been selected for high reliabilty and a temperature range of -40 °C to 85 °C as a minimum requirement. Automotive grade if available. 

And should be OK for DIY. No super tiny SMT. Smallest spacing about 1/40” (0,6 mm). Solderable with a 0,3/0,4 mm tip, a steady hand and maybe a common magnifying glass.

UPDATE (2020). DELETED IMAGE: CASCODE SiC JFETS will be used when the build starts. Eight microseconds short circuit rated.
MICROCONTROLLER UPDATE: Automotive grade ATMEL D51, great development tools, E version of the ARM based chip has CAN. Suitable for FOC.


----------



## Tesseract (Sep 27, 2008)

Your post is, unfortunately, one of those that can't be quoted (I bet you can't edit it, either), so I copied the relevant portion of text I want to respond to and will generically quote it.



> ...The advantages [of SiC modules] are obvious. Higher frequency (no audible noise), better efficiency (smaller battery pack), no need for liquid cooling (weight saving) and lower overall cost.


Higher frequency is not necessarily an advantage in motor drives. The lamination thickness of the armature is invariably determined by the "rotational" frequency it operates at, which is far lower than the PWM frequency. However, iron losses in the armature are definitely proportional to both armature (ie - rotational) frequency *and* PWM frequency. So, you really want to use the lowest PWM frequency possible to maximize motor efficiency.

Note that "armature" refers to the part of a motor that experiences alternating flux swings; this is usually the "stator" of an AC motor and the "rotor" of a DC motor.

As for efficiency, SiC is a so-called "wide bandgap" semiconductor and so it has a higher blocking voltage for a given conductivity, but it is still a strictly "majority carrier" device and therefore will always have higher conduction loss than a bipolar device of the same voltage/current rating (ie - IGBT). There are only two advantages to SiC MOSFETs and only one of those is relevant to motor drives: 1) they can switch at a much higher frequency as a result of not having to suffer minority carrier recombination; 2) they can tolerate a higher operating temperature (approximately 150C continuous, versus 100C for conventional Si MOSFETs and IGBTs).



> Desaturation detection is as far as I know the only reliable method for on-state overload protection of IPMs that are used near the load limits.


Desaturation is a unique phenomenon of bipolar devices like IGBTs and does not apply to unipolar devices like MOSFETs. Without getting too bogged down in technical details that will just make the eyes of most people here glaze over, the voltage drop across a MOSFET is linear with current (though exponentially proportional to temperature; roughly to the 1.6 power) while the voltage drop across a bipolar device like an IGBT is relatively constant except for an ohmic loss which is linearly proportional to current (just like a MOSFET) and a diode-like increase of 60mV/decade of current up until the current is so high that there are insufficient charge carriers available. It is at this point that the voltage drop abruptly increases (e.g., from 1.5V to 6V or more) and the bipolar device is then said to have come out of saturation (ie - it has desaturated).

Long story short, you can't use a typical "desaturation protection" circuit with SiC MOSFETs; rather, overcurrent protection will have to depend on high speed "cycle by cycle" limiting.


----------



## Sonikaccord (Dec 17, 2012)

SiC has much higher thermal conductivity than Si and is less temperature sensitive which is a big plus in an EV.

WBG transistors would allow the magnetics for a boost converter to shrink to allow for smaller packaging.

Easy to parallel since they are more or less self regulating.

Less turn on/off losses

Easier to make a pure/very low THD sine wave motor inverter because of higher switching frequency. (Smaller filter) And output is spike free. This also improves motor efficiency

I've been reading more about GaN than SiC but I believe they share similar characteristics.


----------



## Tony Bogs (Apr 12, 2014)

Desaturation is a term that is used for bipolar devices. when the so called linear region is entered. The voltage increases rapidly with increasing current. At high loads it leads to device destruction (overheating). That's the key property. Mosfets show a similar behaviour. I'll keep using the term desaturation because that is what manufacturers still use in datasheets and white papers.

Iron losses: if the flux variations are kept low, the loss increase due to a higher PWM frequency should not be substantial. 

Conduction losses: those losses are about the same, but switching losses are much, much lower.


----------



## Tony Bogs (Apr 12, 2014)

The PCB is ready and the first test is done. The results confirm that the Avago ACPL-332J can be used as the primary desat driver. 

Driver board Q&A: 

Q: What is the maximum repetitive peak working isolation voltage?
A: The ACPL-332J optocoupler's isolation voltage specification is 891V peak. 

Q: How many SiC devices can be driven by one board?
A: Two Cree CAS300M SiC mosfets can be driven in parallel. 

Q: The Cree CAS300M SiC needs a very low gate resistor for the highest efficiency. Can the board handle the high peak currents?
A: Yes. Each mosfet has its own IXYS IXD*609* high current driver ic. 

Q: How is the IXYS driver turned off when the SiCmosfet desaturates? 
A: An IXYS IXDD driver ic has an enable input. A signal from the 332J optocoupler drives a transistor that pullls the enable input low. 

Q: Can the fast switching of SiC mosfets cause interference on the board?
A: The board is shielded. The optocoupler and other isolation circuits have been designed for inverter application. 
The CMR value is closer to 10kV per microsecond than the usual design goal of 5kV per microsecond for inverters.


----------



## Sonikaccord (Dec 17, 2012)

Tony Bogs said:


> Desaturation is a term that is used for bipolar devices. when the so called linear region is entered. The voltage increases rapidly with increasing current. At high loads it leads to device destruction (overheating). That's the key property. Mosfets show a similar behaviour. I'll keep using the term desaturation because that is what manufacturers still use in datasheets and white papers.
> 
> Iron losses: if the flux variations are kept low, the loss increase due to a higher PWM frequency should not be substantial.
> 
> Conduction losses: those losses are about the same, but switching losses are much, much lower.


According to the datasheet for this device, CAS300M12BM2, there is no "linear" or "desaturation" region so you don't need desaturation detection. The current applied is almost linearly proportional to the voltage drop across S-D (Ron) That would simplify driver design as all you would need is a way to measure current. Pretty much what Tesseract said. 

Why such an overkill device though? I don't see any EVs over about 3-400V. You can sacrifice some of that blocking capability for higher current capacity and a much less expensive device...


----------



## Tony Bogs (Apr 12, 2014)

There's a linear region allright for the CAS300M12 in the on state. For every mosfet.

As soon as the drain current of the mosfet exceeds a certain level the mosfet no longer acts like a resistor but as a (gate) voltage controlled current source. 

The desat is a extremely fast protection mechanism (few microseconds) that no current measurement system can match. It needs to be that fast for short circuits and low gate voltages. In general: fault conditions.

Why expensive SiC? I'm not buying them now. The price has to drop first. 
For instance size. Phase output filters are much bulkier for cheaper devices and so is the cooling.


----------



## Sonikaccord (Dec 17, 2012)

How much current are you running through the device? The Cree's graph tops out at 600A. With a decent driver, it looks like it can tolerate the rated current plus a few current spikes here and there. Then again, it doesn't take much to fry a FET.



I guess I'm thinking the cycle-by-cycle current limiting should throw a red flag once a certain threshold is passed. Or am I missing something there?



I was still speaking of the WBG semiconductor as I love the potential, but more so some of the other devices on the market.


----------



## Tony Bogs (Apr 12, 2014)

It's much easier to fry an IGBT. Latch up. I've even used avalanche rated MOSFETS as a IGBT turn off protection in a design. 

But glad you asked. Desaturation detection protects against FAULT conditions in the on state. At high loads. 
Basically two cases: overcurrent (short circuit) and faulty gate drive voltages (low). When rapid intervention is a must. 

The nominal current load for the CAS300 is 300A. But it takes quite a bit of math to calculate the maximum current for a specific application.

Technical background: The linear region starts above 600A. Up to 1500A (device maximum). 
During a fault condition it's power (heat) that destroys the mosfet. But the thermal properties of the CAS300 are impressive.
A dynamic junction to case thermal resistance of about 0.0002 K/W for a single pulse event. 
That means the CAS300 can take more than 200kW heat. But only for a very short time. In the microsecond region.


----------



## Tesseract (Sep 27, 2008)

Tony Bogs said:


> There's a linear region allright for the CAS300M12 in the on state. For every mosfet.


Correct. MOSFETs - including SiC types - act like a resistor with some temperature dependence when fully turned on.



Tony Bogs said:


> As soon as the drain current of the mosfet exceeds a certain level the mosfet no longer acts like a resistor but as a (gate) voltage controlled current source.


Incorrect. You are describing how a bipolar device - such as an IGBT - behaves. The voltage drop across the collector-emitter junction of a bipolar device is almost linear with gate/base voltage once the gate/base voltage is brought above conduction threshold [and then the CE drop increases approx. 60mV per decade of current, just like a BJT, plus a minor contribution from Ohmic losses]. In contrast, the drain-source resistance in a standard Si MOSFET might halve when going from 5V to 10V, and change not at all when going from 10V to 15V. SiC MOSFETs tend to require a higher voltage to fully turn on (20V vs. 10V for a standard MOSFET), and thus have a somewhat wider "square law Ohmic region" above the threshold voltage, but otherwise behave the same.

There is such thing as a SiC BJT (and JFET), but I haven't personally used either. 



Tony Bogs said:


> The desat is a extremely fast protection mechanism (few microseconds) that no current measurement system can match. It needs to be that fast for short circuits and low gate voltages. In general: fault conditions.


Desaturation occurs much faster than a "few microseconds"; more like a few nanoseconds depending on the die size. Usually bipolar devices are rated to withstand desaturation for 6-10us, however, which might be what you are referring to. Nevertheless, it is entirely possible to make a current limiting circuit that reacts nearly as quickly as desaturation; the problem is that a majority carrier device does not limit short-circuit current whereas a bipolar device in desaturation does. In other words, bipolar devices will protect themselves to some extent during a short. It's one of the primary reasons they are more rugged than unipolar (majority carrier only) devices.



Tony Bogs said:


> Why expensive SiC? I'm not buying them now. The price has to drop first.
> For instance size. Phase output filters are much bulkier for cheaper devices and so is the cooling.


"Phase output filters" are rarely used on motor drives, and only then when the cables between the inverter and motor are longer than 10's of meters. Occasionally there is a light "dV/dt" output filter and/or a common mode choke around all three phase cables, but those are not really for integrating the PWM'ed output voltage waveform into more of a sine wave; just for softening the switching transitions.


----------



## Sonikaccord (Dec 17, 2012)

Fault protection from over current situations and gate drive errors can be observed by a microcontroller.



Would a sine wave drive really increase motor efficiency? Or is that just marketing talk?


----------



## Tony Bogs (Apr 12, 2014)

> Posted by Tesseract:
> 
> Quote:
> Originally Posted by *Tony Bogs*
> ...


Maybe you're more experienced with conventional (non punch through, very light punch through) IGBTs with 10 microsecond short circuit ratings than fast punch through types and mosfets. 

I've mostly used mosfets for designs. 
Mosfets can definitely enter linear mode in the on state. 
In fact, the Cree CAS300 has a very constant transconductance over working temperature: gfs=94. 
Drain current = gfs * gate voltage. 
Clarification: this formula sets the threshold current value. Below it the SiC mosfet acts like a resistor, above it as a gate voltage controlled current source. 
Probably not a good (drain-source voltage independant) current source, but who cares? It is a fault condition in inverters. 

Desaturation protection: common practice for fast IGBT (punch through) and mosfets. 
If I remember correctly, Cree supplies a gate driver with desat protection for the CAS300. And IXYS drive ics. Sold seperately.

Phase filters /pure sine input:
The main reason for using filters is EMI/RFI. Keeps the major part of the high frequency components in the shielded inverter housing.
And (less important):
The motor will have less iron losses. But the filter adds losses.


----------



## Tony Bogs (Apr 12, 2014)

I've compared the 300A Cree CAS300 with a “reference design” for a 300V DC bus Siemens Azure motor that uses fast IXYS PT IGBTs. The motor is well known on this site. Maximum phase peak current 225A at nominal power, 450A at short period peak power. 

One CAS300 outperforms two 200A PT IGBTs on the switching losses. 
Numbers at peak power (450A), based on extrapolation of datasheet information:
Cree @20 kHz 80W
Two IGBTs @16kHz in parallel 540W 

But since the SiC is used above the nominal current rating (450 to 300) the conductance losses are higher. About 300W. Net result 540 – 380 = 160 W. Per mosfet. 
So in total for a full inverter about 1kW loss saving at max peak power.


----------



## Tesseract (Sep 27, 2008)

Tony Bogs said:


> ...Mosfets can definitely enter linear mode in the on state.
> In fact, the Cree CAS300 has a very constant transconductance over working temperature: gfs=94.
> Drain current = gfs * gate voltage.
> Clarification: this formula sets the threshold current value. Below it the SiC mosfet acts like a resistor, above it as a gate voltage controlled current source.
> Probably not a good (drain-source voltage independant) current source, but who cares? It is a fault condition in inverters.


I was mostly objecting to you calling the behavior of any kind of MOSFET experiencing overcurrent as "desaturation", as that is something that can only occur in bipolar devices. 

That said, I actually looked at the datasheet for this module and it does seem that because of the relatively low transconductance you could, indeed, use a standard IGBT drive circuit with desaturation type overcurrent protection, so any argument over proper nomenclature is academic at best. The maximum fault current through a CAS300M12BM2 module with 20V of gate drive will be around 1900A and with 15V of drive (ie - the standard for IGBTs) it will limit to around 1400A, which it can take for 200us, at least. That's pretty impressive, actually.

The switching energy specs are also impressive, but I would still limit switching frequency to the 12-16kHz range.

And one other note, the Cree gate driver uses an isolation IC from Infineon that is often in short supply (1ED020I12-F2).


----------



## Tony Bogs (Apr 12, 2014)

Ah, what's in a name? 



> Originally posted by *Sonikaccord*:
> Fault protection from over current situations and gate drive errors can be observed by a microcontroller.


Correct. 
The driver board drives two optocouplers to signal undervoltage and desaturation FAULTs to the the microcontroller. 



> Originally posted by *Sonikaccord*:
> Would a sine wave drive really increase motor efficiency?


Absolutely true. High frequencies cause added iron core losses, eddy current losses and skin effect losses. They also cause extra wear on ball bearings and stress on the wire insulation unless precautions are taken.


----------



## Tony Bogs (Apr 12, 2014)

*PWM frequency and sine filter*

Here's a link to a comprehensive inverter output filter design guide:
www.danfoss.com/NR/rdonlyres/27F81E71-3779-4406-8EA0-849044873F59/0/Output_Filters_Design_Guide.pdf

In the guide Danfoss recommends the use of either dV/dt or sine filters in applications with frequent regenerative braking. 

I've done the first calculations for the filters. The results are looking good for a low pass (sine) filter.
If the PWM frequency is high enough (say 50kHz) I'm pretty sure it won't be too difficult to make a coupled filter inductor with a relatively small and low cost 110mm iron powder toroid. 
Also needed: three “DC LINK” rated 50 nF (600V / 20Arms ripple) output capacitors. Gives the filter a cut off frequency somewhere around 3kHz. Installing two filters in parallel should keep them cool enough for the 100kW peak power output of the “reference” Siemens Azure motor.  
Total material cost estimation: only US$250 per filter. In comparison, dV/dt filters aren't that much smaller or cheaper.


----------



## Sonikaccord (Dec 17, 2012)

*Re: PWM frequency and sine filter*

Nice article Tony!

So I see the benefits of a LPF in motor drive applications. Are the benefits the same for induction motors and PMSM? I would think that the induction motor would benefit more from this design.

How great is the tradeoff between motor efficiency and filter efficiency?


----------



## Tony Bogs (Apr 12, 2014)

If cost isn't an issue, filters can have very low losses. But there's always a tradeoff. Weight, cost and performance. 

For instance: the low cost filter needs a high PWM input frequency. Obviously, the low cost is a plus. 
The tradeoff is a slight increase in switching losses in the SiC. But the filter copper losses are lower. 

Estimates for the reference motor and a single filter:
Filter magnetic core losses: 200W max (at low speed)
Copper losses: 40W at nominal load, 160W at peak power
Dual filter:
Filter magnetic core losses: 100W max (at low speed)
Copper losses: 80W at nominal load, 320W at peak power

The core losses depend strongly on the magnetic properties of the toroid.
200W means that the toroid needs forced cooling with a peltier element. So I prefer the dual filter solution.

PMSM: the effects on windings, iron and ball bearings are the same. 
Effects on the PM: don't know, but for DIY: you can only get it wrong once (demagnetize).


----------



## Tony Bogs (Apr 12, 2014)

The next version of the PCB design for the gate driver is attached.
With component values and device identification.
If all goes well, I'll post a picture of the assembled PCB next week.

UPDATE (2020): IMAGE DELETED, cascode SiC JFETS will be used


----------



## Tony Bogs (Apr 12, 2014)

Here's the picture of the assembled sic gate driver board as an attachment. 
The components are in DIY size. Made with a cheap phone, so it is not very sharp. 

The next step is the filter.
A measurement must be done to know the effect of the core losses of the toroid. 
Amidon material 26 is the reference material. It's iron powder for choke and filter applications.

As a reminder: 
Recently EV regulations include EMC tests. 
No wonder, the advancing technology in power electronics leads to ever faster switching and higher frequencies. 
The filter priority is easier EMI/RFI compliance. The other effects are bonuses.


----------



## Tony Bogs (Apr 12, 2014)

The toroid iron core is in. A picture of the test circuit for the toroid can be found in the attachment. 

The reason for the test is that the only loss spec for core material is: choke/filter applications. 
So it needs to be tested with a half bridge inverter to determine core heating @ 50kHz. The rise in surface temperature is measured with an infrared thermometer.

The 40 °C measured temperature rise is what can be expected with Amidon 26. 
The dimensions match two stacked Amidon T400A cores. If it looks like, smells like and feels like ... 
 
Ok, the result is that the core will do for a 50kHz sine filter.


----------



## Tony Bogs (Apr 12, 2014)

Tests show that the gate driver board is a little over its maximum drive capability at 50 kHz. A single isolated Recom DC/DC source can't supply the necessary milli-amps. 
I've found a nice Fairchild SOIC16 controller for a compact and fully protected LLC resonant converter for the next version.


----------



## MPaulHolmes (Feb 23, 2008)

This has been very informative for me. Thank you! I know those soic16 opto/gate drive chips have a soft turn-off when a desat signal is triggered inside the chip. Does using the disable pin on the ixdd609 (I can't remember if that's the part number) remove the soft turnoff? I used an npn-pnp totem pole to boost the current from the fod8316 since one of those datasheets recommended that for preserving the desat soft turnoff.


----------



## Tony Bogs (Apr 12, 2014)

Sorry for the late response. Had more urgent matters to attend to.
You don't want soft turn-off with SiC.
Short circuit faults that last longer than let's say 1 microsecond can destroy a SiC.
So SiC should be rated for higher turn-off voltage spikes than IGBTs.

The latest version of the gate driver uses the "standard" IXDN609 (without enable) in a SOIC package.

The design of the resonant power supply took quite a bit of time.
Analytical methods and models only go so far for the design of the frequency compensation of a resonant supply.
It takes hardware measurements to be sure.

Modification: The ACPL-331J has better isolation, dV/dt and turn off time specs than the ACPL-332J.

Latest PCB layout can be found in the attachment.


----------



## PStechPaul (May 1, 2012)

I just found this discussion and it has been quite interesting. I didn't see any links to the Cree CAS300 device, so here is what I found:
http://www.cree.com/Power/Products/SiC-Power-Modules/SiC-Modules/CAS300M12BM2

Datasheet:
http://www.cree.com/~/media/Files/Cree/Power/Data%20Sheets/CAS300M12BM2.pdf

They are about $560 each from Newark, and there is a 1700V version for about $850. The price/benefit ratio may be excessive at this point, at least for DIY EVs, but that can change. Apparently the benefit of much higher frequency PWM may not be all that applicable to motors, except when filters are used on the inverter outputs.
http://www.newark.com/cree/cas300m12bm2/sic-mosfet-dual-n-channel-1-2kv/dp/55X2370

But there may be immediate and significant benefit for chargers and DC-DC converters. The EMW 10kW charger I'm working on uses IGBTs, probably because they are readily available for cheap on eBay as surplus or pulls from older VFDs, but they limit the PWM to the range of 8-20 kHz and that dictates large, expensive, and heavy magnetic components. Perhaps the SiC MOSFETs may allow a redesign at 50kHz or higher. A 1200V 47A TO-247 SiC MOSFET is only about $33 and two to four of them may easily replace the large IGBT bricks at reasonable cost and probably much lower overall cost because of the smaller magnetics.
http://www.newark.com/cree/cmf20120d/n-channel-sic-power-mosfet-1200v/dp/25T0989

Actually, for chargers and DC-DC converters, 600V is plenty, and there are 47 amp 600V TO-247 MOSFETs for less than $3 each:
http://www.newark.com/vishay-siliconix/sihg47n60e-ge3/mosfet-n-channel-600v-47a-to-247ac/dp/68W7055

I don't intend to hijack this thread to discuss other than controllers, but I just wanted to comment and keep track of this project.


----------



## Tony Bogs (Apr 12, 2014)

At lower frequency than 50 kHz the major benefit is the higher efficiency (lower switching losses),
which reduces the overall cost, weight and size of the power electronic system. 
Especially the cooling part. Even with SiC at $500 to $800 a piece. 
It's going to take some time for SiC to become mainstream.

I've read most of the posts on the EMW charger project. If I remember correctly, the design has SiC diodes in it. 
In general, due to higher switching frequencies, power electronics have seen a reduction in size over the last decades. 
Complete 1A step down converters (no external components) are now available in TO220 and similar packages.
The reduction is size also applies to magnetic components. 

For voltage rating of power devices there's a lot of information available online. 
Bus voltage, bus bar inductances, and especially high turn-off currents are important for the voltage selection.

With 300A devices available (Cree is the first), SiC is now an option for high power inverters.


A lower frequency is more suitable for an integrated EV inverter-motor drivetrain.


----------



## Tony Bogs (Apr 12, 2014)

NEXT STEP: INTEGRATION IN A CONTROLLER

The obvious next step is to integrate SiC in a controller. 
The Tumanako(-vc?) open source project has shown great progress recently. 
Videos of converted cars, equipped with home brew Tumanako controllers, being driven on the open road, have been placed online. 
The project started several years ago. In 2007/2008 or maybe even earlier. 
Initially an expensive Semikron mosfet power unit was used, later on a DIY kit for IGBTs became available. 
The kit is well known on this forum.

So there's been development for a longer period of time, 
it's obviously DIY, it has been reported to work and it's open source. Excellent relevant credentials, I guess. 

Some of my (2015) hardware considerations:

> Of course: SiC mosfets replace IGBTs.
> Implementation of SPI readout of fault signals (SiC gate driver signals) and isolated ADC board (bus and phase voltages, temperature sensors)
Which means new designs for a main board and an ADC board. 
The main board needs different pin assignments, more connectors, and many newer components are only available in SMT packages. 
> I've got a current sensor circuit that I've designed and built a few years ago with one current sensor (Honeywell CSNX25). 
A one sensor board should give flexibility in the placement on the phase cables. 
Also, with sensors on all phases and desaturation detection in the gate drivers, full short circuit detection can be achieved
(reference: Fuji IGBT module application manual REH984b_a, chapter 5, section 1-3, page 5-5). 
> Addition of ground loop opto isolators. (High speed) opto isolators are cheap. About a buck a piece or less. 
> The Olimex USB-ISO should provide adequate HID safety isolation (up to 1000 VDC) for the laptop USB to controller USART connection when the HV is on. 
> All components must have an extended temperature range. Preferably automotive grade.
> No analog circuits on the MCU main board. Clear exception: MCU ADC I/O connection to phase current sensor boards.

STATUS SIC GATE DRIVER BOARD
Final tests are being prepared. With some other opto components. 
And a final design for the undervoltage detection with automotive grade SMT devices.

RESONANT CONVERTER
Not interested in the hardcore engineering side of LLC resonant converters? 
Then you probably want to ignore the links below.

Measuring the transfer function of the hardware to be sure:
www.ti.com/lit/an/slua582a/slua582a.pdf

A must read IMHO, the theoretical approach:
scholar.lib.vt.edu/theses/available/etd-09152003-180228/unrestricted/Ch6.pdf

A LLC recipe:
https://www.fairchildsemi.com/application-notes/AN/AN-4151.pdf


----------



## Tony Bogs (Apr 12, 2014)

The special design for the main (MCU) board is in the attachment. 
There are seperate connectors for the three current sensor boards and the six gate driver boards. 
The 1/10 inch SIP spacing is the standard for low cost pre-assembled cable kits. 
Other connectors: SPI (2x), PWM out (quasi analog out, 2x 2 lines), RELAY out ( precharge and HV on), 
fast response inputs (4 lines: EMCY, BRAKE, MPROT, BMS), rev sensor , and a LLC resonant power source input (14 to 18V)

Pins have been re-assigned to free up I/O for SPI use: USART2 (SPI master, 8 bit, 115200 baud) and SPI2 (master, 16 bit, 5Mb). 
Re-assigned timer outputs (TIM3) can provide quasi analog signals for instrumentation I/O boards (for instance speedo, boost, regen, engine rpm). 

Two SPI boards are necessary to implement the new I/O in addition to the Tumanako I/O as it is:
> a low frequency, isolated digital I/O board (ON, START, FORWARD, REVERSE, ERROR, OVERTEMP) on USART2 
> an ADC board for isolated temperature and voltage measurements on SPI2

The six fault signals from the gate driver boards are read through SPI master USART2. 
It's a good illustration how little is needed for SPI I/O. An eight bit HC165 shift register, a HC132 and a schottky diode. 
The two remaining HC165 bits are used for the low frequency EMCY and MPROT (fault) input signals. 
All eight fault signals, when active, immediately generate a direct shutdown signal for the PWM timer TIM1 (BKIN).


----------



## kennybobby (Aug 10, 2012)

What PWM frequency and how is the pulse width calculated? Is it based upon feedback from the 25A current sensors? What is the frequency response of the current loop, i.e. the response time of the current sense board measurement, the ADC conversion, the PWM calculation, the gate driver on/off.

Are you just PWM the top transistor and holding the bottom ones on, or are they all being pulsed separately?


----------



## Tony Bogs (Apr 12, 2014)

PWM frequency: without sine filter just above audible, with sine filter 50 kHz (see earlier posts). 
Bandwidth CSNX sensor board (25A, for low power test runs) about 100kHz, LEM 800A 50 kHz (spec). 
Response time overcurrent to shutdown is to be determined (estimated 2.5 us @ 50% overdrive).
Schematics will follow as soon as tests are completed.
Calculation and other questions: for now check out Another homebrew controller (Tumanako) software @ johanneshuebner.com and on this forum.

The schematic for the spi fault circuit is attached (not yet tested).
And a picture of the resonant ps circuit of the gate driver for test purposes (mainly control loop measurement, effect of second transformer (-5V SiC off voltage) on transfer function).
The brightly red and yellow of the caps for the compensation network are easy to spot.
Added the list of reassigned pins.


----------



## Tony Bogs (Apr 12, 2014)

The schematic for the first 'off main board' SPI circuit is in the attachment. 
It's for the low frequency (Human Interface) input signals like START, mode selection (SPORT/ECO), FORWARD, REVERSE. 
All inputs have optocouplers for safety and against common mode / ground loop issues.

The SPI ADC that I'm going to use is the LTC2360. 12 bit, 10us cycle, low power. For SPI isolation I'll try the FOD8160 (10Mb).

*Gate drive DC/DC converter:*

In IGBT / mosfet driver applications the insulation in converters is subject to high dv/dt stresses. 
Contrary to most other types of converters, the primary and secondary windings of a LLC resonant converter can be placed at great distance in seperate chambers. 
A small 2 by 2 cm core can convert up to 10W. I've decided to go with LLC for the extremely fast switching SiC. 
Even for a 1200V/600A IGBT powerbrick I'd probably prefer LLC over 'off the shelf' low power modules (<= 2W) to be safe under adverse conditions. 

An important test to perform is measuring the effect of high dV/dt on the feedback input (optocoupler) of the converter. 
I'll use the 300V mosfet stage I've used earlier for the toroid test.


----------



## Tony Bogs (Apr 12, 2014)

*Current sensor board.*

I blew away the dust and re-designed my CSNX25 current sensor board to make it more compatible with the current Tumanako setup and ready for high power (LEM sensor).
The first checks and corrections are done. The result is in the attachment.

*On board overcurrent detection.*

I've moved the overcurrent detection to the sensor boards. 
There is an opamp rectifier in the CSNX25 circuit that I've left in for that purpose. 
So now only one timer output will do as a LF DAC for setting the overcurrent threshold. 
N.B. I'm using desat and undervoltage detection to protect the SiC power bricks. 
Current sensor response time is not critical for the bricks in my setup. 

*Schottky diodes. *

The new design has Schottky diodes in the opamp rectifier circuit. 
A high temp leakage current (significant above 100 degrees C) can cause a slightly negative offset in the output of the rectifier. 
First calculations show a peak value of about -50mV at 125 degrees C. 
The sensor board full scale range is 2500 mV. 
So at reallly high temperatures the overcurrent detection might trip at just a little bit lower amp value. Can't be bad.
Correction: just the other way around, maybe an adjustment of the threshold in SW is necessary if the Tumanako software does not lower the threshold already with increasing temperature.

*Accuracy.*

I'll be using 0,1% resistors for the parts of the circuit that can affect accuracy (R* group). 
Reference voltages and DC shifts are derived from a 5V precision (trimmed) regulator (0,15% LT1461).
Since the STM32-H103 ADC is already 1% or worse and the LEM is 1% or worse, higher accuracy on other parts might keep the total below 3%.

*LEM HTFS high amp series.*

Only a few modifications are needed for the LEM HTFS-P high amp series (300 to 1200A peak). Mainly resistors for load and range.

EDIT 21/10/15: BAS70 diode solves schottky leakage issue.


----------



## Tony Bogs (Apr 12, 2014)

Two checks:

*TIM3*

TIM3 is used for the rev input by the Tumanako software. 
First check indicates that the TIM3 channels can't be used for quasi analog LF output.

*ANTI ALIASING*

The ADC conversion rate on the STM32 chip must be high enough to prevent aliasing errors. 
First check does not result in "all clear" for the current Tumanako configuration. 
Without a sine filter the spectrum of the output signal of the current sensor contains PWM frequency components. 
Low frequency IGBT setups are probably in the clear.
I've seperated the overcurrent detection circuit from the measuring (ADC) part on the current sensor board. 
If anti aliasing filtering is necessary, it will only affect the bandwidth of the ADC branch, not the response time of the overcurrent detection.


----------



## Tony Bogs (Apr 12, 2014)

*SPI OUT*
No LIN or CAN yet, so it's SPI for the output signals to the safe, low voltage car subsystem (the good old PbS equivalent). 
Isolated of course, with high reliability, low temperature drift (CTR) and low degradation optocouplers. 
My choice: Vishay SFH6156-3T. Only half a buck a piece.
Smartmos switches to replace, otherwise drive, relays if possible.

The USART in SPI synchronous mode can generate much higher bitrates than 115200. SPI is flexible, devices can be cascaded to 16 bit, 24 bit .... 

*DC/DC*
I've replaced the 20mm ferrite with a 25mm version, that has more pins (as can be seen on the main board PCB layout). 
No real difference in cost, triple power, and no second transformer on the gate driver board.

Q: Why a relatively large transformer?
A: The gate driver is close to the power bricks where temperatures can reach high values. 
Many high frequency power ferrites are at risk of thermal runaway at high load and ambient temperatures above 85 degrees C. 
Up to the Curie temp where the magnetic properties are lost.
For many DC/DC converters substantial derating is specified around that temperature. 
For example: nominal 3W at 75 degrees C, 0W at 90 degrees C.
So the answer is: extreme oversizing to extend the temperature range to about 105 degrees C


----------



## Tony Bogs (Apr 12, 2014)

*DC/DC dV/dt review*
A first analysis indicates that a high common mode dV/dt injects a significant error signal in the optocoupler feedback. I've decided to take the shortcut: eliminate the error signal by using digital feedback. I've chosen the Avagotech HCPL-7520. The indicated applications include switched mode power supply signal isolation, and general purpose low-power current sensing and 
monitoring. Key features: 15kV/us CMR, sigma-delta conversion, 100 kHz bandwidth, -40 to 100 degrees C ambient, 891V working voltage.

*ANTI-ALIASING FILTER*

In my setup (auto tranny and reference Siemens motor 1PV5135-4WS140) the phase frequency will not be higher than 100 Hz (~6000RPM). 
A cut -off frequency of 2 kHz, single pole RC, results in a phase shift of about a degree @ 100Hz and 20dB attenuation at 20kHz (~ minimum PWM frequency SiC). 

With phase output sine filter, PWM 50kHz:
The LEM sensor is noisy and the output of the filter contains some residual PWM ripple. Cut-off at 5 kHz. 

*LEM specific current sensor PCB layout:*


----------



## Tony Bogs (Apr 12, 2014)

*GATE DRIVE POWER REQUIREMENT

*It's quite easy to calculate the required gate drive power for an IGBT/ MOSFET if the important parameters are known:


Total gate charge Q (positive gatevoltage V+ ) @ the maximum load point
Gate capacitance C (negative gatevoltage V-)
Drive frequency f
Supply current for the driver electronics Is
 Power : P = (f * Q * V+) + (f * C * V- * V-) + (Is * (V+ - V-))

*Here's the engineering catch:* determining the maximum load point for the total gate charge. 
The application manual for the power brick should give some guidelines. 
Some things to consider:


is the HV layout optimised? (low inductance laminated bus bar OR copper DIY strips?)
motor specs: phase inductance and voltage (PWM ripple), amps.
Fault conditions, for instance partially shorted phase wiring.
High temperature range
 The datasheet usually specifies a *TYPICAL* total gate charge at a *GIVEN NOMINAL LOAD POINT and gate drive voltage*. 

Calculation for a 600A/1200V power IGBT brick *@ datasheet load point*:
The specified total gate charge Q @ Vge = 15V, Vce=300V, Ic=600A, is 2400 nC *TYPICAL*.
The gate capacitance is specified as 90nF max. A desat driver takes about 7,5 mA.
At 10 kHz, +15/-15V the required power is 787,5mW *TYPICAL at the datasheet (ideal/ nominal) load point*. 720 mW @10kHz, +15/-5V

In a high power(100kW), high amp, low phase inductance DIY setup, I would not drive the IGBT brick with less than 3W OR without the usual protection against short circuit, overtemperature, desat and undervoltage. 

So it's not that difficult to calculate the (nominal/datasheet) power requirement for two CAS300M SiC in parallel @ 50 kHz.

Enjoy!

Done the high dV/dt optocoupler test: 100mV disturbance with a 300V pk-pk signal, 50 kHz. 
50 kHz is way above the loop bandwidth, but lower frequencies can affect the regulation.


----------



## Sonikaccord (Dec 17, 2012)

For 2 CAS300m17s in parallel:
Ciss = 20nF
Drive freq = 50 kHz
Gate charge = 1076 nC
V+ = 20 V
V- = -5 V

2x[(50kHz * 1076 nC * 20V) + (50kHz * 20nF * -5 V * -5 V) + (7.5 mA * 25V)]

= 3027mW

Question:
Why LLC over another isolated topology like forward or flyback?

I'm still following this thread. I would like to learn more about protecting the power devices as it is still very much a mystery to me. It looks like you're from across the pond. Sorry for any incorrect use of the comma.


----------



## PStechPaul (May 1, 2012)

I'm trying to understand the calculation of power requirement for gate drive. I see that the energy for the ON state is determined by 1/2 the charge times the voltage, and that for the OFF state by 1/2 the capacitance times the voltage squared. The energy is actually the difference in the two energy states, and the fact that the energy is transferred into and back out of the gate each cycle doubles the 1/2 factor.

The power is actually dissipated during the transfer of the energy, which involves the total resistance of the gate circuit and the current integrated over the transition time. According to the following document, it seems that this power works out to be 1/2 that of the transfer of energy, regardless of the value of the resistance or the speed of transfer. My LTSpice simulation seemed to show something like half the power predicted by the equations above. Also, the gate capacitance may be a function of voltage as well as the voltage across the collector to emitter and perhaps other factors such as current.

Here is the article that seems to explain this phenomenon:
http://hyperphysics.phy-astr.gsu.edu/hbase/electric/capeng2.html

Perhaps it may be possible to achieve a nearly lossless transfer of energy between the source and the gate capacitance by using inductance rather than resistive elements (including BJTs and MOSFETs in the driver). However, it is likely to be impractical and unnecessary considering the small amounts of gate drive power compared to overall losses in a multi-KW inverter or other IGBT switching device.


----------



## Tony Bogs (Apr 12, 2014)

The gate resistor is totally irrelevant for the power requirement. 
The formula for the energy storage in a cap in the link you posted is correct though.
To "fill" the cap with charge using a RC network, it takes twice that amount of energy, independent of the R value. 
But the R is relevant for the time it takes to filll the cap and other performance figures (in a gate drive circuit). 

An inductance introduces ringing. That's really bad. 
Even a 10 cm wire between driver and gate is a factor to take into account. 
In the selection of the gate resistor to dampen ringing. 
Twisting the wire with the return reduces the inductance. 
"Independent" sources: semikron application notes AN-7002, AN-7003. 
R>= 2 * SQRT (L / C). L= wire inductance (app. 100nH for 10cm untwisted), C= input capacitance IGBT/Mosfet). L= 100n, C =10n: R > ~6.6 Ohm

"Independent" source for the power formula: for instance IXYS site.
IXAN0010 (eq 1.4, only positive drive voltage, first term in the equation I posted).

Because the gate is not a simple cap, there's a load point dependent Q for charge in the the first term.

And there's IXAN0011 (higher efficiency in driving with IXYS driver ICs).


----------



## Tony Bogs (Apr 12, 2014)

@PStechPaul:
First I didn't quite know what to make of your earlier post about the EMW charger. But I think I've got it now.
Great idea, a modular charger. Would also make a great SiC project. Huge wide airgap U core transformer, resonant of course. All very efficient.


----------



## Tony Bogs (Apr 12, 2014)

The modular charger design is on hold, waiting for delivery of SiC diodes.

Time for an NEWS update on high power SiC:
- Semikron has released a 540A,1200V half bridge SiC module. Product is still in sample status: http://www.semikron.com/products/product-classes/sic/full-sic.html
- PDF data sheet: http://www.semikron.com/dl/service-...semikron-datasheet-skm500mb120sc-21919770.pdf
- Toyota to test SiC: http://insideevs.com/toyota-to-test-sic-semiconductors-in-camry-hybrid-fuel-cell-bus/

Cost and maturity of the high power modules have not reached the levels at which application is straightforward. 
I am already applying more mature lower power SiC devices in my modular charger design. So far SiC works great. 
The Tumanako project has shown some issues at high power levels. 
So I guess an intermediate stage is the right way to continue. 
A low power SiC inverter for the auxiliary (belt driven) system: AC, power steering, vacuum pump ....


----------



## Tony Bogs (Apr 12, 2014)

I've decided to switch to the ACPL-339J for maximum flexibility in drive parameters: http://docs.avagotech.com/docs/AV02-3784ENP
And smt parts with smaller foot prints: the png shows the redesign in progress.

On page 18 of the ACPL-339J datasheet there's a very interesting table about the drive requirements of IGBTs. 
An estimated 16A peak for a 1200V/600A IGBT. Based on 4000nC gate charge. 
Avagotech suggests a 35A trench mosfet to drive the IGBT gate.


----------



## Tony Bogs (Apr 12, 2014)

Just found out that CAN is supported on the Arduino Due: http://forum.arduino.cc/index.php?topic=131096.0
Can is not supported by the Tumanako libraries, so I definitely will start with porting the inverter software to the Due. The Tumanako external I/O (user, BMS ...) is really from a previous era. 
The STM32 can still be used for the auxiliary system for comparison.

Microchip has an easy to use and cheap standalone Digital CAN I/O Expander device: MCP25020. Also available with 10bit ADC.
http://ww1.microchip.com/downloads/en/DeviceDoc/21664D.pdf


----------



## Tony Bogs (Apr 12, 2014)

I believe there's a question that remained unanswered. 

Q: Why LLC and not flyback or another topology?
A: Main reason is that LLC works great with low coupling factors. Primary and secondary windings can be seperated on a two chamber coil former.
No need for triple insulated wire or mylar. Also: LLC is resonant, which means low stress on components (ZVS and ZCS switching).

I have solved the schottky leakage issue with the current sensor board. Actually really simple. Just use another diode: BAS70. 
So the components can be soldered on. PCB has been in a drawer somewhere. Think I can still find it. I will try to get all the components in before X-mas. 
Same goes for the gate driver board, but the progress on the PCB design is slow.


----------



## Tony Bogs (Apr 12, 2014)

The current sensor board. 800Arms LEM sensor. Some components are not in yet. The BAS70 diode and 0.1% resistors. 

See if it works and then get the other one ready (need at least two).


----------



## Ai! (May 9, 2014)

why there are not all smd components? weird look)


----------



## Tony Bogs (Apr 12, 2014)

Yeah, those R's are 0.1%. Not available in SMD. Mounted in DIY SMT style. 

I try to keep everything within the DIY comfort zone. In particular the "special" parts: PCB, inductors, transformers ...
Btw, that is one of the other reasons for LLC. The transformer is relatively huge for the required power. Only a few turns (about 25) are needed at the high LLC frequency.

I will also try to get rid of the LLC compensation network. Use hysteretic control in stead. That *should* make the feedback practically independent of the "plant" transfer function.

EDIT: My mistake: 0.1% is available in SMD. Next version is all SMD.


----------



## Tony Bogs (Apr 12, 2014)

The hystereti control for the LLC at fixed frequency. 
I have modified an earlier LLC gate driver P/S and replaced the usual frequency control and feedback compensation. 
Works fine. The hysteresis is 400mVpp at 20VDC.
For a higher isolation working voltage (1414Vp) the ACPL can be replaced with an industrial grade FOD8160. 
The FOD does need a zener circuit on the controller side, Vcc = 5V.
I did the usual extreme conditions check: drive capability of the LM2903 is only 6mA garuanteed. Not enough to drive the optocoupler.


----------



## Tony Bogs (Apr 12, 2014)

About PCB layout: big through hole components are always on the opposite side. Saves space.

Some points reagarding hysteretic control:


The pulse skipping mode (hysteretic control) is a normal mode of control for a LLC. Most often used for light loads.
At a fixed frequency (just above resonance) the LLC behaves like a “DC transformer”. 
Formula: OuputV = K * InputV. K is almost independent of the load.
Hysteretic control is similar to the very common ''thermostat' control. If the temperature (voltage) gets too high/low, turn the heater (LLC) off/on. Nothing new here.
 So it looks like that there will be a gate driver board before the end of the year. 
Although the image may not give that imprression, it's just a matter of stitching the different sections together.


----------



## Tony Bogs (Apr 12, 2014)

The stitching is done. High amp driver board for two Cree modules in parallel. Up to app. 100 kHz.
One board connects directly to the modules. The other one is stacked on top with suitable through PCB connections.
There are still some checks to be done and the mounting holes have to be sorted for stacking.


----------



## Sonikaccord (Dec 17, 2012)

Very nice! Lots of progress has been made since I last checked in here.


----------



## Tony Bogs (Apr 12, 2014)

I finally got around to installing the toolchain on my new eight core desktop. 
Only the usual mods to the Makefile, -I, -L, etc, and a few symlinks were needed to get stm32sine.bin.
For further development I will get me some sort of pi. Probably fruity:raspberry.

First addition to the software has been made: rcc call to enable the clock for the alternate function registers. I want to use SPI.

Remap code snippets to free up SPI2 and USART2 lines:


----------



## Tony Bogs (Apr 12, 2014)

A 55kW SiC inverter designed by NCSU researchers 12,1 kW/L :
http://www.greencarcongress.com/2016/09/20150915-ncsu.html


----------



## Arlo (Dec 27, 2009)

Tesseract said:


> Desaturation is a unique phenomenon of bipolar devices like IGBTs and does not apply to unipolar devices like MOSFETs. Without getting too bogged down in technical details that will just make the eyes of most people here glaze over, the voltage drop across a MOSFET is linear with current (though exponentially proportional to temperature; roughly to the 1.6 power) while the voltage drop across a bipolar device like an IGBT is relatively constant except for an ohmic loss which is linearly proportional to current (just like a MOSFET) and a diode-like increase of 60mV/decade of current up until the current is so high that there are insufficient charge carriers available. It is at this point that the voltage drop abruptly increases (e.g., from 1.5V to 6V or more) and the bipolar device is then said to have come out of saturation (ie - it has desaturated).
> 
> Long story short, you can't use a typical "desaturation protection" circuit with SiC MOSFETs; rather, overcurrent protection will have to depend on high speed "cycle by cycle" limiting.


I and many others have implemented desat with mosfets and it works fine. You just need to use a zener rated for the right current flow and set the voltage on the desat pin to a number that will trip the desat when the mosfet voltage drop gets high enough but is still in the safe limits for a single pulse. Usualy about 2x the peak desired currents used.


----------



## Tony Bogs (Apr 12, 2014)

Arlo said:


> I and many others have implemented desat with mosfets and it works fine. You just need to use a zener rated for the right current flow and set the voltage on the desat pin to a number that will trip the desat when the mosfet voltage drop gets high enough but is still in the safe limits for a single pulse. Usualy about 2x the peak desired currents used.


Here is the CREE/WOLFSPEED/PRODRIVE Certified gate driver board (production solution**) specifically designed for the CREE CAS300M12BM2 SiC: 
http://www.wolfspeed.com/pt62scmd12

The VDS desat/overcurrent trip point is typ 4V as specified in the datasheet:
http://www.wolfspeed.com/downloads/dl/file/id/569/product/187/pt62scmd12.pdf

Timing is also very critical. Specified overcurrent (desat) blanking time: 0.75 to 1.25 usec, turn-off time 1 usec max.

Main differences between the ACPL339J/LLC and the CREE/WOLFSPEED/PRODRIVE:
Jitter:
Unknown ACPL339J vs CREE/WOLFSPEED/PRODRIVE 1 nsec typ
Switching frequency:
200 KHZ ACPL339J vs 125 KHZ CREE/WOLFSPEED/PRODRIVE 
Dead and blanking time:
external (uC) set / on board ACP339J vs ON BOARD GENERATOR / SET CREE/WOLFSPEED/PRODRIVE
dV/dt immunity:
50kV/us ACPL339J vs 100kV/us CREE/WOLFSPEED/PRODRIVE
Signal isolation:
Optocoupler ACPL339J vs No optocoupler CREE/WOLFSPEED/PRODRIVE
Interface:
Direct LED drive ACPL339J vs RS422 CREE/WOLFSPEED/PRODRIVE
Propagation delay:
250nsec max ACPL339J vs 125nsec typ @25C CREE/WOLFSPEED/PRODRIVE


----------



## Tony Bogs (Apr 12, 2014)

Forgot a very important difference between the driver boards: ACPL339J drives two SiC mosfets in parallel, the CREE/WOLFSPEED/PRODRIVE 1 high and low side mosfet (halfbridge).

Found this isolated CANBUS transceiver (50kV/us) for harsh environments:
http://www.ti.com/product/iso1050


----------



## Tony Bogs (Apr 12, 2014)

Mitsubishi presented a 86kVA/L working model of a SiC inverter.
Expects commercialization for EV's in 2021:

http://www.mitsubishielectric.com/news/2017/0309-a.html


----------



## Tony Bogs (Apr 12, 2014)

Looks like we have to wait four or five years for SiC to become mainstream. 
Plenty of time to do a bit of programming.

First on the long list of things to do: port the inverter software to the ***uino zero (m0) (pro) architecture,
based on the "smart" series of Atmel ARM microcontrollers.

http://www.atmel.com/Images/Atmel-42181-SAM-D21_Datasheet.pdf


----------



## Tony Bogs (Apr 12, 2014)

Porting the software to an AEC grade will have to be put on hold, because there are 
great developments on the Tumanako projects by Johannes Huebner (jhuebner) and Damien Maguire (jackbauer). 
Huebner is going to upgrade his kit with an air cooled (great) high power IGBT stage, CAN and more. 
Damien is working on a Tumanako digital board for the big Tesla model S drivetrain: http://www.diyelectriccar.com/forums/showthread.php?p=885049#post885049

So it's time to continue with IGBTs (for now and probably the next ten years) and a high end (Tesla) ACIM. 
I will try to keep up with a board for the 150kW front drivetrain of a Tesla 85D. 
Basically the same functionality as Damien's board, but I have chosen other parts, for example: 

lm2734xq buck (was 3A LM2596S) has a 10x higher freq, works with much smaller parts and is AEC grade. It is only 1A but that should be more than adequate.
TPS73233Q 3.3V LDO (was LD1117) features high precision, low C (ceramic) values, AEC grade.
TPS60400Q -5V charge pump runs at a variable frequency, AEC grade. 
RBT7 version of the STM32F103 controller has an extended 105 deg C temp range. The Atmel D21L (125 deg C) comes later.
NXP 74HCT4052 analog switches for temp sensors: extended 125 deg C temp range.
TRS3232E-Q RS232 transceiver is cheaper with AEC and an extended temp range.

http://www.ti.com/general/docs/lit/getliterature.tsp?genericPartNumber=LM2734&fileType=pdf
http://www.ti.com/general/docs/lit/getliterature.tsp?genericPartNumber=TPS60400-Q1&fileType=pdf
http://www.ti.com/general/docs/lit/getliterature.tsp?genericPartNumber=TPS732&fileType=pdf
http://assets.nexperia.com/documents/data-sheet/74HC_HCT4052.pdf
http://www.ti.com/lit/ds/symlink/trs3232e-q1.pdf
http://www.ti.com/general/docs/lit/getliterature.tsp?genericPartNumber=LM2734&fileType=pdf


----------



## Tony Bogs (Apr 12, 2014)

To be absolutely clear: this is not a Tumanako-kiwi-openinverter based project.


----------



## nitrousnrg (Feb 25, 2016)

Tony Bogs said:


> The first Kicad schematics for my Tumanako - Tesla build


You might find this interesting
https://endless-sphere.com/forums/viewtopic.php?f=30&t=84930
https://endless-sphere.com/forums/viewtopic.php?f=30&t=89056

Both made in kicad

Cheers


----------



## Tony Bogs (Apr 12, 2014)

Schematics for RS232, digital outputs (relay drivers) featuring fully protected smartmos Infineon BTS3110N HITFETS, and version 2 of the digital inputs.

EDIT: forget isolated inputs, not enough pins on connector. Missed that bit in Damiens video. 
Digital inputs V3 has transient suppression, because the STM32 has +/- 5mA functional EMI susceptibility on most GPIO pins.
Some even less: 0 mA on PA4,PA5 and PC13..PC15. No current injection allowed on these pins for reliable operation.


----------



## Tony Bogs (Apr 12, 2014)

*CONTROLLER BOARD DESIGN FROM SCRATCH*

Well, it has become clear from Damiens video and posts in his *DIY Tesla Controller *thread that a Tesla drivetrain is a CANBUS system. 
The highly integrated drivetrain is a great starting point for a SiC build, but there just aren't enough pins on the external connector for a lot of parallel I/O. Only brake and throtlle. 
I'm going to start from scratch with the design of a CAN and SPI based controller board with xxxuino compatible Atmel MCUs. 
Probably a 32 pin ATMEGA64M1-AZ for the main board and another AVR on an external CAN satellite board for I/O: throttle, shift stick input etc.


----------



## Tony Bogs (Apr 12, 2014)

nitrousnrg said:


> You might find this interesting
> https://endless-sphere.com/forums/vi...p?f=30&t=84930
> https://endless-sphere.com/forums/vi...p?f=30&t=89056
> 
> Both made in kicad


Oh yeah, IBGTS for now, and once again found confirmation that an ARM 32bit has lots of spare resources like computing power in a motor controller.


----------



## nitrousnrg (Feb 25, 2016)

Tony Bogs said:


> Oh yeah, IBGTS for now, and once again found confirmation that an ARM 32bit has lots of spare resources like computing power in a motor controller.


That microcontroller is a monster, and most important, the FOC code and graphical user interface (CAN-enabled) is already developed =)

And for the powerstage I guess it could be a matter of swapping the TO247 IGBTs for TO247 SiCs when the day comes.

I should make a thread in this forum someday about these


----------



## dcb (Dec 5, 2009)

Tony Bogs said:


> I'm going to start from scratch with the design of a CAN and SPI based controller board with xxxuino compatible Atmel MCUs.


what is wrong with a code compatible board with more pins?!?

http://www.mouser.com/ProductDetail...0WPLDnYsI79VyEGU7o4m/3QnSSCyRl88nt/LYMmnI2g==

with all kinds of other features on it (built in easy to use programmer and etc, even handles arduino shields, and an online compiler if you like)


----------



## Tony Bogs (Apr 12, 2014)

Phew, Damien (jackbauer) had me worried a litlle bit when he posted that the current signal from the Tesla drivetrain is digital (as in: not analog). But luckily, it looks like it is a sigma-delta bitstream. Phew again.



nitrousng said:


> And for the powerstage I guess it could be a matter of swapping the TO247 IGBTs for TO247 SiCs when the day comes.


Well, it isn't that easy. I tried two TO247 SiC in parallel (in my charger design thread) and messed it up pretty bad. 
But I'll try it again when prices come down and if I can find the free time for it.



nitrousng said:


> That microcontroller is a monster, and most important, the FOC code and graphical user interface (CAN-enabled) is already developed =)


and 


dcb said:


> what is wrong with a code compatible board with more pins?!?
> 
> http://www.mouser.com/ProductDetail/...LYMmnI2g%3d%3d
> 
> with all kinds of other features on it (built in easy to use programmer and etc, even handles arduino shields, and an online compiler if you like)


Yeah, that's it. For both. Very nice boards, but with too many features. I want to reduce it to the bare essentials for a Tesla drivetrain. So less pins is better (also for DIY). Probably even no FOC. Well, maybe. 

And I am not sure anymore about porting software. It is not that difficult to implement basic ACIM control and CAN connectivity. On a 16 MHz ATMEGA SVM VFD results in a CPU load of about 10%.

I'm not going to use development boards / shields in my build.


----------



## Tony Bogs (Apr 12, 2014)

Here are the schematics of the ATMEGA64M1 uC basic ACIM controller.
Overcurrent protection is in SW. IGBTs are protected by DESAT.
DESAT still results in a shutdown of the power stage controller section of the uC.
Other parts can survive an overcurrent condition for a longer period of time. 
Response time approximately 500usec (group and phase delay of current sensor filter), which is adequate for motor windings etc.


----------



## jackbauer (Jan 12, 2008)

Could you give a description of the current sensor filter circuit? Might just steal it


----------



## Tony Bogs (Apr 12, 2014)

Chebyshev LPF, characteristic frequency 1000Hz, 0.2 dB pass band ripple.

REV 2 has already been designed  (for FOC): 900 Hz, 0.05dB ripple.

Feel free to copy it. Especially for educational purposes.  

No guarantees. Certainly isn't going to be fast enough for HW detection of overcurrent.


----------



## Tony Bogs (Apr 12, 2014)

The topology in the sigma-delta filter schematic can be used for a great number of filter types. 
Change the following parts 

R7,R8 910
R5,R6 6800
R3,R4 5100
C6,C7 1.5n
C3,C4 150p
C2,C5 330p

Opamp MCP6292

and you get a Bessel 3rd order Low Pass Filter with a characteristic frequency of 48KHz, low signal distortion in the pass band and high attenuation (60dB+) above 1MHz. Step response 0 to 100% is 7 usec.


----------



## jackbauer (Jan 12, 2008)

Sounds ideal!


----------



## Tony Bogs (Apr 12, 2014)

Textbook classic. The topology is widely used and appreciated for its simplicity and versatility. It has been around since 1955. 

Don't hesitate to make good use of it if you think it's ideal for your application.


----------



## jackbauer (Jan 12, 2008)

Thanks Tony. I'm going to give it a shot in the next rev of the Tesla board.


----------



## Tony Bogs (Apr 12, 2014)

First image: LTSPICEIV simulation run of the step response of the 48kHz Bessel 3rd order, duty cycle 0 to 50 and back to 0 @ 4MHz in, LTC6084 opamp.


----------



## jackbauer (Jan 12, 2008)

What clock speed would that equate to for a 16 bit conversion Tony?


----------



## Tony Bogs (Apr 12, 2014)

What R value does a LTC1799HS at the set pin need to run at 10 MHz?


----------



## jackbauer (Jan 12, 2008)

Tony Bogs said:


> What R value does a LTC1799HS at the set pin need to run at 10 MHz?


I have been trying to work that out myself. I can't make the equation in the datasheet work. Not much of an engineer So I just put a 1 Meg pot on the PCB


----------



## Tony Bogs (Apr 12, 2014)

I hope my filter design can approach* 9 to 10 bit resolution* (the ADC of the ATMEGA64M1 is 10 bit).
*BUT:* I'm going to use a* 900 Hz 3rd order Chebyshev* and the *16 MHz* CPU clock. 
That is, if you find that the P85D front drive unit uses a similar circuit as the RWD.

Might give you some indication of what can be expected from a 48kHz Bessel @ 10 Mhz.


----------



## Tony Bogs (Apr 12, 2014)

I finally managed to catch up with Kicad. 
First board layout (OpenGL canvas), component placement almost done, and project specific library (manual soldering) for the ATMEGA64M1 in V4.0.7.


----------



## Tony Bogs (Apr 12, 2014)

Simulations results of a tuned Bessel filter:
- characteristic frequency close to 48 kHz
- app. 12x higher Rin/Zin >> higher accuracy
- voltage shifting at the input 5 > 3.33 V
- high dampening factor ζ ~= 0.8 >> no overshoot
- step response ~ 6 usec (0 to 90%)

For higher accuracy I'm going to add a MAX6071BAUT41 at the VREF input of the ATMEGA64M1 and SN74LVC1G125 buffers at the inputs of the current filter.


----------



## jackbauer (Jan 12, 2008)

Thanks for this excellent work Tony.


----------



## Tony Bogs (Apr 12, 2014)

Apparently someone has misplaced a very nice Tesla P85D front motor.


----------



## Tony Bogs (Apr 12, 2014)

No connector issues here. The controller only needs 5 external wires, because it is a CAN system: GROUND, CANL, CANH, +12V and I have added BRAKE IN.

Bosch introduced the CANBUS system to reduce the number of wires in the wiring loom. And it works.

I have picked the 5pin EDAC E-seal 560 series connectors. http://www.edac.net/dat/files/135.pdf
EDAC is a Canadian company, headquarters in Markham, Ontario. 

The image shows the ATMEGA64M1 P85D front motor controller board design in one of the early stages.


----------



## jackbauer (Jan 12, 2008)

Your miles ahead of me Tony I'll sort out a board outline and hole locations for you over the weekend. The logic board uses a 24 pin 2.54mm pitch dual row connector to the igbt driver stage.


----------



## nitrousnrg (Feb 25, 2016)

If this is a 4 layer board I can help with the mechanical integration or with the layout if you want.

For the pcb outline its best to draw it with an mcad or 2d cad, export to dxf and import the dxf into pcbnew.


----------



## Tony Bogs (Apr 12, 2014)

Thanks. Yeah, probably 4 layers. 

@Damien: OK, bit of a surprise but I can wait a few days.

In the mean time I'll try to sort out the CAN I/O satellite (instrument cluster, throttle, warning lights etc.) 
and an information display / control unit for the auxiliary systems like A/C, vacuum pump, audible warning etc. 
I've seen a very nice blue/white 40x2 Arduino compatible display (parallel HD44.. LCD lib).


----------



## Tony Bogs (Apr 12, 2014)

Yes, finally, the Raspbery Pi A+ is here and it supports CAN boards with a MCP2515!
Just add a TFT touchscreen (at least 10") and the result is a nice, low cost Tesla look-alike.

However, the Pi has not been designed for use in a car to be part of the drive system. 

So here it is: the PCB design of the mini version with the bare drive system essentials for arguably the best compromise of cost, size, reliability etc. Based on the AVR 8 bit automotive CAN/SPI controller ATMEGA64C1.

The board is the human interface for the ATMEGA64M1 controller board that will find its place in the Tesla drive unit.
Possible inputs: micro SD card with preset controller settings, 2.8" touch screen for information, configuration and modification, and the usual pedal and gearshifter inputs: throttle pots (2 max), gearshifter and switches.

Touchscreen: ADAFRUIT 1651 https://www.adafruit.com/product/1651

On/off inputs: PARK-REVERSE-NEUTRAL-DRIVE-ECOGEAR-LOWGEAR-WINTER-SPORT-CRUISE
(Throttle) Pots: 2
Ouputs: TFT 320x240, 4 analog (PWM) outputs for speedo etc., relay drivers for precharge and main contactor. 
Safety input, potential free (up to +/- 50V): BMS/CHARGER

SMPS 6V preregulator with EN50022 EMI filter
5V 1% LDO postregulator
Short circuit multifuse protection on 12V input and switch input circuits
Resistive current limiter on potmeter circuits
Smartmos protection and diagnostics in relay drivers: EMI, overtemperature, overcurrent, overvoltage, reverse polarity, and detection of open/short circuit in relays.


----------



## Tony Bogs (Apr 12, 2014)

The board design is almost ready to be sent to the foundry. 

Bare essentials with regard to functionality.
Example: (regen) brake signaling to traffic relies entirely on the brake pedal switch turning on the brake lights. 
Activating the brake lights via CAN will be implemented in the rear lighting CAN controller. 
The schematics for the front lighting CAN module are done, PCB is next.

Switching on the reversing light via CAN is essential for a single gear transmission. 
It has to be done when the inverter signals actual driving in reverse. So the board in the images supports it.
Another last minute addition: input for the kickdown switch.

Images are in 3D. Not all parts have 3D models (yet). And the male header strip should be female.


----------



## Tony Bogs (Apr 12, 2014)

Final additions to integrate a CANBUS based TESLA drive unit in another non-TESLA car. 

1. BRAKE LIGHT outputs. All essential CAN functionality is now on one board. 
Two drivers, LHS/RHS, each with 4 channels, 3A per channel, two or four channels can be connected in parallel on one driver. 
Should provide enough flexibility for almost every imaginable combination of brake lights. 

2. On board seperate 150mA 5V LDO for the (throttle) pots. Those hall pots are 5V, aren't they?. Yeah, I'm pretty sure they are.

3. Two auxiliary relay drivers. For a FAN, coolant pump or whatever is needed.


----------



## Tony Bogs (Apr 12, 2014)

Now a protocol for sending messages across the CAN bus is needed. 
I'm not going to implement CANopen or anything similar.
CANopen is great for a large (industrial) network with a lot of different types of nodes with its directory service, network management messages, dynamic adrresses and so on.
On a uC about 40K code, 2K data is the minimum requirement for CANopen. 

No, it's bare essential functionality again with a custom protocol.


----------



## jhuebner (Apr 30, 2010)

Probably full CANOpen is that complex. But if you only "steel" the basic SDO and PDO messages from CANOpen you can get away with some 1-2k of code.


----------



## Tony Bogs (Apr 12, 2014)

The complexity of CANopen reminds me somewhat of network operating systems I worked with in IT in the 90s. 
I think it is less of an effort to compose a set of custom messages than to dig into the CANopen source. 
Only a very small set of messages is needed for the drivetrain.


----------



## jhuebner (Apr 30, 2010)

No its simple if you limit it to the basics. 
For example splitting the 11-bit ID into function code and nodeid:





Function code Node ID 
Length 4 bits 7 bits

Getting and setting parameters via SDO (Function code 0x600)

Byte 1 Byte 2-3 Byte 4 Byte 5-8 
3 bits 1 bit 2 bits 1 bit 1 bit 2 bytes 1 byte 4 bytes
ccs=1 reserved(=0) n e s index subindex data
Byte 1 looks complex but for getting/setting 32-bit values it's trivial. 0x40: write, 0x22 read. You can use index or subindex for addressing the parameter.

And PDO does not even define a fixed data structure, only the function codes.

There are standardized device profiles that exactly describe where to find data. And other good stuff. It's just an encouragement to not reinvent the wheel.

EDIT: formatting did not survive... Found here: https://en.wikipedia.org/wiki/CANopen


----------



## Tony Bogs (Apr 12, 2014)

CANBUS is really simple. Takes care of almost everything. Like a wheel. If you spin, it stays upright. 

So no need for for a complex HLP like CANopen. Adds a lot of unnecessary overhead. 
CANopen is a layer on top of CANBUS to accomodate large industrial networks. 
Has nothing to do with the roots of CANBUS in automotive.

In fact it is like designing a controller with a lot of external wiring. Not done (uncommon practice) since the 90s.

I'm sticking with a custom set of messages. Done in a few hours.


----------



## Tony Bogs (Apr 12, 2014)

Allright, let's design and build an inverter. And we'll start with some inexpensive short circuit rated ISOPLUS247 soft punch through IGBTs: IXYS IXA37I1200HJ. 
Yes, IGBTs for now. They are not very expensive to blow up. Less than US$10 a piece.
And of course, I'll protect them against dI/dt breakdown at turn-off with mosfets in parallel.

I'm going to need an inverter for the motor that drives the mechanically driven auxiliary systems like the pumps for the airconditioning and power steering.
Air cooled, probably a car fan for the AC radiator on top.
I already have the coolers. Size 10x20 cm, 10mm bas plate, 30mm fins, one for the hi side and one for the lo side.
Not with those thin fins since Semikron and others indicate that they are dust collectors.


----------



## Tony Bogs (Apr 12, 2014)

EXCELLENT NEWS. AFAIK TESLA IS THE FIRST WITH SIC IN A SERIES PRODUCED CAR, MODEL III. 

One of the motors in an AWD model is an ACIM. 
Now it's a waiting game for the first autopilot totals to hit the scrapyard.

https://insideevs.com/tesla-model-3-dual-motor-and-performance-versions-revealed/

Looks like I can use the two coolers in the previous post for my senior EV build. One for the mosfet and the other for the freewheel diode.

More great news: Johannes is adding CAN IO to his homebrew controller. Thumbs up!


----------



## Tony Bogs (Apr 12, 2014)

GREAT! More than 50K model III delivered in the last quarter. 

I'm sure quite a few of them are the dual motor version with the SiC hardware and an ACIM.
So it's time to blow away the dust from the MEGA64 diagram and modify it so it can be used with the latest pre- and discharge circuits in https://www.diyelectriccar.com/foru...ic-precharge-controller-discretes-198359.html

I'll implement slip control since it is the most efficient way to drive an ACIM and I certainly don't want a huge battery pack.


----------



## Tony Bogs (Apr 12, 2014)

Looks like it will be an all hardware controller.


----------



## Tony Bogs (Apr 12, 2014)

No, seriously. This has been clear since day one: the usual CANBUS topology for cars will be used. Lots of dedicated, inexpensive uC on the bus.
We need a controller in the (duino) DIY zone. So no changes here: ATMEGA32/64M1. 

Just giving a little kick to this thread. So y'all know it is still alive.

It's a waiting game. Model III SiC drivetrain and next gen battery tech: solid state.
You know, solid state: safe, less expensive, wide operating temp range. And on top of all that: it only needs a basic BMS setup. 
Looks like this one (Prologium, Taiwan) is going to be the first in a production car. Maybe next year (NIO ES3?).
NEWS: Several EU car makers and Chinese startup NIO are testing these battery packs. Right now! Great!

https://tech-papyrus.blogspot.com/2018/12/prologiums-solid-state-battery-won-ces.html
https://www.youtube.com/watch?v=plTeGaP3a04
https://insideevs.com/news/367082/prologium-nio-solid-state-batteries/


I'll send the design of the ATMEGAxxM1 board to the foundry for PCBA service (includes assembly) as soon as I have some spare time. Maybe early next year. 

Then the software bit can start. It's all out there. Just has to glued together.


----------



## Tony Bogs (Apr 12, 2014)

Here's the teaser image of the first CANBUS board design for a Tesla front drivetrain (model S).
Isn't basic beautiful?


----------



## Tony Bogs (Apr 12, 2014)

With CANBUS one can try to reduce the total length of wiring in a car.
The first I/O satellite board design had too much I/O in a single location. 
It had to be split up. 

INSTRUMENT CLUSTER
So here's the next CANBUS teaser. This duino compatible board goes behind the instrument cluster.
Outputs pseudo (i.e. filtered PWM) analog to the legacy instrument cluster: speedo, revcounter, fuel, temperature and boost.
Yeah, that includes the ancient turbo boost needle. 
Other I/O close by for instance: BRAKE (pedal), DRIVE, REVERSE, THROTTLE. And specific EV: PRECHARGE and MAIN CONTACTOR relay driver outputs.

DISPLAY MODULE
Damien Maguire (Jackbauer) made his version of a CANBUS display module a couple of years ago: https://www.diyelectriccar.com/forums/showthread.php/can-bus-lcd-displays-178585.html
Something similar can replace the ICE version that is usually found somewhere in a central position in the dash.

Aren't those duino compatible boards great?


----------



## Tony Bogs (Apr 12, 2014)

Delphi is ready for VW/Porsche/Audi (?) and the next ten years: 800V SiC inverter in an EV package:

https://insideevs.com/news/371247/delphi-800v-sic-inverter/

Such a nice, tidy, little grey box. Does it need liquid cooling? No visible signs of it in the picture.

I've done the prep bits for my 10kW DIY power stage (for instance evaluation of the alu pcbs in the precharge circuit thread) . 

It takes a little bit of programming and testing before I can move on to 100kW+. 



And there's no sign of SiC inverters on the scrap yard yet.


----------



## HighHopes (May 29, 2013)

i've designed SiC inverters, the first one was in 2007 with IGBT + SiC diode, was 540Vdc, 50kw for motor drive application. that was expensive back then. i had access to a fully military qualified lab (bench test, EMI chambers, shake & bake, pcb assembly, you name it, we had it). and a near infinite budget too.... 

going high in switching frequency, higher than 21kHz, is only useful in certain applications. for your typical motor drive in an electric vehicle.. with no AC output filter .. what's the point? standard Si can do 21kHz no problem, be it mosfet or igbt. if you go high in switching frequecy you will generate a lot of low frequency harmonics which creates a new problem you were not anticipating and takes away from the advantages you were seeking. yes you can solve this in firmware but you lose DC bus utilization. i solved it in hardware (patented) without lose of bus utilization which was nice. 

personally, for typical EV application, i'd rather have lower loses that SiC offers and thus allow more amps through to get the same average temperature. you're still going to need a heatsink either way.

gate driver is no problem, and also desaturation protection in the standard way is no problem IF you chose your gate driver IC carefully and spend time on the bench to tune it.

so at the end of the day.. you spend 3x the $ to get SiC mosfet which is LESS reliable than Si IGBT (bad for EV application) and you get what benefit? slightly smaller packaging... that's cool. but is it ultimately really needed in an EV? you have lots of room there... 

$0.02


----------



## Tony Bogs (Apr 12, 2014)

Yeah, 2007. Great year. IGBT or SiC mosfet?
I never liked IGBTs with their tail bump, high losses, big snubbers (high dV/dt at turn-off, IGBTs have a built-in serial killer). 

There are big advantages attached to an output filter if you're going to use a "standard" (DIY) ACIM. 

Why 50 kHz: much smaller filter, low phase inductances of low voltage high power motors, less wear and tear on insulation and bearings with a filter. 
Not so long ago, a member here had some serious issues with a low switching frequency in a Tesla drivetrain. 

EMI, climate chamber: hey, this is a DIY forum. Let's aim for compliance by design.

What do the pros indicate? Well, Tesla has already moved on to SiC mosfets in the model III. Or Musk has given the green light for it. 

VW is ahead of Tesla on the voltage: Porsche Taycan 800V, higher phase inductances, lower I^2R losses, faster charging ... 

Five years later since my first post, maybe 20 kHz is OK now for 800V.





BACK to programming. 

Wow, this bit banging of a dedicated uC works fast. 
No overhead of schedulers, interproces pipes, semaphores and issues with latency. 
Certainly less than 10 pages of code (with comments).


----------



## Tony Bogs (Apr 12, 2014)

Here's an image of the SiC mosfets in this piece about the new Tesla SiC inverter.
Not in the DIY zonee. Cu ribbon bonding, plastic molding .. 

And nowhere to be found on the shelf in the scrap yard.


https://www.pntpower.com/tesla-model-3-powered-by-st-microelectronics-sic-mosfets/


----------



## Tony Bogs (Apr 12, 2014)

No more details about my projects from now on. New privacy policy here. 

KiCAD has improved. Version 5 is more user friendly. 

IGBT and DC are still dominant here but really: it is technology from the EV-1 period.


No worries, I've taken you back there in a few threads. It has been a lot of fun.


----------



## Tony Bogs (Apr 12, 2014)

*INEXPENSIVE motor controller basics. BOGS style.*

1. No PID and no torque control. Why not? For a PID and torque control you have to set control and motor parameters correctly. 
That approach creates a lot of overhead, especially in software, when a controller is supposed to be "universal". 
Motor parameters not set correctly? BOOM! or best case scenario: OVERCURRENT FAULT.
In my motor controller designs the driver is part of the control loop.
Have a look at my hardware DC and ACIM controller circuits. 
Just hit the throttle and away you go. That is DIY IMHO.
No need to set a dozen parameters (or more) via a web interface or even worse: a serial terminal.

*You are the driver and you provide the feedback path for speed and acceleration.* 

So 2. No need for a web interface or serial interface (WiFi, RS232: whooaaa!, really?) 
Throttle stuff etc. is handled in the dedicated I/O controller.
Those system parameters (like type of throttle) can be set via a touch display unit. 
Very easy to get that up and running with a cheap duino board.
And so here's:

3. CANBUS topology. Car system design basics. Implies many dedicated inexpensive controller circuits.
You can even hook up reverse engineered auxiliary units from the scrapyard. Charger units for instance. 
ARM processors? Digital signal processors? (Embedded) programmers love them. 
But hey, this is not IT (WHAT????! USB and ethernet in a motor controller??, you're kidding, right?) project
and not an industrial automation project (so no CANopen).

4. This is a SiC project, but it is possible to use those old 600A+ IGBT bricks again. 
Recycling is great. But you do need a different gate driver and cooling system design.


----------



## Tony Bogs (Apr 12, 2014)

A SCRAPYARD build with Tesla parts has become very popular recently.

Here is a teaser image of the ACIM controller hardware that is needed for a Tesla model S front or rear drive unit
as an inexpensive controller board replacement. 

This board is the ACIM version of my inexpensive DC controller design, but with a little bit extra: CANBUS!
A tiny 8 bit controller has all the hardware stuff on board, but the Tesla drive units do have an awful lot of NTC thermistors. 
So one extra piece of hardware has been addded: an analog multiplexer (US$ 0,50). 

- full hardware (hardwired) desaturation power stage protection 
- full (power) overload protection provided by a single current sensor on DC bus.
No interface hardware needed, no special construction: 
inexpensive LEM sensor directly connected to uC via simple passive network.
- full status information via very inexpensive duino based CANBUS display module

I'll let you know where you can find the details as soon as possible, 
but I want to be the first to build it. So no details yet!


----------



## Tony Bogs (Apr 12, 2014)

Cascode SiC JFETS are now available. They are short circuit rated for eight microseconds. The build can start. Please see update in first post.


----------



## Stevem08 (Jan 9, 2019)

Tony Bogs said:


> voltage?
> A: The ACPL-332J optocoupler's isolation


----------



## Solarsail (Jul 22, 2017)

Stevem08 said:


> .





Tony Bogs said:


> .


Hi Tony and Steve and anyone else active on this thread. This thread seems to be one of the few alive on this forum on controllers. I am having difficulty finding a commercial controller for the Emrax 188/208 PMAC. I need 250V and about 125A continuous. Since this is a multirotor airplane application weight is critical. I can only find heavy EV controllers rated at 400V 200A cont, and weighing 8 kg or more.

Would you recommend a DIY homebrew for this project? If so, where do I start? Any pointers or advice is greatly appreciated.

Than you so much.


----------



## remy_martian (Feb 4, 2019)

What's the gate driver du jour, given this thread's links on the ones bandied about for SiC have expired?

And, of course, any further details on the ACIM's & instrument panel generic's designs? Squarematics (sic) would be nice.

thanks!


----------



## Tony Bogs (Apr 12, 2014)

@Stevem08: The working isolation voltage can be found in the datasheet. 
@Solarsail: I'd recommend my design. Coming soon. Suitable SiC devices are available and there is progress on the controller HW and software front. 
Not just another homebrew inverter (I'm a BSEE system designer), but part of a CANBUS conversion kit. 
Images of the first KiCAD renderings of the MCP ATMEGA32M1 and TI ISO1050DW CANdriver prototype boards will be posted very soon in my "inexpensive AC controller" thread. 
OK, both threads are sort of merging, so here they are in the attachments.

First image shows KiCAD rendering of the prototype PCB for an isolated Rapberry Pi CANBUS interface. 
Based on MCP2515 and ISO1050DW. The big DIP is actually a SSOP to DIP piggyback PCB for the MCP2515.

The interface circuit uses the GPIO hardware PWM0 as clock signal for the isolated power supply.
The second image shows the wiringpi gpio utility based shell script that starts the power supply.

The third image show the KiCAD rendering of the ATMEGA32M1 prototype PCB. The 32M1 is on a TFQP32 to DIP piggyback PCB in the centre.
These boards are very important for all my projects. They add (isolated) CANBUS connectivity and uC control. 

Both boards have been built and are up and running. Wireshark is used on the Pi to capture CAN communication.

@remy_martian: The cascode JFETS _should_ work just fine with the current gate driver designs. 
Actually, even much better: they have a fourth kelvin pin and much they are easier to drive (higher gate resistor values).


----------



## Solarsail (Jul 22, 2017)

Tony Bogs said:


> I'd recommend my design. Coming soon. Suitable SiC devices are available and there is progress on the controller HW and software front.


Sounds great. Can't wait to learn about your project. I'll check your thread.

600V would be nice but 420Vmax is good too. 150Acont I would need. 200Acont even better. Water cooling is OK. Supply is 28V. Resolver/encoder good too.

Running 4 rotors 40kW each. So need 4 of everything.

Thanks


----------



## remy_martian (Feb 4, 2019)

Nobody makes 420V transistors. 600V, then 1200V.

Lots of repurposing of salvage inverters these days, up to 600V which can be had for the cost of the power transistors themselves, or less, and they have the caps and cooling circuit.

Has the world blown past this homebrew effort, as with many of us left holding the bag with $5,000 traction motors when you can buy a motor now for $1,000 with gearbox?

Maybe you should move up to 1200V devices and enable _up to_ 800V packs? That is something that's rare and worth building from scratch, imo.


----------



## Tony Bogs (Apr 12, 2014)

Well, my contributions here have been all about evaluating circuits for DIY conversions. For my personal use.
And having some fun doing it. Blowing up a few mosfets, trying out active filters in an all hardware design are a few examples.
A thyristor based precharge circuit is nothing more than just a bit of "back to the 70s" fun.

But 800V is definitely the way to go. And CANbus of course. There's no way around CAN. Proven reliable communication is essential. As many DIY salvage yard visitors have found out.

My system design: CANbus backbone with multiple cheap and easy to program automotive grade micro-controllers. I have selected the ATMEGA32M1. 
I'm not going to do FOC for ACIMs, but it is feasible with three ATMEGA32M1 devices. Now I need two. One handles the low frequency stuff ( for instance thermistors).
The other one generates the high frequency gate drive signals. The KiCAD schematic is ready. A rendering of the prototype PCB can be found here in a couple of weeks. 

In my other "inexpensive ACIM controller" thread there's an image of the two uC PCB for a popular scrapyard ACIM drivetrain.


----------



## Tony Bogs (Apr 12, 2014)

Dev PCB layout powestage controller is ready. Rendering is in the attachment. Software: just finished customizing Optiboot for CAN flashing of the atmega32m1 using avrdude. 
@Solarsail. 400V means: 40kW is like a "walk in the park". Supports for encoder up to 32 pulses per rev per channel (SW framework ready). Water cooled. 
@remy_martian: Basic config for the instrument panel: 2.8" touchscreens.The VMA412 has a -40 to 85C temp range. Wireless link to a tablet is possible.


----------



## Tony Bogs (Apr 12, 2014)

The powerstage uC dev board has been built and it is generating the desired PWM modulated saddle waves. 
Verified with MAX7409 active filters at the PWM outputs.


----------



## Tony Bogs (Apr 12, 2014)

Schematic of the can to instrument/panel display. Old gauges (speedo, rev counter, temp, turbo, fuel) can be re-used. Arduino compatible as custom Canduino board (pin/port mapping in image).

Edit: Posted diagrams too early. Several design issues were found. Mainly Arduino pin compatibility and power supply (L / C ratings and values).


----------



## Tony Bogs (Apr 12, 2014)

Here's the KiCAD rendering of the built instrument panel dev board to complete the set of four controller dev boards.
The images posted here do not refelect the boards as they have been built. 
Some tracks are wider, parts have been moved, copper areas have been added etc.

But now the SiC HV laminated busbar design can be designed and built.
Always six TO247-4L mosfets. Package current limit is 110Arms. This means that 100kW+ can be achieved at 800V DC bus.


----------



## Tony Bogs (Apr 12, 2014)

ICE EMULATION module

Yep, that's right. The easiest and most efficient way to convert an ICE vehicle with a lot of modern electronics (read: micro-controllers) is emulating the ICE.
I certainly don't want to be limited to converting 30 to 50 year old "breaker point" cars.

My conversion kit has 4 micro-controllers. One of them runs the emulation software. For petrol engines. Turbochargers are supported. 🙂

The COVID-19 lock-down measures provide the ideal circumstances for software development. 
A major part of the emulation software is ready: the airflow / manifold pressure calculations.


----------



## remy_martian (Feb 4, 2019)

Yup - that's what the world wants in an EV...built in hesitation when the accelerator gets pressed, gradual increase in torque until it hits 4,000rpm, unbalanced missing phase power ("misfire"), stalling now and then, randomly refusing to start in cold weather, making random noises, dumping massive power into the stator to make the coolant overheat & vent the radiator cap, and opening a servo valve proportional to distance driven to drip gearbox oil on the floor 😂


----------



## Tony Bogs (Apr 12, 2014)

remy_martian said:


> Yup - that's what the world wants in an EV...built in hesitation when the accelerator gets pressed, gradual increase in torque until it hits 4,000rpm, unbalanced missing phase power ("misfire"), stalling now and then, randomly refusing to start in cold weather, making random noises, dumping massive power into the stator to make the coolant overheat & vent the radiator cap, and opening a servo valve proportional to distance driven to drip gearbox oil on the floor 😂


Too bad you didn't get it this time.... but virtually you're partially right. The virtual ICE doesn't have leaky valves, torque is almost instant and there's no turbo lag. 
Virtually misfires can happen but they do not affect performance and they do not throw a Check Engine. 
Emulation is solely done to keep the existing controllers doing all but control the engine.


----------



## Tony Bogs (Apr 12, 2014)

Since 2007 I have built several experimental circuits to try out control methods and DIY designs. For instance LLC circuits.

Here's a screenshot of the FINAL LTSPICE simulation of the multi branch LLC, current mode, primary side uC controlled isolated gate power supplies for the SiC 800V inverter hardware.

This circuit will be built soon. Widely available common mode filter chokes can be used as transformers.


----------



## Tony Bogs (Apr 12, 2014)

SiC cascode FET inverter in the LTSPICE world ...


----------



## Tony Bogs (Apr 12, 2014)

And the walk in the park has begun ... Here's an image of one of the many, many steps.
Looks like the UnitedSiC models steer the designer towards -5/12.9 V gate drive. 
LTSPICE convergence issues with lower values.

Industry trend is still: go with 800V and SiC fets. 

The new Hyundai IONIQ5 is 800V. 
Great styling, excellent value for money. Beats Tesla III/Y IMHO.


----------



## Tony Bogs (Apr 12, 2014)

@remy_martian:

SiC is easy to drive. Basic schematic below.
The ADuM is automotive grade, 3nsec channel-to-channel, 100kV/usec transient CM


----------



## Tony Bogs (Apr 12, 2014)

The power supply extension for the + in 100kW+ in the LTSPICE world


----------



## Tony Bogs (Apr 12, 2014)

@remy_martian: KiCAD Squarematic  of the 350 to 800V cascode 100kW+ inverter.

Yep, this means that the design is done. It is the result of seven years sharing DIY approaches and experimental circuits.
Some results: LLC power supply in current mode with post shunt regulation, cascode SiC for hard switching.








AGAIN: this schematic is only indicative of the final result. Details may change and can be found elsewhere online soon. 
Example: Two IXYS604 devices in stead of one to prevent shoot through currents in the mosfet LLC out stages of the LLC.
Compliance LT1720 fast comparator will be replaced with automotive grade TS3011IYDT in the final result.


----------



## MattsAwesomeStuff (Aug 10, 2017)

Hurray, progress.

I think Damien actually used an earlier design of yours in his Red Arrow budget build.


----------



## Tony Bogs (Apr 12, 2014)

Sure. Making the world a little better is a serious matter.

Kelvin and LV/HV signal isolation: automotive grade ADuM 241/242E0. CANBUS, gate signals, fault....
Mosfets in parallel: timing is critical. I'm using a FPGA for it. 
For now (development phase): LATTICE ICE40 HX8K on a Sparkfun Alchitry Cu. Reason: there's an open source toolkit for it.
Later on the verilog design will be ported to an automotive grade FPGA.
With a FPGA the ATmega32M1 has enough throughput for the remaining tasks: CANBUS, SPI link to FPGA, PWM.
Selected mosfet driver: Texas Instruments UCC27519AQDBVRQ1, Fast, automotive grade, inexpensive, both TTL and CMOS level inputs.

ALL PARTS ARE AUTOMOTIVE GRADE in the final design. DISCRETES, FOR EXAMPLE: Nexperia PMV37ENEA trench mosfet.

This project is NOT cheap, NOT inexpensive and @100kW+ is certainly NOT a walk in the park. 
1. But a 400V, 40kW air cooled inverter IS. 40kW, 400V doesn't need mosfets in parallel.
2. The 350 to 800V 100kW+ design does need it. Supports up to 8 mosfets in parallel. 
3. 110A is the current limit of the TO247-4 package, but it is NOT achievable in a 800V, 100kW+ system. Thermal limits.
4. 30 (air cooled) to 40Arms (liquid) is the limit per mosfet @800V.
5. The existing gate driver circuits for IGBT and SI/SiC mosfets won't work for 800V high amp devices in parallel @ 100kW+. 

Ultimately, the inexpensive all hardware controller project is also a FPGA project. Just for the record.


----------



## Tony Bogs (Apr 12, 2014)

OK, here's the gate driver circuit for parallel operation at 800V, 100kW+. DON'T USE THIS IN A BUILD UNLESS YOU ARE A TRAINED PROFESSIONAL.







NO REALLY: DON'T.


----------



## Tony Bogs (Apr 12, 2014)

Please keep in mind that this is a project in progress. Turns out the ADuM241E0 is not available as an automotive qualified part.
So here's the next version for KELVIN ISOLATION.


----------



## Tony Bogs (Apr 12, 2014)

The pulse transformer has been dropped. No longer needed. 
Solved with the aid of LTSPICE and signal rerouting via the FPGA. 

So here's version 2. Also: minor change in PS/UVLO. Wiring OOPS.








Please keep in mind that this a SIC project in the development phase.

DO NOT APPLY THE CIRCUITS IN THIS THREAD TO IGBT BUILDS. 
NO, REALLY, DON'T.


----------



## Tony Bogs (Apr 12, 2014)

Progress report. Much earlier I introduced SPI in this thread and other projects. SPI is great for implementation in a FPGA.
The ICE40 HX comes with SPI on-chip. Here's the FPGA squarematic with supporting circuits. It is a copy of one of the 80 KiCAD project sheets (squarematics).
DON'T USE THESE CIRCUITS YET!! NO, REALLY, DON'T. In development.


----------

