EE445M RTOS
Taken at the University of Texas Spring 2015
pwm.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define PWM_GEN_MODE_DOWN   0x00000000
 
#define PWM_GEN_MODE_UP_DOWN   0x00000002
 
#define PWM_GEN_MODE_SYNC   0x00000038
 
#define PWM_GEN_MODE_NO_SYNC   0x00000000
 
#define PWM_GEN_MODE_DBG_RUN   0x00000004
 
#define PWM_GEN_MODE_DBG_STOP   0x00000000
 
#define PWM_GEN_MODE_FAULT_LATCHED   0x00040000
 
#define PWM_GEN_MODE_FAULT_UNLATCHED   0x00000000
 
#define PWM_GEN_MODE_FAULT_MINPER   0x00020000
 
#define PWM_GEN_MODE_FAULT_NO_MINPER   0x00000000
 
#define PWM_GEN_MODE_FAULT_EXT   0x00010000
 
#define PWM_GEN_MODE_FAULT_LEGACY   0x00000000
 
#define PWM_GEN_MODE_DB_NO_SYNC   0x00000000
 
#define PWM_GEN_MODE_DB_SYNC_LOCAL   0x0000A800
 
#define PWM_GEN_MODE_DB_SYNC_GLOBAL   0x0000FC00
 
#define PWM_GEN_MODE_GEN_NO_SYNC   0x00000000
 
#define PWM_GEN_MODE_GEN_SYNC_LOCAL   0x00000280
 
#define PWM_GEN_MODE_GEN_SYNC_GLOBAL   0x000003C0
 
#define PWM_INT_CNT_ZERO   0x00000001
 
#define PWM_INT_CNT_LOAD   0x00000002
 
#define PWM_INT_CNT_AU   0x00000004
 
#define PWM_INT_CNT_AD   0x00000008
 
#define PWM_INT_CNT_BU   0x00000010
 
#define PWM_INT_CNT_BD   0x00000020
 
#define PWM_TR_CNT_ZERO   0x00000100
 
#define PWM_TR_CNT_LOAD   0x00000200
 
#define PWM_TR_CNT_AU   0x00000400
 
#define PWM_TR_CNT_AD   0x00000800
 
#define PWM_TR_CNT_BU   0x00001000
 
#define PWM_TR_CNT_BD   0x00002000
 
#define PWM_INT_GEN_0   0x00000001
 
#define PWM_INT_GEN_1   0x00000002
 
#define PWM_INT_GEN_2   0x00000004
 
#define PWM_INT_GEN_3   0x00000008
 
#define PWM_INT_FAULT0   0x00010000
 
#define PWM_INT_FAULT1   0x00020000
 
#define PWM_INT_FAULT2   0x00040000
 
#define PWM_INT_FAULT3   0x00080000
 
#define PWM_INT_FAULT_M   0x000F0000
 
#define PWM_GEN_0   0x00000040
 
#define PWM_GEN_1   0x00000080
 
#define PWM_GEN_2   0x000000C0
 
#define PWM_GEN_3   0x00000100
 
#define PWM_GEN_0_BIT   0x00000001
 
#define PWM_GEN_1_BIT   0x00000002
 
#define PWM_GEN_2_BIT   0x00000004
 
#define PWM_GEN_3_BIT   0x00000008
 
#define PWM_GEN_EXT_0   0x00000800
 
#define PWM_GEN_EXT_1   0x00000880
 
#define PWM_GEN_EXT_2   0x00000900
 
#define PWM_GEN_EXT_3   0x00000980
 
#define PWM_OUT_0   0x00000040
 
#define PWM_OUT_1   0x00000041
 
#define PWM_OUT_2   0x00000082
 
#define PWM_OUT_3   0x00000083
 
#define PWM_OUT_4   0x000000C4
 
#define PWM_OUT_5   0x000000C5
 
#define PWM_OUT_6   0x00000106
 
#define PWM_OUT_7   0x00000107
 
#define PWM_OUT_0_BIT   0x00000001
 
#define PWM_OUT_1_BIT   0x00000002
 
#define PWM_OUT_2_BIT   0x00000004
 
#define PWM_OUT_3_BIT   0x00000008
 
#define PWM_OUT_4_BIT   0x00000010
 
#define PWM_OUT_5_BIT   0x00000020
 
#define PWM_OUT_6_BIT   0x00000040
 
