|
3.3kW Totem-pole PFC with CoolMOS and XMC1402
|
Communication code. More...
#include "xmc_flash.h"Go to the source code of this file.
Data Structures | |
| union | msg_t |
| struct | params_t |
Macros | |
| #define | MASTER_KEY (1) |
| #define | UART_TRANSMIT_CLK_DIV (2) |
Converter ID | |
| #define | CONVERTER (5) |
| #define | VERSION_BITS (8) |
| #define | VERSION (1) |
| #define | SUB_VERSION (0) |
Serial communication commands | |
Communication blocks of 3 bytes. 1 byte command, 2 bytes payload. |----------—|----------—|----------—|----------—|----------—| 0x55 CMD DATA_0 DATA_1 CRC | |
| #define | UART_WRITE_MSK (0x00) |
| #define | UART_SAVE (0x06) |
| #define | UART_READ (0x80) |
| #define | UART_STATUS_S (0x04) |
| #define | SOFT_VER (0x25) |
| #define | CONVERTER_ID (0x26) |
| #define | UART_DT_D2S (0x34) |
| #define | UART_DT_S2D_MAX (0x35) |
| #define | UART_DT_S2D_MIN (0x36) |
| #define | UART_CONST_I (0x37) |
| #define | UART_OFF_REG1 (0x38) |
| #define | UART_SLOPE_REG1 (0x39) |
| #define | UART_REG1_I (0x40) |
| #define | UART_OFF_REG2 (0x41) |
| #define | UART_SLOPE_REG2 (0x42) |
| #define | UART_REG2_I (0x43) |
| #define | UART_POWER (0x44) |
Serial communication payloads | |
Metering of output voltage. Metering of output current. Metering of input voltage. Metering of input current. Version of software. Converter identifier. NTC temperature. Die temperature. Buck-Boost mode operation. Communication blocks of 3 bytes. 1 byte command, 2 bytes payload. |----------—|----------—|----------—|----------—|----------—| 0x55 CMD DATA_0 DATA_1 CRC | |
| #define | UART_ON_OFF_START (0x8080) |
| #define | UART_ON_OFF_STOP (0x0101) |
| #define | UART_BOOST_MODE (0x8080) |
| #define | UART_BUCK_MODE (0x0101) |
Functions | |
| uint32_t | XMC_USIC_CH_TXFIFO_GetLevel (XMC_USIC_CH_t *const channel) |
| void | uart_transmit () |
| UART transmit data. More... | |
| void | uart_receive () |
| UART receive data. More... | |
| void | load_ROM_parameters () |
| Copy parameters from ROM into an intermediate RAM area. NOT USED IN THIS SW VERSION; DEAD TIME SET IN iL_deadtime() FUNCTION. More... | |
| void | check_RAM_parameters () |
| Check that parameters in RAM are insight of a valid range. More... | |
Variables | |
| const params_t * | parameters_ROM |
| const params_t | parameters_DFLT |
| params_t | parameters_RAM |
Communication code.