Bar Logo Dual Active Bridge Development Board (Part-No. )
 
Content
     
Loading...
Searching...
No Matches

Conversion macros for user-declarations of Primary Voltage Feedback parameters. More...

+ Collaboration diagram for Conversion Macros:
#define VPRI_OV_THRES_TRIG   (UNITS_FROM_ENG_TO_ADC(VPRI_OV_THRES_TRIG_VOLTS,VPRI_SNS_GAIN,VPRI_SNS_OFS))
 
#define VPRI_OV_THRES_CLEAR   (UNITS_FROM_ENG_TO_ADC(VPRI_OV_THRES_CLEAR_VOLTS,VPRI_SNS_GAIN,VPRI_SNS_OFS))
 
#define VPRI_OV_T_BLANK_TRIG   ((uint16_t)(_rnd(VPRI_OV_T_BLANK_TRIG_SEC / VSEC_OV_TICK_SEC)))
 
#define VPRI_OV_T_BLANK_CLEAR   ((uint16_t)(_rnd(VPRI_OV_T_BLANK_CLEAR_SEC / VSEC_OV_TICK_SEC)))
 
#define VPRI_UV_THRES_TRIG   (UNITS_FROM_ENG_TO_ADC(VPRI_UV_THRES_TRIG_VOLTS,VPRI_SNS_GAIN,VPRI_SNS_OFS))
 
#define VPRI_UV_THRES_CLEAR   (UNITS_FROM_ENG_TO_ADC(VPRI_UV_THRES_CLEAR_VOLTS,VPRI_SNS_GAIN,VPRI_SNS_OFS))
 
#define VPRI_UV_T_BLANK_TRIG   ((uint16_t)(_rnd(VPRI_UV_T_BLANK_TRIG_SEC / VSEC_UV_TICK_SEC)))
 
#define VPRI_UV_T_BLANK_CLEAR   ((uint16_t)(_rnd(VPRI_UV_T_BLANK_CLEAR_SEC / VSEC_UV_TICK_SEC)))
 
#define VPRIM_LOAD_STEP_CLAMP   (UNITS_FROM_ENG_TO_ADC( VPRIM_LOAD_STEP_CLAMPING_VOLTS,VPRI_SNS_GAIN,0.0))
 
#define VPRI_SCALER   (10u)
 
#define VPRI_FACTOR   (uint16_t)((1 / VPRI_VOLTAGE_GAIN) * VPRI_SCALER)
 

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

◆ VPRI_FACTOR

#define VPRI_FACTOR   (uint16_t)((1 / VPRI_VOLTAGE_GAIN) * VPRI_SCALER)

Definition at line 138 of file macros.h.

◆ VPRI_OV_T_BLANK_CLEAR

#define VPRI_OV_T_BLANK_CLEAR   ((uint16_t)(_rnd(VPRI_OV_T_BLANK_CLEAR_SEC / VSEC_OV_TICK_SEC)))

Definition at line 128 of file macros.h.

◆ VPRI_OV_T_BLANK_TRIG

#define VPRI_OV_T_BLANK_TRIG   ((uint16_t)(_rnd(VPRI_OV_T_BLANK_TRIG_SEC / VSEC_OV_TICK_SEC)))

Definition at line 127 of file macros.h.

◆ VPRI_OV_THRES_CLEAR

Definition at line 126 of file macros.h.

◆ VPRI_OV_THRES_TRIG

Definition at line 125 of file macros.h.

◆ VPRI_SCALER

#define VPRI_SCALER   (10u)

Definition at line 137 of file macros.h.

◆ VPRI_UV_T_BLANK_CLEAR

#define VPRI_UV_T_BLANK_CLEAR   ((uint16_t)(_rnd(VPRI_UV_T_BLANK_CLEAR_SEC / VSEC_UV_TICK_SEC)))

Definition at line 133 of file macros.h.

◆ VPRI_UV_T_BLANK_TRIG

#define VPRI_UV_T_BLANK_TRIG   ((uint16_t)(_rnd(VPRI_UV_T_BLANK_TRIG_SEC / VSEC_UV_TICK_SEC)))

Definition at line 132 of file macros.h.

◆ VPRI_UV_THRES_CLEAR

Definition at line 131 of file macros.h.

◆ VPRI_UV_THRES_TRIG

Definition at line 130 of file macros.h.

◆ VPRIM_LOAD_STEP_CLAMP

#define VPRIM_LOAD_STEP_CLAMP   (UNITS_FROM_ENG_TO_ADC( VPRIM_LOAD_STEP_CLAMPING_VOLTS,VPRI_SNS_GAIN,0.0))

Definition at line 135 of file macros.h.