Functions | |
| uint32_t | BSP_HRTIM_GetTimerFreq (uint32_t TimerIdx) |
| Gets the clock frequency of the specific timer in MHz. | |
| HRTIM_TimerCfgTypeDef | BSP_HRTIM_GetDefaultTimerConfig (timer_frequency_t f, uint32_t TimerIdx) |
| Gets the default timer configuration for the HRTIM. | |
| HRTIM_CompareCfgTypeDef | BSP_HRTIM_GetDefaultCompareConfig (void) |
| Gets the default compare configuration for the HRTIM. | |
| HRTIM_DeadTimeCfgTypeDef | BSP_HRTIM_GetDefaultDeadtimeConfig (void) |
| Gets the default dead time configuration for the HRTIM. | |
| HRTIM_OutputCfgTypeDef | BSP_HRTIM_GetDefaultOutputConfig (void) |
| Gets the default output configuration for the HRTIM. | |
| IRQn_Type | BSP_HRTIM_GetIRQn (uint32_t TimerIdx) |
| Gets the IRQ for a timer submodule for HRTIM. | |
| void | BSP_HRTIM_Init (void) |
| Initialize the HRTIM. | |
| void | BSP_MasterHRTIM_SetShiftValue (hrtim_comp_t comp, uint32_t value) |
| Configures the compare value for the HRTIM compare unit. This value can be used to reset the HRTIM submodules at required instances. | |
| void | BSP_MasterHRTIM_SetShiftPercent (hrtim_opts_t *opts, hrtim_comp_t comp, float percent) |
| Configures the compare value for the HRTIM compare. Instead of a value user provides a percentage between 0-1; thus specifying the shift in percentage instead of value for easier computation on user end. This value can be used to reset the HRTIM submodules at required instances. | |
| void | BSP_TIM2_ConfigFiberRx (tim_trg_in_type_t slaveType, tim_slave_edge_t slaveEdge, tim_out_trigger_config_t *outTrigger, float _fs) |
| Configures the Fiber/Sync Rx pin to receive the synchronization event via TIM2 module. | |
| void | BSP_TIM3_ConfigFiberTx (tim_in_trigger_config_t *inTrigger, tim_out_trigger_config_t *outTrigger, float _fs) |
| Configures the Fiber/Sync Tx pin to generate a PWM of required frequency. | |
| void | BSP_MasterHRTIM_Config (hrtim_opts_t *opts) |
| Configures the master timer for HRTIM1 module. | |
| void | BSP_TIM3_FiberTxStart (bool startHrtimMaster) |
| Start the generation of PWM for the TIM3 modules (Fiber/Sync Tx) | |
| void | BSP_MasterHRTIM_Start (void) |
| Use this function to start the Master HRTIM. | |
| void | BSP_HRTIM_Config_Interrupt (bool enable, PWMResetCallback callback, int priority) |
| Enable / Disable interrupt for Master HRTIM unit. | |
| void | BSP_Timer_SetInputTrigger (TIM_HandleTypeDef *_htim, tim_in_trigger_config_t *_config) |
| Set the input trigger of a timer to make it a slave of any of the timer_trigger_src_t. | |
| void | BSP_Timer_SetOutputTrigger (TIM_HandleTypeDef *_htim, tim_out_trigger_config_t *_config) |
| Set the output trigger of a timer to make it a slave of any other timer. | |
|
extern |
| enable | If enable interrupt set this parameter to true |
| callback | Specifies the function to be called when the PWM is reset |
| priority | Interrupt priority. Range (0-15). Here 0 is the highest priority |
|
extern |
Default Configuration:
|
extern |
Default Configuration:
|
extern |
Default Configuration:
|
extern |
Default Configuration:
| f | Defines the freuency in Hz. |
| TimerIdx | Index of the timer submodule. |
|
extern |
| TimerIdx | Index of the timer submodule. |
|
extern |
| TimerIdx | Index of the timer submodule. |
| void BSP_HRTIM_Init | ( | void | ) |
Configures the HRTIM with CPU Clock. The following events are configured.
--------— event
|
extern |
The master timer is used as a support timer, which may be used for synchronizing different HRTIM submodules. This timer can only operate as a master and can only be enabled or reset based upon the TIM1 module. Use the BSP_MasterHRTIM_SetShiftValue() and BSP_MasterHRTIM_SetShiftPercent() functions to configure the trigger delays for other timer modules.
| opts | Contains the configuration options for the Master HRTIM. |
|
extern |
| opts | Contains the configuration options for the Master HRTIM. |
| comp | Type of the compare unit. |
| percent | Phase shift in percentage. |
|
extern |
| comp | Type of the compare unit. |
| value | Phase shift value to be fed in the compare unit. |
|
extern |
| slaveType | Control what to do when signal received on the RX pin |
| slaveEdge | Select the rising or falling edge for the RX pin as trigger |
| outTrigger | Output trigger configuration for the timer. Used to synchronize another timer to the RX signal |
| _fs | Required frequency at Fiber/Sync RX Pin |
|
extern |
| inTrigger | Input trigger configuration for the timer. Used to synchronize the TX signal to another trigger/Source |
| outTrigger | Output trigger configuration for the timer. Used to synchronize another timer to the TX signal |
| _fs | Required frequency at Fiber/Sync TX Pin |
|
extern |
| startHrtimMaster | Master HRTIM and TIM3 can also be enabled at the same time via software. To enable this feature pass true in this parameter. |
|
extern |
| _htim | Handle of the timer to be configured. (Make sure to initialize this parameter before this function). |
| _config | Required configuration. If this value is set to NULL the timer will be configured as independent timer. |
|
extern |
| _htim | Handle of the timer to be configured. (Make sure to initialize this parameter before this function). |
| _config | Required configuration for the output trigger. |