#define PWM_OUT_7_BIT   0x00000080
 
#define PWM_FAULT_GROUP_0   0
 
#define PWM_FAULT_FAULT0   0x00000001
 
#define PWM_FAULT_FAULT1   0x00000002
 
#define PWM_FAULT_FAULT2   0x00000004
 
#define PWM_FAULT_FAULT3   0x00000008
 
#define PWM_FAULT_ACMP0   0x00010000
 
#define PWM_FAULT_ACMP1   0x00020000
 
#define PWM_FAULT_ACMP2   0x00040000
 
#define PWM_FAULT_GROUP_1   1
 
#define PWM_FAULT_DCMP0   0x00000001
 
#define PWM_FAULT_DCMP1   0x00000002
 
#define PWM_FAULT_DCMP2   0x00000004
 
#define PWM_FAULT_DCMP3   0x00000008
 
#define PWM_FAULT_DCMP4   0x00000010
 
#define PWM_FAULT_DCMP5   0x00000020
 
#define PWM_FAULT_DCMP6   0x00000040
 
#define PWM_FAULT_DCMP7   0x00000080
 
#define PWM_FAULT0_SENSE_HIGH   0x00000000
 
#define PWM_FAULT0_SENSE_LOW   0x00000001
 
#define PWM_FAULT1_SENSE_HIGH   0x00000000
 
#define PWM_FAULT1_SENSE_LOW   0x00000002
 
#define PWM_FAULT2_SENSE_HIGH   0x00000000
 
#define PWM_FAULT2_SENSE_LOW   0x00000004
 
#define PWM_FAULT3_SENSE_HIGH   0x00000000
 
#define PWM_FAULT3_SENSE_LOW   0x00000008
 
#define PWM_SYSCLK_DIV_1   0x00000000
 
#define PWM_SYSCLK_DIV_2   0x00000100
 
#define PWM_SYSCLK_DIV_4   0x00000101
 
#define PWM_SYSCLK_DIV_8   0x00000102
 
#define PWM_SYSCLK_DIV_16   0x00000103
 
#define PWM_SYSCLK_DIV_32   0x00000104
 
#define PWM_SYSCLK_DIV_64   0x00000105
 
#define PWM_OUTPUT_MODE_NO_SYNC   0x00000000
 
#define PWM_OUTPUT_MODE_SYNC_LOCAL   0x00000002
 
#define PWM_OUTPUT_MODE_SYNC_GLOBAL   0x00000003
 

Functions

void PWMGenConfigure (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32Config)
 
void PWMGenPeriodSet (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32Period)
 
uint32_t PWMGenPeriodGet (uint32_t ui32Base, uint32_t ui32Gen)
 
void PWMGenEnable (uint32_t ui32Base, uint32_t ui32Gen)
 
void PWMGenDisable (uint32_t ui32Base, uint32_t ui32Gen)
 
void PWMPulseWidthSet (uint32_t ui32Base, uint32_t ui32PWMOut, uint32_t ui32Width)
 
uint32_t PWMPulseWidthGet (uint32_t ui32Base, uint32_t ui32PWMOut)
 
void PWMDeadBandEnable (uint32_t ui32Base, uint32_t ui32Gen, uint16_t ui16Rise, uint16_t ui16Fall)
 
void PWMDeadBandDisable (uint32_t ui32Base, uint32_t ui32Gen)
 
void PWMSyncUpdate (uint32_t ui32Base, uint32_t ui32GenBits)
 
void PWMSyncTimeBase (uint32_t ui32Base, uint32_t ui32GenBits)
 
void PWMOutputState (uint32_t ui32Base, uint32_t ui32PWMOutBits, bool bEnable)
 
void PWMOutputInvert (uint32_t ui32Base, uint32_t ui32PWMOutBits, bool bInvert)
 
void PWMOutputFaultLevel (uint32_t ui32Base, uint32_t ui32PWMOutBits, bool bDriveHigh)
 
void PWMOutputFault (uint32_t ui32Base, uint32_t ui32PWMOutBits, bool bFaultSuppress)
 
void PWMGenIntRegister (uint32_t ui32Base, uint32_t ui32Gen, void(*pfnIntHandler)(void))
 
void PWMGenIntUnregister (uint32_t ui32Base, uint32_t ui32Gen)
 
void PWMFaultIntRegister (uint32_t ui32Base, void(*pfnIntHandler)(void))
 
