Menu

Controller Decision Matrix

André S.

On this page all information for possible controllers for the inverter are collected. After listing all the necessary functions a rating for the best suited controller will be done.

For a first rough estimation of the needed computing power some considerations:
If we want to achieve a control loop frequency of 16 kHz and we use a controller with 100 MHz core clock we have 6250 clock cycles to gather all needed (analog) input values, do the calculations and set the outputs. Besides that there may be some serial communication that also needs to be addressed.
The choice of controller clearly sets the limits how fast and how precise the inverter will be able to operate.
It may be possible to use a less performant controller (and save costs) when the first implementation indicates that there is plenty of time to perform all necessary operations.
So a controller family that covers a bigger performance spectrum gets a better rating than a controller that's only available in a single configuration.

Because of the preferred support from FreeRTOS (see [#1]) all listed controllers below must be covered in the list at the FreeRTOS ports list. This also excludes 8-bit controllers.

The ADC resolution must be at least 12 bit. For the AC current the resolution should be as fine as possible to prevent any DC current flowing into the grid. For 10 A max. AC current and 12 bit resolution this would provide a resolution of (20 A_pp)/(2^12)=~5 mA. To allow some headroom the scale will be set higher than 10 A max. With 12 bit this still allows a resolution better than 10 mA. More than 12 bit resolution would be overkill due to the noisy environment inside an inverter and also due to the high dynamic of most of the signals.

The STR7 and STR9 controller families from ST are no fit due to insufficient ADC features.

A list of controllers was assembled from the supplier pages and then limited with prices from digikey. All controllers more expensive than 5 EUR were regarded out of limit for this project.

The whole list can be found in the files section controller-overview.ods.

Following the list of controllers that were left with the applied limits regarding to the requirements:

Manufacturer Device
Name
CPU Frequency
(MHz)
RAM(KB) Flash(KB) PWM(Ch) DMA(Ch) ADC Channels ADC Resolution (Bit) I2C (TWI) UART(SCI) SPI Timers 16 bit Timers 32 bit PWM Channels GPIO IO Supply(V) Package Group Pin Count Digikey Price (€)
ST STM32F030K6 ARM Cortex-M0 48 4 32 6 5 10 12 1 1 1 4 - 27 2.4 - 3.6 LQFP 32 7x7x1.4 32 1.53
ST STM32F030C6 ARM Cortex-M0 48 4 32 6 5 10 12 1 1 1 4 - 39 2.4 - 3.6 LQFP 48 7x7x1.4 48 1.75
ST STM32F030C8 ARM Cortex-M0 48 8 64 6 5 10 12 2 2 2 6 - 39 2.4 - 3.6 LQFP 48 7x7x1.4 48 2.10
ST STM32F030R8 ARM Cortex-M0 48 8 64 6 5 16 12 2 2 2 6 - 55 2.4 - 3.6 LQFP 64 10x10x1.4 64 2.19
ST STM32F100C4 ARM Cortex-M3 24 4 16 6 7 10 12 1 2 1 6 - 37 2 - 3.6 LQFP 48 7x7x1.4 48 3.14
ST STM32F070RB ARM Cortex-M0 48 16 128 6 5 16 12 8 - 51 2.4 - 3.6 LQFP 64 10x10x1.4 64 3.51
Freescale MKV30F64VLH10 ARM Cortex-M4 100 16 64 10 4 29 16 1 4 1 11 4 46 1.71 to 3.6 QFP 64 64 3.81
Freescale MKV30F128VLH10 ARM Cortex-M4 100 16 128 10 4 29 16 1 4 1 11 4 46 1.71 to 3.6 QFP 64 64 4.36
Freescale MKV31F128VLH10 ARM Cortex-M4 100 24 128 12 4 29 16 2 4 2 13 4 46 1.71 to 3.6 QFP 64 64 4.77
NXP LPC11U67 ARM Cortex-M0+ 50 16 128 16 8 12 2 3 2 11 34 2.4-3.6 LQFP48 48 4.78

According to that list two controller families need to be investigated: from ST the STM32F030 family and from Freescale the MKV30F family.

The Freescale controllers offer more RAM and a higher core frequency which may provide more flexibility in the system design.
On the other hand the ST controllers are about half the price and offer smaller packages which may save board space and reduce the whole system costs. But due to the lower CPU performance they may limit the maximum control loop frequency, which then can lead to higher system costs.

Both controller families are supported by FreeRTOS with GCC. The Freescale controllers are according to the side also supported by Eclipse where the ST controllers are only supported by non-free tools.

So for now the design will be aimed to run on a Freescale MKV30F64 controller.


Related

Tickets: #1
Wiki: Electronics and Electrical