Bar Logo 3.8/7.6 kw Totem pole Demonstration Application (Part-No. (not specified))
 
Content
     
Loading...
Searching...
No Matches
pwm_hs_interface.h
1
18/*
19© [2024] Microchip Technology Inc. and its subsidiaries.
20
21 Subject to your compliance with these terms, you may use Microchip
22 software and any derivatives exclusively with Microchip products.
23 You are responsible for complying with 3rd party license terms
24 applicable to your use of 3rd party software (including open source
25 software) that may accompany Microchip software. SOFTWARE IS ?AS IS.?
26 NO WARRANTIES, WHETHER EXPRESS, IMPLIED OR STATUTORY, APPLY TO THIS
27 SOFTWARE, INCLUDING ANY IMPLIED WARRANTIES OF NON-INFRINGEMENT,
28 MERCHANTABILITY, OR FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT
29 WILL MICROCHIP BE LIABLE FOR ANY INDIRECT, SPECIAL, PUNITIVE,
30 INCIDENTAL OR CONSEQUENTIAL LOSS, DAMAGE, COST OR EXPENSE OF ANY
31 KIND WHATSOEVER RELATED TO THE SOFTWARE, HOWEVER CAUSED, EVEN IF
32 MICROCHIP HAS BEEN ADVISED OF THE POSSIBILITY OR THE DAMAGES ARE
33 FORESEEABLE. TO THE FULLEST EXTENT ALLOWED BY LAW, MICROCHIP?S
34 TOTAL LIABILITY ON ALL CLAIMS RELATED TO THE SOFTWARE WILL NOT
35 EXCEED AMOUNT OF FEES, IF ANY, YOU PAID DIRECTLY TO MICROCHIP FOR
36 THIS SOFTWARE.
37*/
38
39#ifndef PWM_HS_INTERFACE_H
40#define PWM_HS_INTERFACE_H
41
42// Section: Included Files
43
44#include <stdbool.h>
45#include <stdint.h>
46#include "pwm_hs_types.h"
47
48// Section: Data Type Definitions
49
57 void (*Initialize)(void);
59
60 void (*Deinitialize)(void);
62
63 void (*Disable)(void);
65
66 void (*Enable)(void);
68
69 void (*MasterPeriodSet)(uint16_t period);
71
72 void (*MasterDutyCycleSet)(uint16_t masterDutyCycle);
74
75 void (*MasterPhaseSet)(uint16_t masterPhase);
77
78 void (*PeriodSet)(enum PWM_GENERATOR genNum, uint16_t period);
80
81 void (*ModeSet)(enum PWM_GENERATOR genNum, enum PWM_MODES mode);
83
84 void (*DutyCycleSet)(enum PWM_GENERATOR genNum, uint16_t dutyCycle);
86
87 void (*PhaseSelect)(enum PWM_GENERATOR genNum, enum PWM_SOURCE_SELECT source);
89
90 void (*PhaseSet)(enum PWM_GENERATOR genNum, uint16_t phase);
92
93 void (*OverrideDataSet)(enum PWM_GENERATOR genNum, uint16_t overrideData);
95
96 void (*OverrideDataHighSet)(enum PWM_GENERATOR genNum, bool overrideDataHigh);
98
99 void (*OverrideDataLowSet)(enum PWM_GENERATOR genNum, bool overrideDataLow);
101
102 uint16_t (*OverrideDataGet)(enum PWM_GENERATOR genNum);
104
105 void (*OverrideHighEnable)(enum PWM_GENERATOR genNum);
107
108 void (*OverrideLowEnable)(enum PWM_GENERATOR genNum);
110
111 void (*OverrideHighDisable)(enum PWM_GENERATOR genNum);
113
114 void (*OverrideLowDisable)(enum PWM_GENERATOR genNum);
116
117 void (*DeadTimeLowSet)(enum PWM_GENERATOR genNum,uint16_t deadtimeLow);
119
120 void (*DeadTimeHighSet)(enum PWM_GENERATOR genNum,uint16_t deadtimeHigh);
122
123 void (*DeadTimeSet)(enum PWM_GENERATOR genNum,uint16_t deadtime);
125
126 void (*TriggerCompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue);
128
131
134
137
140
141 void (*SpecialEventPrimaryCompareValueSet)(uint16_t compareValue);
143
146
149
152
155
158
159 void (*GeneratorDisable)(enum PWM_GENERATOR genNum);
161
162 void (*GeneratorEnable)(enum PWM_GENERATOR genNum);
164
165 void (*TriggerACompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue);
167
168 void (*TriggerBCompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue);
170
171 void (*TriggerCCompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue);
173
176
179
180 void (*FaultModeLatchClear)(enum PWM_GENERATOR genNum);
182
183 void (*Trigger1Enable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister);
185
186 void (*Trigger1Disable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister);
188
189 void (*Trigger2Enable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister);
191
192 void (*Trigger2Disable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister);
194
195 void (*GeneratorEOCEventCallbackRegister)(void (*callback)(enum PWM_GENERATOR genNum));
197
198 void (*CommonEventCallbackRegister)(void (*callback)(enum PWM_COMMON_EVENT event));
200
201 void (*GeneratorTasks)(enum PWM_GENERATOR intGen);
203
206};
207
208#endif //PWM_HS_INTERFACE_H
This is the generated driver types header file for the PWM driver.
PWM_SOURCE_SELECT
PWM_GENERATOR_INTERRUPT
Defines the PWM generator interrupts that are available for the module to use.
PWM_TRIGGER_COMPARE
Defines the PWM generator Trigger Compare registers that are available for the module to use.
PWM_MODES
Defines the PWM generator operating modes that are available.
PWM_GENERATOR
Defines the PWM generators that are selected from the MCC Melody User Interface for the PWM output co...
PWM_COMMON_EVENT
Defines the PWM generator Common Events that are available for the module to use.
Structure containing the function pointers of PWM driver.
void(* DutyCycleSet)(enum PWM_GENERATOR genNum, uint16_t dutyCycle)
Pointer to PWM_DutyCycleSet.
void(* Enable)(void)
Pointer to PWM_Enable.
void(* SpecialEventPrimaryInterruptDisable)(void)
Pointer to PWM_SpecialEventPrimaryInterruptDisable (Defined if PWM_SPECIAL_EVENT_FEATURE_AVAILABLE is...
void(* TriggerCompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue)
Pointer to PWM_TriggerCompareValueSet.
void(* OverrideLowEnable)(enum PWM_GENERATOR genNum)
Pointer to PWM_OverrideLowEnable.
void(* TriggerBCompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue)
Pointer to PWM_TriggerBCompareValueSet (Defined if PWM_MULTIPLE_TRIGGER_FEATURE_AVAILABLE is 1 in PWM...
void(* DeadTimeSet)(enum PWM_GENERATOR genNum, uint16_t deadtime)
Pointer to PWM_DeadTimeSet.
void(* OverrideDataHighSet)(enum PWM_GENERATOR genNum, bool overrideDataHigh)
Pointer to PWM_OverrideDataHighSet.
void(* GeneratorDisable)(enum PWM_GENERATOR genNum)
Pointer to PWM_GeneratorDisable (Defined if PWM_GENERATOR_ENABLE_FEATURE_AVAILABLE is 1 in PWM_featur...
void(* CommonEventTasks)(enum PWM_COMMON_EVENT event)
Pointer to PWM_CommonEventTasks (Supported only in polling mode)
void(* OverrideHighDisable)(enum PWM_GENERATOR genNum)
Pointer to PWM_OverrideHighDisable.
void(* SoftwareUpdateRequest)(enum PWM_GENERATOR genNum)
Pointer to PWM_SoftwareUpdateRequest (Defined if PWM_SOFTWARE_UPDATE_FEATURE_AVAILABLE is 1 in PWM_fe...
void(* OverrideDataSet)(enum PWM_GENERATOR genNum, uint16_t overrideData)
Pointer to PWM_OverrideDataSet.
void(* DeadTimeLowSet)(enum PWM_GENERATOR genNum, uint16_t deadtimeLow)
Pointer to PWM_DeadTimeLowSet.
void(* ModeSet)(enum PWM_GENERATOR genNum, enum PWM_MODES mode)
Pointer to PWM_ModeSet.
void(* GeneratorEventStatusClear)(enum PWM_GENERATOR genNum, enum PWM_GENERATOR_INTERRUPT interrupt)
Pointer to PWM_GeneratorEventStatusClear.
void(* MasterPeriodSet)(uint16_t period)
Pointer to PWM_MasterPeriodSet.
void(* SpecialEventPrimaryCompareValueSet)(uint16_t compareValue)
Pointer to PWM_SpecialEventPrimaryCompareValueSet (Defined if PWM_SPECIAL_EVENT_FEATURE_AVAILABLE is ...
void(* PeriodSet)(enum PWM_GENERATOR genNum, uint16_t period)
Pointer to PWM_PeriodSet.
void(* FaultModeLatchClear)(enum PWM_GENERATOR genNum)
Pointer to PWM_FaultModeLatchClear (Defined if PWM_FAULT_LATCH_SOFTWARE_CLEAR_FEATURE_AVAILABLE is 1 ...
void(* GeneratorEOCEventCallbackRegister)(void(*callback)(enum PWM_GENERATOR genNum))
Pointer to PWM_GeneratorEOCEventCallbackRegister.
void(* Trigger2Enable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister)
Pointer to PWM_Trigger2Enable (Defined if PWM_TRIGGER_ENABLE_FEATURE_AVAILABLE is 1 in PWM_features....
void(* FaultModeLatchEnable)(enum PWM_GENERATOR genNum)
Pointer to PWM_FaultModeLatchEnable (Defined if PWM_FAULT_MODE_FEATURE_AVAILABLE is 1 in PWM_features...
void(* MasterDutyCycleSet)(uint16_t masterDutyCycle)
Pointer to PWM_MasterDutyCycleSet.
void(* GeneratorInterruptEnable)(enum PWM_GENERATOR genNum, enum PWM_GENERATOR_INTERRUPT interrupt)
Pointer to PWM_GeneratorInterruptEnable.
void(* Trigger1Disable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister)
Pointer to PWM_Trigger1Disable (Defined if PWM_TRIGGER_ENABLE_FEATURE_AVAILABLE is 1 in PWM_features....
void(* GeneratorEnable)(enum PWM_GENERATOR genNum)
Pointer to PWM_GeneratorEnable (Defined if PWM_GENERATOR_ENABLE_FEATURE_AVAILABLE is 1 in PWM_feature...
void(* Disable)(void)
Pointer to PWM_Disable.
void(* GeneratorTasks)(enum PWM_GENERATOR intGen)
Pointer to PWM_GeneratorTasks (Supported only in polling mode)
void(* OverrideHighEnable)(enum PWM_GENERATOR genNum)
Pointer to PWM_OverrideHighEnable.
void(* SpecialEventPrimaryInterruptEnable)(void)
Pointer to PWM_SpecialEventPrimaryInterruptEnable (Defined if PWM_SPECIAL_EVENT_FEATURE_AVAILABLE is ...
void(* CommonEventCallbackRegister)(void(*callback)(enum PWM_COMMON_EVENT event))
Pointer to PWM_CommonEventCallbackRegister.
void(* GeneratorInterruptDisable)(enum PWM_GENERATOR genNum, enum PWM_GENERATOR_INTERRUPT interrupt)
Pointer to PWM_GeneratorInterruptDisable.
void(* MasterPhaseSet)(uint16_t masterPhase)
Pointer to PWM_MasterPhaseSet (Defined if PWM_GENERATOR_MASTER_PHASE_FEATURE_AVAILABLE is 1 in PWM_fe...
void(* PhaseSelect)(enum PWM_GENERATOR genNum, enum PWM_SOURCE_SELECT source)
Pointer to PWM_PhaseSelect.
bool(* SoftwareUpdatePending)(enum PWM_GENERATOR genNum)
Pointer to PWM_SoftwareUpdatePending (Defined if PWM_SOFTWARE_UPDATE_FEATURE_AVAILABLE is 1 in PWM_fe...
void(* DeadTimeHighSet)(enum PWM_GENERATOR genNum, uint16_t deadtimeHigh)
Pointer to PWM_DeadTimeHighSet.
void(* TriggerACompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue)
Pointer to PWM_TriggerACompareValueSet (Defined if PWM_MULTIPLE_TRIGGER_FEATURE_AVAILABLE is 1 in PWM...
bool(* GeneratorEventStatusGet)(enum PWM_GENERATOR genNum, enum PWM_GENERATOR_INTERRUPT interrupt)
Pointer to PWM_GeneratorEventStatusGet.
void(* Deinitialize)(void)
Pointer to PWM_Deinitialize.
void(* OverrideLowDisable)(enum PWM_GENERATOR genNum)
Pointer to PWM_OverrideLowDisable.
void(* SpecialEventTriggerInterruptFlagClear)(void)
Pointer to PWM_SpecialEventTriggerInterruptFlagClear (Defined if PWM_SPECIAL_EVENT_FEATURE_AVAILABLE ...
void(* PhaseSet)(enum PWM_GENERATOR genNum, uint16_t phase)
Pointer to PWM_PhaseSet.
void(* OverrideDataLowSet)(enum PWM_GENERATOR genNum, bool overrideDataLow)
Pointer to PWM_OverrideDataLowSet.
uint16_t(* OverrideDataGet)(enum PWM_GENERATOR genNum)
Pointer to PWM_OverrideDataGet.
void(* Trigger1Enable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister)
Pointer to PWM_Trigger1Enable (Defined if PWM_TRIGGER_ENABLE_FEATURE_AVAILABLE is 1 in PWM_features....
void(* FaultModeLatchDisable)(enum PWM_GENERATOR genNum)
Pointer to PWM_FaultModeLatchDisable (Defined if PWM_FAULT_MODE_FEATURE_AVAILABLE is 1 in PWM_feature...
void(* TriggerCCompareValueSet)(enum PWM_GENERATOR genNum, uint16_t trigCompValue)
Pointer to PWM_TriggerCCompareValueSet (Defined if PWM_MULTIPLE_TRIGGER_FEATURE_AVAILABLE is 1 in PWM...
void(* Trigger2Disable)(enum PWM_GENERATOR genNum, enum PWM_TRIGGER_COMPARE compareRegister)
Pointer to PWM_Trigger2Disable (Defined if PWM_TRIGGER_ENABLE_FEATURE_AVAILABLE is 1 in PWM_features....
void(* Initialize)(void)
Pointer to PWM_Initialize.