void PWMFaultIntUnregister (uint32_t ui32Base)
 
void PWMGenIntTrigEnable (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32IntTrig)
 
void PWMGenIntTrigDisable (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32IntTrig)
 
uint32_t PWMGenIntStatus (uint32_t ui32Base, uint32_t ui32Gen, bool bMasked)
 
void PWMGenIntClear (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32Ints)
 
void PWMIntEnable (uint32_t ui32Base, uint32_t ui32GenFault)
 
void PWMIntDisable (uint32_t ui32Base, uint32_t ui32GenFault)
 
void PWMFaultIntClear (uint32_t ui32Base)
 
uint32_t PWMIntStatus (uint32_t ui32Base, bool bMasked)
 
void PWMFaultIntClearExt (uint32_t ui32Base, uint32_t ui32FaultInts)
 
void PWMGenFaultConfigure (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32MinFaultPeriod, uint32_t ui32FaultSenses)
 
void PWMGenFaultTriggerSet (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32Group, uint32_t ui32FaultTriggers)
 
uint32_t PWMGenFaultTriggerGet (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32Group)
 
uint32_t PWMGenFaultStatus (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32Group)
 
void PWMGenFaultClear (uint32_t ui32Base, uint32_t ui32Gen, uint32_t ui32Group, uint32_t ui32FaultTriggers)
 
void PWMClockSet (uint32_t ui32Base, uint32_t ui32Config)
 
uint32_t PWMClockGet (uint32_t ui32Base)
 
void PWMOutputUpdateMode (uint32_t ui32Base, uint32_t ui32PWMOutBits, uint32_t ui32Mode)
 

Macro Definition Documentation

#define PWM_FAULT0_SENSE_HIGH   0x00000000

Definition at line 210 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT0_SENSE_LOW   0x00000001

Definition at line 211 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT1_SENSE_HIGH   0x00000000

Definition at line 212 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT1_SENSE_LOW   0x00000002

Definition at line 213 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT2_SENSE_HIGH   0x00000000

Definition at line 214 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT2_SENSE_LOW   0x00000004

Definition at line 215 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT3_SENSE_HIGH   0x00000000

Definition at line 216 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT3_SENSE_LOW   0x00000008

Definition at line 217 of file pwm.h.

Referenced by PWMGenFaultConfigure().

#define PWM_FAULT_ACMP0   0x00010000

Definition at line 184 of file pwm.h.

#define PWM_FAULT_ACMP1   0x00020000

Definition at line 185 of file pwm.h.

#define PWM_FAULT_ACMP2   0x00040000

Definition at line 186 of file pwm.h.

#define PWM_FAULT_DCMP0   0x00000001

Definition at line 196 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_DCMP1   0x00000002

Definition at line 197 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_DCMP2   0x00000004

Definition at line 198 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_DCMP3   0x00000008

Definition at line 199 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_DCMP4   0x00000010

Definition at line 200 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_DCMP5   0x00000020

Definition at line 201 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_DCMP6   0x00000040

Definition at line 202 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_DCMP7   0x00000080

Definition at line 203 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_FAULT0   0x00000001

Definition at line 180 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_FAULT1   0x00000002

Definition at line 181 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_FAULT2   0x00000004

Definition at line 182 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_FAULT3   0x00000008

Definition at line 183 of file pwm.h.

Referenced by PWMGenFaultClear(), and PWMGenFaultTriggerSet().

#define PWM_FAULT_GROUP_0   0
#define PWM_FAULT_GROUP_1   1
#define PWM_GEN_0   0x00000040

Definition at line 134 of file pwm.h.

Referenced by _PWMGenIntNumberGet().

#define PWM_GEN_0_BIT   0x00000001

Definition at line 139 of file pwm.h.

Referenced by PWMSyncTimeBase(), and PWMSyncUpdate().

#define PWM_GEN_1   0x00000080

Definition at line 135 of file pwm.h.

Referenced by _PWMGenIntNumberGet().

#define PWM_GEN_1_BIT   0x00000002

Definition at line 140 of file pwm.h.

Referenced by PWMSyncTimeBase(), and PWMSyncUpdate().

#define PWM_GEN_2   0x000000C0

Definition at line 136 of file pwm.h.

Referenced by _PWMGenIntNumberGet().

#define PWM_GEN_2_BIT   0x00000004

