|  | Dual Active Bridge Development Board (Part-No. ) |
Content |  |  |  |  |  |

Loading...
Searching...
No Matches
Conversion Macros
Configuration Layer » PWM Settings

Conversion macros for user declarations of PWM peripheral. More...

Collaboration diagram for Conversion Macros:

#define | PWM_CLOCK_PERIOD (float)(1.0 / PWM_CLOCK_FREQUENCY)
| Conversion macros for user-declarations of PWM parameters.
#define | MAX_SWITCHING_PERIOD (float)(1.0/MINIMUM_SWITCHING_FREQUENCY)
| Switching period in [sec].
#define | MIN_SWITCHING_PERIOD (float)(1.0/MAXIMUM_SWITCHING_FREQUENCY)
| Switching period in [sec].
#define | MAX_PWM_PERIOD (uint16_t)(float)(MAX_SWITCHING_PERIOD / PWM_CLOCK_PERIOD)
| This sets the switching period of the converter.
#define | MIN_PWM_PERIOD (uint16_t)(float)(MIN_SWITCHING_PERIOD / PWM_CLOCK_PERIOD)
| This sets the switching period of the converter.
#define | PERIOD_RANGE (uint16_t)(MAX_PWM_PERIOD - MIN_PWM_PERIOD)
| This is the calculation of Period range. NOTE: only use in Debugging moode using digital power development board.
#define | ADC_PERIOD_RANGE (uint16_t)(float)(PERIOD_RANGE / ADC_RESOLUTION)
| This is the calculation for ADC equivalent with Period range. NOTE: only use in Debugging moode using digital power development board.
#define | MIN_PWM_DEAD_TIME (uint16_t)(MINIMUM_DEADTIME / (float)PWM_CLOCK_PERIOD)
| Minimum dead time [tick = 250ps].
#define | MAX_PWM_DEAD_TIME (uint16_t)(MAXIMUM_DEADTIME / (float)PWM_CLOCK_PERIOD)
| Maximum dead time [tick = 250ps].
#define | MIN_PHASE_SHIFTED_PULSE (uint16_t)(MINIMUM_PHASESHIFTED_PULSE / (float)PWM_CLOCK_PERIOD)
| Maximum dead time [tick = 250ps].
#define | DEGREES_PHASE_10x (10u)
#define | DEGREES_PHASE_SCALER (10u)
#define | DEGREES_PHASE_SCALING_10 ((pow(2.0, DEGREES_PHASE_SCALER)) / DEGREES_PHASE_10x)
#define | DEGREES_PHASE_FACTOR ((PRI_TO_SEC_PHASE_DEGREES_LIMIT * ((DEGREES_PHASE_SCALER)* DEGREES_PHASE_10x)))

## Detailed Description

These conversion macros are used to convert user settings defined as physical quantities into binary (integer) numbers, which will be written to registers and variables and used in calculations throughout the firmware.

## Macro Definition Documentation

## ◆ ADC_PERIOD_RANGE

#define ADC_PERIOD_RANGE (uint16_t)(float)(PERIOD_RANGE / ADC_RESOLUTION)

Definition at line 43 of file macros.h.

## ◆ DEGREES_PHASE_10x

#define DEGREES_PHASE_10x (10u)

Definition at line 54 of file macros.h.

## ◆ DEGREES_PHASE_FACTOR

#define DEGREES_PHASE_FACTOR ((PRI_TO_SEC_PHASE_DEGREES_LIMIT * ((DEGREES_PHASE_SCALER)* DEGREES_PHASE_10x)))

Definition at line 57 of file macros.h.

## ◆ DEGREES_PHASE_SCALER

#define DEGREES_PHASE_SCALER (10u)

Definition at line 55 of file macros.h.

## ◆ DEGREES_PHASE_SCALING_10

#define DEGREES_PHASE_SCALING_10 ((pow(2.0, DEGREES_PHASE_SCALER)) / DEGREES_PHASE_10x)

Definition at line 56 of file macros.h.

## ◆ MAX_PWM_DEAD_TIME

#define MAX_PWM_DEAD_TIME (uint16_t)(MAXIMUM_DEADTIME / (float)PWM_CLOCK_PERIOD)

Definition at line 50 of file macros.h.

## ◆ MAX_PWM_PERIOD

#define MAX_PWM_PERIOD (uint16_t)(float)(MAX_SWITCHING_PERIOD / PWM_CLOCK_PERIOD)

Definition at line 40 of file macros.h.

## ◆ MAX_SWITCHING_PERIOD

#define MAX_SWITCHING_PERIOD (float)(1.0/MINIMUM_SWITCHING_FREQUENCY)

Definition at line 38 of file macros.h.

## ◆ MIN_PHASE_SHIFTED_PULSE

#define MIN_PHASE_SHIFTED_PULSE (uint16_t)(MINIMUM_PHASESHIFTED_PULSE / (float)PWM_CLOCK_PERIOD)

Definition at line 52 of file macros.h.

## ◆ MIN_PWM_DEAD_TIME

#define MIN_PWM_DEAD_TIME (uint16_t)(MINIMUM_DEADTIME / (float)PWM_CLOCK_PERIOD)

Definition at line 49 of file macros.h.

## ◆ MIN_PWM_PERIOD

#define MIN_PWM_PERIOD (uint16_t)(float)(MIN_SWITCHING_PERIOD / PWM_CLOCK_PERIOD)

Definition at line 41 of file macros.h.

## ◆ MIN_SWITCHING_PERIOD

#define MIN_SWITCHING_PERIOD (float)(1.0/MAXIMUM_SWITCHING_FREQUENCY)

Definition at line 39 of file macros.h.

## ◆ PERIOD_RANGE

#define PERIOD_RANGE (uint16_t)(MAX_PWM_PERIOD - MIN_PWM_PERIOD)

Definition at line 42 of file macros.h.

## ◆ PWM_CLOCK_PERIOD

#define PWM_CLOCK_PERIOD (float)(1.0 / PWM_CLOCK_FREQUENCY)

These conversion macros are used to convert user settings defined as physical quantities into binary (integer) numbers, which will be written to registers and variables and used in calculations throughout the firmware. PWM Clock Period in [sec]

Definition at line 37 of file macros.h.