Definition at line 141 of file pwm.h.

Referenced by PWMSyncTimeBase(), and PWMSyncUpdate().

#define PWM_GEN_3   0x00000100

Definition at line 137 of file pwm.h.

Referenced by _PWMGenIntNumberGet().

#define PWM_GEN_3_BIT   0x00000008

Definition at line 142 of file pwm.h.

Referenced by PWMSyncTimeBase(), and PWMSyncUpdate().

#define PWM_GEN_EXT_0   0x00000800

Definition at line 144 of file pwm.h.

#define PWM_GEN_EXT_1   0x00000880

Definition at line 145 of file pwm.h.

#define PWM_GEN_EXT_2   0x00000900

Definition at line 146 of file pwm.h.

#define PWM_GEN_EXT_3   0x00000980

Definition at line 147 of file pwm.h.

#define PWM_GEN_MODE_DB_NO_SYNC   0x00000000

Definition at line 77 of file pwm.h.

#define PWM_GEN_MODE_DB_SYNC_GLOBAL   0x0000FC00

Definition at line 82 of file pwm.h.

#define PWM_GEN_MODE_DB_SYNC_LOCAL   0x0000A800

Definition at line 79 of file pwm.h.

#define PWM_GEN_MODE_DBG_RUN   0x00000004

Definition at line 64 of file pwm.h.

#define PWM_GEN_MODE_DBG_STOP   0x00000000

Definition at line 65 of file pwm.h.

#define PWM_GEN_MODE_DOWN   0x00000000

Definition at line 60 of file pwm.h.

#define PWM_GEN_MODE_FAULT_EXT   0x00010000

Definition at line 74 of file pwm.h.

#define PWM_GEN_MODE_FAULT_LATCHED   0x00040000

Definition at line 66 of file pwm.h.

#define PWM_GEN_MODE_FAULT_LEGACY   0x00000000

Definition at line 75 of file pwm.h.

#define PWM_GEN_MODE_FAULT_MINPER   0x00020000

Definition at line 70 of file pwm.h.

#define PWM_GEN_MODE_FAULT_NO_MINPER   0x00000000

Definition at line 72 of file pwm.h.

#define PWM_GEN_MODE_FAULT_UNLATCHED   0x00000000

Definition at line 68 of file pwm.h.

#define PWM_GEN_MODE_GEN_NO_SYNC   0x00000000

Definition at line 85 of file pwm.h.

#define PWM_GEN_MODE_GEN_SYNC_GLOBAL   0x000003C0

Definition at line 91 of file pwm.h.

#define PWM_GEN_MODE_GEN_SYNC_LOCAL   0x00000280

Definition at line 88 of file pwm.h.

#define PWM_GEN_MODE_NO_SYNC   0x00000000

Definition at line 63 of file pwm.h.

#define PWM_GEN_MODE_SYNC   0x00000038

Definition at line 62 of file pwm.h.

#define PWM_GEN_MODE_UP_DOWN   0x00000002

Definition at line 61 of file pwm.h.

#define PWM_INT_CNT_AD   0x00000008

Definition at line 104 of file pwm.h.

Referenced by PWMGenIntClear(), PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_INT_CNT_AU   0x00000004

Definition at line 103 of file pwm.h.

Referenced by PWMGenIntClear(), PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_INT_CNT_BD   0x00000020

Definition at line 106 of file pwm.h.

Referenced by PWMGenIntClear(), PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_INT_CNT_BU   0x00000010

Definition at line 105 of file pwm.h.

Referenced by PWMGenIntClear(), PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_INT_CNT_LOAD   0x00000002

Definition at line 102 of file pwm.h.

Referenced by PWMGenIntClear(), PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_INT_CNT_ZERO   0x00000001

Definition at line 101 of file pwm.h.

Referenced by PWMGenIntClear(), PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_INT_FAULT0   0x00010000

Definition at line 123 of file pwm.h.

Referenced by PWMFaultIntClearExt(), PWMIntDisable(), and PWMIntEnable().

#define PWM_INT_FAULT1   0x00020000

Definition at line 124 of file pwm.h.

Referenced by PWMFaultIntClearExt(), PWMIntDisable(), and PWMIntEnable().

#define PWM_INT_FAULT2   0x00040000

Definition at line 125 of file pwm.h.

Referenced by PWMFaultIntClearExt(), PWMIntDisable(), and PWMIntEnable().

#define PWM_INT_FAULT3   0x00080000

Definition at line 126 of file pwm.h.

Referenced by PWMFaultIntClearExt(), PWMIntDisable(), and PWMIntEnable().

#define PWM_INT_FAULT_M   0x000F0000

Definition at line 127 of file pwm.h.

#define PWM_INT_GEN_0   0x00000001

Definition at line 119 of file pwm.h.

Referenced by PWMIntDisable(), and PWMIntEnable().

#define PWM_INT_GEN_1   0x00000002

Definition at line 120 of file pwm.h.

Referenced by PWMIntDisable(), and PWMIntEnable().

#define PWM_INT_GEN_2   0x00000004

Definition at line 121 of file pwm.h.

Referenced by PWMIntDisable(), and PWMIntEnable().

#define PWM_INT_GEN_3   0x00000008

Definition at line 122 of file pwm.h.

Referenced by PWMIntDisable(), and PWMIntEnable().

#define PWM_OUT_0   0x00000040

Definition at line 154 of file pwm.h.

#define PWM_OUT_0_BIT   0x00000001
#define PWM_OUT_1   0x00000041

Definition at line 155 of file pwm.h.

#define PWM_OUT_1_BIT   0x00000002
#define PWM_OUT_2   0x00000082

Definition at line 156 of file pwm.h.

#define PWM_OUT_2_BIT   0x00000004
#define PWM_OUT_3   0x00000083

Definition at line 157 of file pwm.h.

#define PWM_OUT_3_BIT   0x00000008
#define PWM_OUT_4   0x000000C4

Definition at line 158 of file pwm.h.

#define PWM_OUT_4_BIT   0x00000010
#define PWM_OUT_5   0x000000C5

Definition at line 159 of file pwm.h.

#define PWM_OUT_5_BIT   0x00000020
#define PWM_OUT_6   0x00000106

Definition at line 160 of file pwm.h.

#define PWM_OUT_6_BIT   0x00000040
#define PWM_OUT_7   0x00000107

Definition at line 161 of file pwm.h.

#define PWM_OUT_7_BIT   0x00000080
#define PWM_OUTPUT_MODE_NO_SYNC   0x00000000

Definition at line 239 of file pwm.h.

Referenced by PWMOutputUpdateMode().

#define PWM_OUTPUT_MODE_SYNC_GLOBAL   0x00000003

Definition at line 242 of file pwm.h.

Referenced by PWMOutputUpdateMode().

#define PWM_OUTPUT_MODE_SYNC_LOCAL   0x00000002

Definition at line 240 of file pwm.h.

Referenced by PWMOutputUpdateMode().

#define PWM_SYSCLK_DIV_1   0x00000000

Definition at line 225 of file pwm.h.

Referenced by PWMClockGet().

#define PWM_SYSCLK_DIV_16   0x00000103

Definition at line 229 of file pwm.h.

Referenced by PWMClockSet().

#define PWM_SYSCLK_DIV_2   0x00000100

Definition at line 226 of file pwm.h.

Referenced by PWMClockSet().

#define PWM_SYSCLK_DIV_32   0x00000104

Definition at line 230 of file pwm.h.

Referenced by PWMClockSet().

#define PWM_SYSCLK_DIV_4   0x00000101

Definition at line 227 of file pwm.h.

Referenced by PWMClockSet().

#define PWM_SYSCLK_DIV_64   0x00000105

Definition at line 231 of file pwm.h.

Referenced by PWMClockSet().

#define PWM_SYSCLK_DIV_8   0x00000102

Definition at line 228 of file pwm.h.

Referenced by PWMClockSet().

#define PWM_TR_CNT_AD   0x00000800

Definition at line 110 of file pwm.h.

Referenced by PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_TR_CNT_AU   0x00000400

Definition at line 109 of file pwm.h.

Referenced by PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_TR_CNT_BD   0x00002000

Definition at line 112 of file pwm.h.

Referenced by PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_TR_CNT_BU   0x00001000

Definition at line 111 of file pwm.h.

Referenced by PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_TR_CNT_LOAD   0x00000200

Definition at line 108 of file pwm.h.

Referenced by PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().

#define PWM_TR_CNT_ZERO   0x00000100

Definition at line 107 of file pwm.h.

Referenced by PWMGenIntTrigDisable(), and PWMGenIntTrigEnable().