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

Loading...
Searching...
No Matches
Files | Enumerations | Functions
MCC Custom Code PWM
Driver Layer

Contain functions and data types as MCC extension for PWM. More...

Collaboration diagram for MCC Custom Code PWM:

## Files
file | drv_custom_config_pwm.h
| Contains PWM initialization that was not supported by MCC generated code.
file | drv_mcc_extension_pwm.h
| Contains public functions and defines for the MCC code extension for PWM.

## Enumerations
enum | PWM_PCI_ACCEPTANCE_CRITERIA_e { PWM_PCI_ACCEPT_LEVEL_SENSITIVE = 0 , PWM_PCI_ACCEPT_RISING_EDGE = 1 , PWM_PCI_ACCEPT_ANY_EDGE = 2 , PWM_PCI_ACCEPT_LATCHED = 3 , PWM_PCI_ACCEPT_LATCHED_RISING_EDGE = 4 , PWM_PCI_ACCEPT_LATCHED_ANY_EDGE = 5 }
| Set PCI fault acceptance criteria. More...
enum | PWM_PCI_TERMTIME_AFTER_EVENT_e { PWM_PCI_TERMTIME_AFTER_EVENT_AT_EOC = 0 , PWM_PCI_TERMTIME_AFTER_EVENT_IMMEDIATE = 1 }
| Settings for Termination Synchronization bit. More...
enum | PWM_SOCS_e { PWM_SOCS_SELF_TRIGGER = 0 , PWM_SOCS_PG1_OR_PG5 = 1 , PWM_SOCS_PG2_OR_PG6 = 2 , PWM_SOCS_PG3_OR_PG7 = 3 , PWM_SOCS_PG4_OR_PG8 = 4 , PWM_SOCS_TRIG_OR_PCI_SYNC = 15 }
| Settings for PWM Start-of_cycle Selection bit. More...
enum | PWM_UPDMOD_e { PWM_UPDMOD_SOC = 0 , PWM_UPDMOD_IMMEDIATE = 1 , PWM_UPDMOD_CLIENT_SOC = 2 , PWM_UPDMOD_CLIENT_IMMEDIATE = 3 }
| settings for PWM Buffer Update Mode Selection bits More...
enum | PWM_PCI_SOURCE_e { PWM_PCI_SOURCE_PWM1 = 0 , PWM_PCI_SOURCE_PWM2 = 1 , PWM_PCI_SOURCE_PWM3 = 2 , PWM_PCI_SOURCE_PWM4 = 3 }
| Settings for PWM Source for PCI Selection bits. More...
enum | RPnR_SOURCE_e { RPnR_SOURCE_DefaultPORT = 0 , RPnR_SOURCE_U1TX = 1 , RPnR_SOURCE_U1RTS = 2 , RPnR_SOURCE_U2TX = 3 , RPnR_SOURCE_U2RTS = 4 , RPnR_SOURCE_SDO1 = 5 , RPnR_SOURCE_SCK1 = 6 , RPnR_SOURCE_SS1 = 7 , RPnR_SOURCE_SDO2 = 8 , RPnR_SOURCE_SCK2 = 9 , RPnR_SOURCE_SS2 = 10 , RPnR_SOURCE_SDO3 = 11 , RPnR_SOURCE_SCK3 = 12 , RPnR_SOURCE_SS3 = 13 , RPnR_SOURCE_REFCLKO = 14 , RPnR_SOURCE_OCM1 = 15 , RPnR_SOURCE_OCM2 = 16 , RPnR_SOURCE_OCM3 = 17 , RPnR_SOURCE_OCM4 = 18 , RPnR_SOURCE_OCM5 = 19 , RPnR_SOURCE_OCM6 = 20 , RPnR_SOURCE_CAN1TX = 21 , RPnR_SOURCE_CMP1 = 23 , RPnR_SOURCE_CMP2 = 24 , RPnR_SOURCE_CMP3 = 25 , RPnR_SOURCE_U3TX = 27 , RPnR_SOURCE_U3RTS = 28 , RPnR_SOURCE_PWM4H = 34 , RPnR_SOURCE_PWM4L = 35 , RPnR_SOURCE_PWMEA = 36 , RPnR_SOURCE_PWMEB = 37 , RPnR_SOURCE_QEICMP1 = 38 , RPnR_SOURCE_QEICMP2 = 39 , RPnR_SOURCE_CLC1OUT = 40 , RPnR_SOURCE_CLC2OUT = 41 , RPnR_SOURCE_OCM7 = 42 , RPnR_SOURCE_OCM8 = 43 , RPnR_SOURCE_PWMEC = 44 , RPnR_SOURCE_PWMED = 45 , RPnR_SOURCE_PTGTRG24 = 46 , RPnR_SOURCE_PTGTRG25 = 47 , RPnR_SOURCE_SENT1OUT = 48 , RPnR_SOURCE_SENT2OUT = 49 , RPnR_SOURCE_MCCP9A = 50 , RPnR_SOURCE_MCCP9B = 51 , RPnR_SOURCE_MCCP9C = 52 , RPnR_SOURCE_MCCP9D = 53 , RPnR_SOURCE_MCCP9E = 54 , RPnR_SOURCE_MCCP9F = 55 , RPnR_SOURCE_CLC3OUT = 59 , RPnR_SOURCE_CLC4OUT = 60 , RPnR_SOURCE_U1DTR = 61 , RPnR_SOURCE_U2DTR = 62 , RPnR_SOURCE_U3DTR = 63 }
| Peripheral output for re-mappable pins. More...
enum | RPnR_VIRTUAL_PIN_e { RPnR_VIRTUAL_PIN_RP176 = 0 , RPnR_VIRTUAL_PIN_RP177 = 1 , RPnR_VIRTUAL_PIN_RP178 = 2 , RPnR_VIRTUAL_PIN_RP179 = 3 , RPnR_VIRTUAL_PIN_RP180 = 4 , RPnR_VIRTUAL_PIN_RP181 = 5 }
| List of re-mappable pins for dsPIC33CK256MP508. More...
enum | RPx_INPUT_e { RPx_INPUT_VSS = 0 , RPx_INPUT_CMP1 = 1 , RPx_INPUT_CMP2 = 2 , RPx_INPUT_CMP3 = 3 , RPx_INPUT_PTG_TRIG_26 = 6 , RPx_INPUT_PTG_TRIG_27 = 7 , RPx_INPUT_PWM_EVENT_C = 11 , RPx_INPUT_PWM_EVENT_D = 12 , RPx_INPUT_PWM_EVENT_E = 13 , RPx_INPUT_RP32 = 32 , RPx_INPUT_RP33 = 33 , RPx_INPUT_RP34 = 34 , RPx_INPUT_RP35 = 35 , RPx_INPUT_RP36 = 36 , RPx_INPUT_RP37 = 37 , RPx_INPUT_RP38 = 38 , RPx_INPUT_RP39 = 39 , RPx_INPUT_RP40 = 40 , RPx_INPUT_RP41 = 41 , RPx_INPUT_RP42 = 42 , RPx_INPUT_RP43 = 43 , RPx_INPUT_RP44 = 44 , RPx_INPUT_RP45 = 45 , RPx_INPUT_RP46 = 46 , RPx_INPUT_RP47 = 47 , RPx_INPUT_RP48 = 48 , RPx_INPUT_RP49 = 49 , RPx_INPUT_RP50 = 50 , RPx_INPUT_RP51 = 51 , RPx_INPUT_RP52 = 52 , RPx_INPUT_RP53 = 53 , RPx_INPUT_RP54 = 54 , RPx_INPUT_RP55 = 55 , RPx_INPUT_RP56 = 56 , RPx_INPUT_RP57 = 57 , RPx_INPUT_RP58 = 58 , RPx_INPUT_RP59 = 59 , RPx_INPUT_RP60 = 60 , RPx_INPUT_RP61 = 61 , RPx_INPUT_RP62 = 62 , RPx_INPUT_RP63 = 63 , RPx_INPUT_RP64 = 64 , RPx_INPUT_RP65 = 65 , RPx_INPUT_RP66 = 66 , RPx_INPUT_RP67 = 67 , RPx_INPUT_RP68 = 68 , RPx_INPUT_RP69 = 69 , RPx_INPUT_RP70 = 70 , RPx_INPUT_RP71 = 71 , RPx_INPUT_RP72 = 72 , RPx_INPUT_RP73 = 73 , RPx_INPUT_RP74 = 74 , RPx_INPUT_RP75 = 75 , RPx_INPUT_RP76 = 76 , RPx_INPUT_RP77 = 77 , RPx_INPUT_RP78 = 78 , RPx_INPUT_RP79 = 79 , RPx_INPUT_DAC3_pwm_req_on = 164 , RPx_INPUT_DAC3_pwm_req_off = 165 , RPx_INPUT_DAC2_pwm_req_on = 166 , RPx_INPUT_DAC2_pwm_req_off = 167 , RPx_INPUT_DAC1_pwm_req_on = 168 , RPx_INPUT_DAC1_pwm_req_off = 169 , RPx_INPUT_RP176 = 176 , RPx_INPUT_RP177 = 177 , RPx_INPUT_RP178 = 178 , RPx_INPUT_RP179 = 179 , RPx_INPUT_RP180 = 180 , RPx_INPUT_RP181 = 181 }
| List of output selection for re-mappable pins (taken from dsPIC33CK256MP508 datasheet) More...
enum | PWM_PCI_INPUT_e { PWM_PCI_INPUT8 = 0 , PWM_PCI_INPUT9 = 1 , PWM_PCI_INPUT10 = 2 , PWM_PCI_INPUT11 = 3 }
| list of PWM PCI inputs More...
enum | PWM_PCI_SOURCE_SELECT_e { PWM_PCI_SOURCE_SELECT_CLC1 = 31 , PWM_PCI_SOURCE_SELECT_CMP3 = 29 , PWM_PCI_SOURCE_SELECT_CMP2 = 28 , PWM_PCI_SOURCE_SELECT_CMP1 = 27 , PWM_PCI_SOURCE_SELECT_PWM_EVENT_D = 26 , PWM_PCI_SOURCE_SELECT_PWM_EVENT_C = 25 , PWM_PCI_SOURCE_SELECT_PWM_EVENT_B = 24 , PWM_PCI_SOURCE_SELECT_PWM_EVENT_A = 23 , PWM_PCI_SOURCE_SELECT_PCI22 = 22 , PWM_PCI_SOURCE_SELECT_PCI21 = 21 , PWM_PCI_SOURCE_SELECT_PCI20 = 20 , PWM_PCI_SOURCE_SELECT_PCI19 = 19 , PWM_PCI_SOURCE_SELECT_PCI18R = 18 , PWM_PCI_SOURCE_SELECT_PCI17R = 17 , PWM_PCI_SOURCE_SELECT_PCI16R = 16 , PWM_PCI_SOURCE_SELECT_PCI15R = 15 , PWM_PCI_SOURCE_SELECT_PCI14R = 14 , PWM_PCI_SOURCE_SELECT_PCI13R = 13 , PWM_PCI_SOURCE_SELECT_PCI12R = 12 , PWM_PCI_SOURCE_SELECT_PCI11R = 11 , PWM_PCI_SOURCE_SELECT_PCI10R = 10 , PWM_PCI_SOURCE_SELECT_PCI9R = 9 , PWM_PCI_SOURCE_SELECT_PCI8R = 8 , PWM_PCI_SOURCE_SELECT_COMBO_TRIG_B = 3 , PWM_PCI_SOURCE_SELECT_COMBO_TRIG_A = 2 , PWM_PCI_SOURCE_SELECT_PWMPCI_MUX = 1 , PWM_PCI_SOURCE_SELECT_TIED_TO_0 = 0 }
| List of PWM PCI inputs. More...
enum | PWM_PCI_ACCEPTANCE_QUALIFER_e { PWM_PCI_ACCEPTANCE_QUALIFER_NONE = 0 , PWM_PCI_ACCEPTANCE_QUALIFER_DUTY = 1 , PWM_PCI_ACCEPTANCE_QUALIFER_LEB = 2 , PWM_PCI_ACCEPTANCE_QUALIFER_PWM = 3 , PWM_PCI_ACCEPTANCE_QUALIFER_PCI_PWMPCI = 4 , PWM_PCI_ACCEPTANCE_QUALIFER_PCI_SOURCE8 = 5 , PWM_PCI_ACCEPTANCE_QUALIFER_PCI_SOURCE9 = 6 , PWM_PCI_ACCEPTANCE_QUALIFER_SWPCI = 7 }
| List of sources of PWM acceptance qualifiers. More...
enum | PWM_TRIG_MODE_e { PWM_TRIG_MODE_SINGLE = 0 , PWM_TRIG_MODE_RETRIGGERABLE = 1 }
| Set PWM trigger mode. More...
enum | PWM_PCI_TERM_e { PWM_PCI_TERM_MANUAL = 0 , PWM_PCI_TERM_AUTO = 1 , PWM_PCI_TERM_PGxTRIGA = 2 , PWM_PCI_TERM_PGxTRIGB = 3 , PWM_PCI_TERM_PGxTRIGC = 4 , PWM_PCI_TERM_PCI_SOURCE1 = 5 , PWM_PCI_TERM_PCI_SOURCE8 = 6 , PWM_PCI_TERM_PCI_SOURCE9 = 7 }
| PWM Termination event selection. More...
enum | PWM_EVENT_SOURCE_e { PWM_EVENT_SOURCE_PGTRGSEL = 0 , PWM_EVENT_SOURCE_PWM_GEN_OUTPUT = 1 , PWM_EVENT_SOURCE_PCI_SYNC_ACTIVE = 2 , PWM_EVENT_SOURCE_PCI_FF_ACTIVE = 3 , PWM_EVENT_SOURCE_PCI_FF_CL_ACTIVE = 4 , PWM_EVENT_SOURCE_PCI_FAULT_ACTIVE = 5 , PWM_EVENT_SOURCE_CAHALF = 6 , PWM_EVENT_SOURCE_STEER = 7 , PWM_EVENT_SOURCE_ADC_TRIG1 = 8 , PWM_EVENT_SOURCE_ADC_TRIG2 = 9 , PWM_EVENT_SOURCE_HR_ERROR_EVENT = 15 }
| Select event source for PWMEVTx register. More...
enum | PWM_UPDTRG_e { PWM_UPDTRG_MANUAL = 0 , PWM_UPDTRG_PGxDC = 1 , PWM_UPDTRG_PGxPHASE = 2 , PWM_UPDTRG_PGxTRIGA = 3 }
| Settings for Update Trigger Event. More...
enum | PWM_LATCH_MODE_e { PWM_SET_DOMINANT_MODE = 0 , PWM_RESET_DOMINANT_MODE = 1 }
| Set PWM trigger mode. More...
enum | PWM_FAULT_DATA_e { PWM_FAULT_EVENT_PWMH = 0 , PWM_FAULT_EVENT_PWML = 1 }
| Set PWM fault data. More...

## Functions
static __inline__ void | DRV_Config_Custom_PWM (void)
| Contains PWM initialization that was not supported by MCC generated code.
static void | PWM_PCI_Fault_AcceptanceCriteria (uint16_t pwmIndex, PWM_PCI_ACCEPTANCE_CRITERIA_t acpSetting)
| Set PCI fault acceptance criteria.
static void | PWM_PCI_Fault_AcceptanceQualiferInvert (uint16_t pwmIndex, bool invert)
| Set PCI polarity of PCI fault acceptance input.
static void | PWM_PCI_Sync_AcceptanceCriteria (uint16_t pwmIndex, PWM_PCI_ACCEPTANCE_CRITERIA_t acpSetting)
| Sets PCI Synchronization Acceptance Criteria.
static void | PWM_PCI_Fault_TimetoTerminateAfterEvent (uint16_t pwmIndex, PWM_PCI_TERMTIME_AFTER_EVENT_t faultTerm)
| Set TSYNCDIS bit to determine when PWM should stop after a fault occurs.
static void | PWM_PCI_Sync_TimetoTerminateAfterEvent (uint16_t pwmIndex, PWM_PCI_TERMTIME_AFTER_EVENT_t faultTerm)
| Set TSYNCDIS bit to determine when PWM should stop after a sync event occurs.
static void | PWM_StartOfCycleTrigger (uint16_t pwmIndex, PWM_SOCS_t triggerSource)
| Set SOCS field to determine start of cycle trigger.
static void | PWM_UPDREQ_Broadcast_Enable (uint16_t pwmIndex, bool enable)
| Enable broadcasting of UPDREQ bit to other PWMs.
static void | PWM_Data_Update_Mode (uint16_t pwmIndex, PWM_UPDMOD_t updateMode)
| Sets the PWM Data Update Mode.
static void | PWM_PCI_Source1 (uint16_t pwmIndex, PWM_PCI_SOURCE_t pciSource)
| Set PWM source for PCI selection bits (for PCI source 1)
static void | RPnR_VirtualPin_Source (RPnR_VIRTUAL_PIN_t virtualPin, RPnR_SOURCE_t peripheral)
| Set source for a virtual pin.
static void | PWM_PCI_INPUT_MaptoPin (PWM_PCI_INPUT_t pciIndex, RPx_INPUT_t pin)
| Map PWM PCI input to a pin.
static void | PWM_PCI_Sync_Source_Select (uint16_t pwmIndex, PWM_PCI_SOURCE_SELECT_t pciSource)
| Set PCI source (PSS field) for PCI Synchronization.
static void | PWM_PCI_Fault_AcceptanceQualifierSource (uint16_t pwmIndex, PWM_PCI_ACCEPTANCE_QUALIFER_t source)
| Set source of fault PCI acceptance qualifier.
static void | PWM_Trigger_Mode (uint16_t pwmIndex, PWM_TRIG_MODE_t trigMode)
| Set source of fault PCI acceptance qualifier.
static void | PWM_PCI_Sync_TerminationEventSelect (uint16_t pwmIndex, PWM_PCI_TERM_t termEvent)
| Select termination event for SYNC PCI.
static void | PWM_Swap_PWMxL_and_PWMxH (uint16_t pwmIndex, bool swapPWMH_PWML)
| Enable/Disable the PWM instance output swap bit.
static void | PWM_EVENTA_Configure (uint16_t pwmSource, PWM_EVENT_SOURCE_t eventSource, bool invert, bool outputEnable, bool stretchDisable, bool outputSync)
| Configure PWM Event A register.
static void | PWM_Data_Update_Trigger (uint16_t pwmIndex, PWM_UPDTRG_t updateTrigger)
| Set PWM Register update trigger.
static void | PWM_Fault_LatchMode (uint16_t pwmIndex, PWM_LATCH_MODE_t latchMode)
| Set the latch mode of fault PCI.
static void | PWM_Fault_DataMode (uint16_t pwmIndex, PWM_FAULT_DATA_t faultDataMode)
| Set the data mode of fault PCI.

## Detailed Description

This documentation includes functions and data types for the PWM peripheral as an enhancement to the MCC Code Configurator. It provides application-specific PWM functions and includes essential PWM initialization that is not supported by the code generated by MCC.

## Enumeration Type Documentation

## ◆ PWM_EVENT_SOURCE_e

enum PWM_EVENT_SOURCE_e

Enumerator
PWM_EVENT_SOURCE_PGTRGSEL |
PWM_EVENT_SOURCE_PWM_GEN_OUTPUT |
PWM_EVENT_SOURCE_PCI_SYNC_ACTIVE |
PWM_EVENT_SOURCE_PCI_FF_ACTIVE |
PWM_EVENT_SOURCE_PCI_FF_CL_ACTIVE |
PWM_EVENT_SOURCE_PCI_FAULT_ACTIVE |
PWM_EVENT_SOURCE_CAHALF |
PWM_EVENT_SOURCE_STEER |
PWM_EVENT_SOURCE_ADC_TRIG1 |
PWM_EVENT_SOURCE_ADC_TRIG2 |
PWM_EVENT_SOURCE_HR_ERROR_EVENT |

Definition at line 1092 of file drv_mcc_extension_pwm.h.

## ◆ PWM_FAULT_DATA_e

enum PWM_FAULT_DATA_e

Enumerator
PWM_FAULT_EVENT_PWMH |
PWM_FAULT_EVENT_PWML |

Definition at line 1255 of file drv_mcc_extension_pwm.h.

## ◆ PWM_LATCH_MODE_e

enum PWM_LATCH_MODE_e

Enumerator
PWM_SET_DOMINANT_MODE |
PWM_RESET_DOMINANT_MODE |

Definition at line 1200 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_ACCEPTANCE_CRITERIA_e

enum PWM_PCI_ACCEPTANCE_CRITERIA_e

<>

Enumerator
PWM_PCI_ACCEPT_LEVEL_SENSITIVE |
PWM_PCI_ACCEPT_RISING_EDGE |
PWM_PCI_ACCEPT_ANY_EDGE |
PWM_PCI_ACCEPT_LATCHED |
PWM_PCI_ACCEPT_LATCHED_RISING_EDGE |
PWM_PCI_ACCEPT_LATCHED_ANY_EDGE |

Definition at line 29 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_ACCEPTANCE_QUALIFER_e

enum PWM_PCI_ACCEPTANCE_QUALIFER_e

Enumerator
PWM_PCI_ACCEPTANCE_QUALIFER_NONE | No acceptance qualifier is used (qualifier forced to ?1?)
PWM_PCI_ACCEPTANCE_QUALIFER_DUTY | Duty cycle is active (base PWM Generator signal)
PWM_PCI_ACCEPTANCE_QUALIFER_LEB | LEB is active.
PWM_PCI_ACCEPTANCE_QUALIFER_PWM | PWM Generator is triggered.
PWM_PCI_ACCEPTANCE_QUALIFER_PCI_PWMPCI | Selects PCI Source #1 (PWM Generator output selected by the PWMPCI[2:0] bits)
PWM_PCI_ACCEPTANCE_QUALIFER_PCI_SOURCE8 | Selects PCI Source #8.
PWM_PCI_ACCEPTANCE_QUALIFER_PCI_SOURCE9 | Selects PCI Source #9.
PWM_PCI_ACCEPTANCE_QUALIFER_SWPCI | SWPCI control bit only (qualifier forced to ?0?)

Definition at line 868 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_INPUT_e

enum PWM_PCI_INPUT_e

Enumerator
PWM_PCI_INPUT8 |
PWM_PCI_INPUT9 |
PWM_PCI_INPUT10 |
PWM_PCI_INPUT11 |

Definition at line 730 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_SOURCE_e

enum PWM_PCI_SOURCE_e

Enumerator
PWM_PCI_SOURCE_PWM1 |
PWM_PCI_SOURCE_PWM2 |
PWM_PCI_SOURCE_PWM3 |
PWM_PCI_SOURCE_PWM4 |

Definition at line 456 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_SOURCE_SELECT_e

enum PWM_PCI_SOURCE_SELECT_e

Enumerator
PWM_PCI_SOURCE_SELECT_CLC1 |
PWM_PCI_SOURCE_SELECT_CMP3 |
PWM_PCI_SOURCE_SELECT_CMP2 |
PWM_PCI_SOURCE_SELECT_CMP1 |
PWM_PCI_SOURCE_SELECT_PWM_EVENT_D |
PWM_PCI_SOURCE_SELECT_PWM_EVENT_C |
PWM_PCI_SOURCE_SELECT_PWM_EVENT_B |
PWM_PCI_SOURCE_SELECT_PWM_EVENT_A |
PWM_PCI_SOURCE_SELECT_PCI22 |
PWM_PCI_SOURCE_SELECT_PCI21 | ‍device pin
PWM_PCI_SOURCE_SELECT_PCI20 | ‍device pin
PWM_PCI_SOURCE_SELECT_PCI19 | ‍device pin
PWM_PCI_SOURCE_SELECT_PCI18R | ‍device pin
PWM_PCI_SOURCE_SELECT_PCI17R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI16R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI15R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI14R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI13R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI12R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI11R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI10R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI9R | ‍RPn input
PWM_PCI_SOURCE_SELECT_PCI8R | ‍RPn input
PWM_PCI_SOURCE_SELECT_COMBO_TRIG_B |
PWM_PCI_SOURCE_SELECT_COMBO_TRIG_A |
PWM_PCI_SOURCE_SELECT_PWMPCI_MUX |
PWM_PCI_SOURCE_SELECT_TIED_TO_0 |

Definition at line 779 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_TERM_e

enum PWM_PCI_TERM_e

Enumerator
PWM_PCI_TERM_MANUAL | Manual Terminate: Terminate on a write of ?1? to the SWTERM bit location.
PWM_PCI_TERM_AUTO | Auto-Terminate: Terminate when PCI source transitions from active to inactive.
PWM_PCI_TERM_PGxTRIGA | PGxTRIGA trigger event.
PWM_PCI_TERM_PGxTRIGB | PGxTRIGB trigger event.
PWM_PCI_TERM_PGxTRIGC | PGxTRIGC trigger event.
PWM_PCI_TERM_PCI_SOURCE1 | Selects PCI Source #1 (PWM Generator output selected by the PWMPCI[2:0] bits)
PWM_PCI_TERM_PCI_SOURCE8 | Selects PCI Source #8.
PWM_PCI_TERM_PCI_SOURCE9 | Selects PCI Source #9.

Definition at line 986 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_TERMTIME_AFTER_EVENT_e

enum PWM_PCI_TERMTIME_AFTER_EVENT_e

<>

Enumerator
PWM_PCI_TERMTIME_AFTER_EVENT_AT_EOC |
PWM_PCI_TERMTIME_AFTER_EVENT_IMMEDIATE |

Definition at line 182 of file drv_mcc_extension_pwm.h.

## ◆ PWM_SOCS_e

enum PWM_SOCS_e

Enumerator
PWM_SOCS_SELF_TRIGGER |
PWM_SOCS_PG1_OR_PG5 |
PWM_SOCS_PG2_OR_PG6 |
PWM_SOCS_PG3_OR_PG7 |
PWM_SOCS_PG4_OR_PG8 |
PWM_SOCS_TRIG_OR_PCI_SYNC |

Definition at line 285 of file drv_mcc_extension_pwm.h.

## ◆ PWM_TRIG_MODE_e

enum PWM_TRIG_MODE_e

Enumerator
PWM_TRIG_MODE_SINGLE |
PWM_TRIG_MODE_RETRIGGERABLE |

Definition at line 931 of file drv_mcc_extension_pwm.h.

## ◆ PWM_UPDMOD_e

enum PWM_UPDMOD_e

Enumerator
PWM_UPDMOD_SOC |
PWM_UPDMOD_IMMEDIATE |
PWM_UPDMOD_CLIENT_SOC |
PWM_UPDMOD_CLIENT_IMMEDIATE |

Definition at line 395 of file drv_mcc_extension_pwm.h.

## ◆ PWM_UPDTRG_e

enum PWM_UPDTRG_e

Enumerator
PWM_UPDTRG_MANUAL | user must manual set UPDREQ bit to update
PWM_UPDTRG_PGxDC | a write to PGxDC will update
PWM_UPDTRG_PGxPHASE | a write to PGxPHASE will update
PWM_UPDTRG_PGxTRIGA | a write to PGxTRIGA will update

Definition at line 1142 of file drv_mcc_extension_pwm.h.

## ◆ RPnR_SOURCE_e

enum RPnR_SOURCE_e

Enumerator
RPnR_SOURCE_DefaultPORT | RPn tied to Default Pin.
RPnR_SOURCE_U1TX | RPn tied to UART1 Transmit.
RPnR_SOURCE_U1RTS | RPn tied to UART1 Request-to-Send.
RPnR_SOURCE_U2TX | RPn tied to UART2 Transmit.
RPnR_SOURCE_U2RTS | RPn tied to UART2 Request-to-Send.
RPnR_SOURCE_SDO1 | RPn tied to SPI1 Data Output.
RPnR_SOURCE_SCK1 | RPn tied to SPI1 Clock Output.
RPnR_SOURCE_SS1 | RPn tied to SPI1 Client Select.
RPnR_SOURCE_SDO2 | RPn tied to SPI2 Data Output.
RPnR_SOURCE_SCK2 | RPn tied to SPI2 Clock Output.
RPnR_SOURCE_SS2 | RPn tied to SPI2 Client Select.
RPnR_SOURCE_SDO3 | RPn tied to SPI3 Data Output.
RPnR_SOURCE_SCK3 | RPn tied to SPI3 Clock Output.
RPnR_SOURCE_SS3 | RPn tied to SPI3 Client Select.
RPnR_SOURCE_REFCLKO | RPn tied to Reference Clock Output.
RPnR_SOURCE_OCM1 | RPn tied to SCCP1 Output.
RPnR_SOURCE_OCM2 | RPn tied to SCCP2 Output.
RPnR_SOURCE_OCM3 | RPn tied to SCCP3 Output.
RPnR_SOURCE_OCM4 | RPn tied to SCCP4 Output.
RPnR_SOURCE_OCM5 | RPn tied to SCCP5 Output.
RPnR_SOURCE_OCM6 | RPn tied to SCCP6 Output.
RPnR_SOURCE_CAN1TX | RPn tied to CAN1 Transmit.
RPnR_SOURCE_CMP1 | RPn tied to Comparator 1 Output.
RPnR_SOURCE_CMP2 | RPn tied to Comparator 2 Output.
RPnR_SOURCE_CMP3 | RPn tied to Comparator 3 Output.
RPnR_SOURCE_U3TX | RPn tied to UART3 Transmit.
RPnR_SOURCE_U3RTS | RPn tied to UART3 Request-to-Send.
RPnR_SOURCE_PWM4H | RPn tied to PWM4H Output.
RPnR_SOURCE_PWM4L | RPn tied to PWM4L Output.
RPnR_SOURCE_PWMEA | RPn tied to PWM Event A Output.
RPnR_SOURCE_PWMEB | RPn tied to PWM Event B Output.
RPnR_SOURCE_QEICMP1 | RPn tied to QEI1 Comparator Output.
RPnR_SOURCE_QEICMP2 | RPn tied to QEI2 Comparator Output.
RPnR_SOURCE_CLC1OUT | RPn tied to CLC1 Output.
RPnR_SOURCE_CLC2OUT | RPn tied to CLC2 Output.
RPnR_SOURCE_OCM7 | RPn tied to SCCP7 Output.
RPnR_SOURCE_OCM8 | RPn tied to SCCP8 Output.
RPnR_SOURCE_PWMEC | RPn tied to PWM Event C Output.
RPnR_SOURCE_PWMED | RPn tied to PWM Event D Output.
RPnR_SOURCE_PTGTRG24 | PTG Trigger Output 24.
RPnR_SOURCE_PTGTRG25 | PTG Trigger Output 25.
RPnR_SOURCE_SENT1OUT | RPn tied to SENT1 Output.
RPnR_SOURCE_SENT2OUT | RPn tied to SENT2 Output.
RPnR_SOURCE_MCCP9A | RPn tied to MCCP9 Output A.
RPnR_SOURCE_MCCP9B | RPn tied to MCCP9 Output B.
RPnR_SOURCE_MCCP9C | RPn tied to MCCP9 Output C.
RPnR_SOURCE_MCCP9D | RPn tied to MCCP9 Output D.
RPnR_SOURCE_MCCP9E | RPn tied to MCCP9 Output E.
RPnR_SOURCE_MCCP9F | RPn tied to MCCP9 Output F.
RPnR_SOURCE_CLC3OUT | RPn tied to CLC4 Output.
RPnR_SOURCE_CLC4OUT | RPn tied to CLC4 Output.
RPnR_SOURCE_U1DTR | RPn tied to UART1 DTR.
RPnR_SOURCE_U2DTR | RPn tied to UART2 DTR.
RPnR_SOURCE_U3DTR | RPn tied to UART3 DTR

Definition at line 520 of file drv_mcc_extension_pwm.h.

## ◆ RPnR_VIRTUAL_PIN_e

enum RPnR_VIRTUAL_PIN_e

Enumerator
RPnR_VIRTUAL_PIN_RP176 |
RPnR_VIRTUAL_PIN_RP177 |
RPnR_VIRTUAL_PIN_RP178 |
RPnR_VIRTUAL_PIN_RP179 |
RPnR_VIRTUAL_PIN_RP180 |
RPnR_VIRTUAL_PIN_RP181 |

Definition at line 584 of file drv_mcc_extension_pwm.h.

## ◆ RPx_INPUT_e

enum RPx_INPUT_e

Enumerator
RPx_INPUT_VSS | Internal.
RPx_INPUT_CMP1 | Internal.
RPx_INPUT_CMP2 | Internal.
RPx_INPUT_CMP3 | Internal.
RPx_INPUT_PTG_TRIG_26 | Internal.
RPx_INPUT_PTG_TRIG_27 | Internal.
RPx_INPUT_PWM_EVENT_C | Internal.
RPx_INPUT_PWM_EVENT_D | Internal.
RPx_INPUT_PWM_EVENT_E | Internal.
RPx_INPUT_RP32 | Port Pin RB0.
RPx_INPUT_RP33 | Port Pin RB1.
RPx_INPUT_RP34 | Port Pin RB2.
RPx_INPUT_RP35 | Port Pin RB3.
RPx_INPUT_RP36 | Port Pin RB4.
RPx_INPUT_RP37 | Port Pin RB5.
RPx_INPUT_RP38 | Port Pin RB6.
RPx_INPUT_RP39 | Port Pin RB7.
RPx_INPUT_RP40 | Port Pin RB8.
RPx_INPUT_RP41 | Port Pin RB9.
RPx_INPUT_RP42 | Port Pin RB10.
RPx_INPUT_RP43 | Port Pin RB11.
RPx_INPUT_RP44 | Port Pin RB12.
RPx_INPUT_RP45 | Port Pin RB13.
RPx_INPUT_RP46 | Port Pin RB14.
RPx_INPUT_RP47 | Port Pin RB15.
RPx_INPUT_RP48 | Port Pin RC0.
RPx_INPUT_RP49 | Port Pin RC1.
RPx_INPUT_RP50 | Port Pin RC2.
RPx_INPUT_RP51 | Port Pin RC3.
RPx_INPUT_RP52 | Port Pin RC4.
RPx_INPUT_RP53 | Port Pin RC5.
RPx_INPUT_RP54 | Port Pin RC6.
RPx_INPUT_RP55 | Port Pin RC7.
RPx_INPUT_RP56 | Port Pin RC8.
RPx_INPUT_RP57 | Port Pin RC9.
RPx_INPUT_RP58 | Port Pin RC10.
RPx_INPUT_RP59 | Port Pin RC11.
RPx_INPUT_RP60 | Port Pin RC12.
RPx_INPUT_RP61 | Port Pin RC13.
RPx_INPUT_RP62 | Port Pin RC14.
RPx_INPUT_RP63 | Port Pin RC15.
RPx_INPUT_RP64 | Port Pin RD0.
RPx_INPUT_RP65 | Port Pin RD1.
RPx_INPUT_RP66 | Port Pin RD2.
RPx_INPUT_RP67 | Port Pin RD3.
RPx_INPUT_RP68 | Port Pin RD4.
RPx_INPUT_RP69 | Port Pin RD5.
RPx_INPUT_RP70 | Port Pin RD6.
RPx_INPUT_RP71 | Port Pin RD7.
RPx_INPUT_RP72 | Port Pin RD8.
RPx_INPUT_RP73 | Port Pin RD9.
RPx_INPUT_RP74 | Port Pin RD10.
RPx_INPUT_RP75 | Port Pin RD11.
RPx_INPUT_RP76 | Port Pin RD12.
RPx_INPUT_RP77 | Port Pin RD13.
RPx_INPUT_RP78 | Port Pin RD14.
RPx_INPUT_RP79 | Port Pin RD15.
RPx_INPUT_DAC3_pwm_req_on | Internal.
RPx_INPUT_DAC3_pwm_req_off | Internal.
RPx_INPUT_DAC2_pwm_req_on | Internal.
RPx_INPUT_DAC2_pwm_req_off | Internal.
RPx_INPUT_DAC1_pwm_req_on | Internal.
RPx_INPUT_DAC1_pwm_req_off | Internal.
RPx_INPUT_RP176 | Virtual RPV0.
RPx_INPUT_RP177 | Virtual RPV1.
RPx_INPUT_RP178 | Virtual RPV2.
RPx_INPUT_RP179 | Virtual RPV3.
RPx_INPUT_RP180 | Virtual RPV4.
RPx_INPUT_RP181 | Virtual RPV5.

Definition at line 652 of file drv_mcc_extension_pwm.h.

## Function Documentation

## ◆ DRV_Config_Custom_PWM()

static __inline__ void DRV_Config_Custom_PWM | ( | void |  | ) |
| static

<>

Returns
  void

This PWM initialization configures the PWM modules to be retriggerable for the cascaded PWM approach. Additionally, two PWM outputs were swapped to support the board's functionality.

Definition at line 25 of file drv_custom_config_pwm.h.

Here is the call graph for this function:
Here is the caller graph for this function:

## ◆ PWM_Data_Update_Mode()

static void PWM_Data_Update_Mode | ( | uint16_t | pwmIndex,
|  | PWM_UPDMOD_t | updateMode
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  updateMode | Pointer to a power control data object of type PWM_UPDMOD_t

Returns
  void

This function is used for register update synchronization between PWMs. Setting the MSTEN bit means that the UPDREQ flag is broadcast to other PWMs. If the UPDMOD field in the receiving PWM is set to "Client SOC" or "client immediate" then this will take effect and data update between different PWM modules can be implemented

Definition at line 417 of file drv_mcc_extension_pwm.h.

## ◆ PWM_Data_Update_Trigger()

static void PWM_Data_Update_Trigger | ( | uint16_t | pwmIndex,
|  | PWM_UPDTRG_t | updateTrigger
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  updateTrigger | Pointer to a power control data object of type PWM_UPDTRG_t

Returns
  void

This function configures the PWM Event Trigger source for a particular PWM instance.

Definition at line 1161 of file drv_mcc_extension_pwm.h.

## ◆ PWM_EVENTA_Configure()

static void PWM_EVENTA_Configure | ( | uint16_t | pwmSource,
|  | PWM_EVENT_SOURCE_t | eventSource,
|  | bool | invert,
|  | bool | outputEnable,
|  | bool | stretchDisable,
|  | bool | outputSync
| ) |  |
| inlinestatic

Parameters

  pwmSource | PWM instance
  eventSource | Pointer to a power control data object of type PWM_EVENT_SOURCE_t
  invert | PWM Event Output Polarity
  outputEnable | PWM Event Output Enable
  stretchDisable | PWM Event Output Stretch Disable
  outputSync | PWM Event Output Sync

Returns
  void

This function configures the PWM Event A (PWM event Output Control register).

Definition at line 1121 of file drv_mcc_extension_pwm.h.

## ◆ PWM_Fault_DataMode()

static void PWM_Fault_DataMode | ( | uint16_t | pwmIndex,
|  | PWM_FAULT_DATA_t | faultDataMode
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  latch | Pointer to a power control data object of type PWM_FAULT_DATA_t

Returns
  void

This function configures the PWM instance data mode for fault PCI.

Definition at line 1271 of file drv_mcc_extension_pwm.h.

Here is the caller graph for this function:

## ◆ PWM_Fault_LatchMode()

static void PWM_Fault_LatchMode | ( | uint16_t | pwmIndex,
|  | PWM_LATCH_MODE_t | latchMode
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  latch | Pointer to a power control data object of type PWM_LATCH_MODE_t

Returns
  void

This function configures the PWM instance latch mode for fault PCI.

Definition at line 1216 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Fault_AcceptanceCriteria()

static void PWM_PCI_Fault_AcceptanceCriteria | ( | uint16_t | pwmIndex,
|  | PWM_PCI_ACCEPTANCE_CRITERIA_t | acpSetting
| ) |  |
| inlinestatic

<>

Parameters

  pwmIndex | PWM instance
  acpSetting | Pointer to a power control data object of type PWM_PCI_ACCEPTANCE_CRITERIA_t

Returns
  void

This function sets the PCI fault Acceptance Criteria.

Definition at line 51 of file drv_mcc_extension_pwm.h.

Here is the caller graph for this function:

## ◆ PWM_PCI_Fault_AcceptanceQualiferInvert()

static void PWM_PCI_Fault_AcceptanceQualiferInvert | ( | uint16_t | pwmIndex,
|  | bool | invert
| ) |  |
| inlinestatic

<>

Parameters

  pwmIndex | PWM instance
  invert | Inverts the polarity

Returns
  void

This function configures the polarity of the PCI fault acceptance qualifier.

Definition at line 98 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Fault_AcceptanceQualifierSource()

static void PWM_PCI_Fault_AcceptanceQualifierSource | ( | uint16_t | pwmIndex,
|  | PWM_PCI_ACCEPTANCE_QUALIFER_t | source
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  source | Pointer to a power control data object of type PWM_PCI_ACCEPTANCE_QUALIFER_t

Returns
  void

This function sets the PWM PCI Fault Acceptance qualifier source for a specific PWM instance.

Definition at line 892 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Fault_TimetoTerminateAfterEvent()

static void PWM_PCI_Fault_TimetoTerminateAfterEvent | ( | uint16_t | pwmIndex,
|  | PWM_PCI_TERMTIME_AFTER_EVENT_t | faultTerm
| ) |  |
| inlinestatic

<>

Parameters

  pwmIndex | PWM instance
  acpSetting | Pointer to a power control data object of type PWM_PCI_TERMTIME_AFTER_EVENT_t

Returns
  void

This function the Termination Synchronization bit for a particular PWM Fault PCI instance.

Definition at line 199 of file drv_mcc_extension_pwm.h.

Here is the caller graph for this function:

## ◆ PWM_PCI_INPUT_MaptoPin()

static void PWM_PCI_INPUT_MaptoPin | ( | PWM_PCI_INPUT_t | pciIndex,
|  | RPx_INPUT_t | pin
| ) |  |
| inlinestatic

Parameters

  pciIndex | Pointer to a power control data object of type PWM_PCI_INPUT_t
  pin | Pointer to a power control data object of type RPx_INPUT_t

Returns
  void

This function maps thePCI input to a particular pin.

Definition at line 748 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Source1()

static void PWM_PCI_Source1 | ( | uint16_t | pwmIndex,
|  | PWM_PCI_SOURCE_t | pciSource
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  pciSource | Pointer to a power control data object of type PWM_PCI_SOURCE_t

Returns
  void

The selected PWM Generator source does not affect the LEB counter. This source can be optionally used as a PCI input, PCI qualifier, PCI terminator or PCI terminator qualifier

Definition at line 481 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Sync_AcceptanceCriteria()

static void PWM_PCI_Sync_AcceptanceCriteria | ( | uint16_t | pwmIndex,
|  | PWM_PCI_ACCEPTANCE_CRITERIA_t | acpSetting
| ) |  |
| inlinestatic

<>

Parameters

  pwmIndex | PWM instance
  acpSetting | Pointer to a power control data object of type PWM_PCI_ACCEPTANCE_CRITERIA_t

Returns
  void

This function configures the PCI Synchronization Acceptance Criteria.

Definition at line 142 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Sync_Source_Select()

static void PWM_PCI_Sync_Source_Select | ( | uint16_t | pwmIndex,
|  | PWM_PCI_SOURCE_SELECT_t | pciSource
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  pciSource | Pointer to a power control data object of type PWM_PCI_SOURCE_SELECT_t

Returns
  void

This function set the PWM PCI Synchronization source.

Definition at line 827 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Sync_TerminationEventSelect()

static void PWM_PCI_Sync_TerminationEventSelect | ( | uint16_t | pwmIndex,
|  | PWM_PCI_TERM_t | termEvent
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  termEvent | Pointer to a power control data object of type PWM_PCI_TERM_t

Returns
  void

This function configures the PWM PCI Synchronization Termination event.

Definition at line 1008 of file drv_mcc_extension_pwm.h.

## ◆ PWM_PCI_Sync_TimetoTerminateAfterEvent()

static void PWM_PCI_Sync_TimetoTerminateAfterEvent | ( | uint16_t | pwmIndex,
|  | PWM_PCI_TERMTIME_AFTER_EVENT_t | faultTerm
| ) |  |
| inlinestatic

<>

Parameters

  pwmIndex | PWM instance
  acpSetting | Pointer to a power control data object of type PWM_PCI_TERMTIME_AFTER_EVENT_t

Returns
  void

This function the Termination Synchronization bit for a particular PWM Synchronization PCI instance.

Definition at line 245 of file drv_mcc_extension_pwm.h.

## ◆ PWM_StartOfCycleTrigger()

static void PWM_StartOfCycleTrigger | ( | uint16_t | pwmIndex,
|  | PWM_SOCS_t | triggerSource
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  triggerSource | Pointer to a power control data object of type PWM_SOCS_t

Returns
  void

This function set the start-of-cycle of a particular PWM instance.

Definition at line 305 of file drv_mcc_extension_pwm.h.

## ◆ PWM_Swap_PWMxL_and_PWMxH()

static void PWM_Swap_PWMxL_and_PWMxH | ( | uint16_t | pwmIndex,
|  | bool | swapPWMH_PWML
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  swapPWMH_PWML | enable/disable the PWM instance output swap bit

Returns
  void

This function configures the PWM output as swapped output (PWMH output -> PWML output; PWML output -> PWMH output).

Definition at line 1053 of file drv_mcc_extension_pwm.h.

Here is the caller graph for this function:

## ◆ PWM_Trigger_Mode()

static void PWM_Trigger_Mode | ( | uint16_t | pwmIndex,
|  | PWM_TRIG_MODE_t | trigMode
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  trigMode | Pointer to a power control data object of type PWM_TRIG_MODE_t

Returns
  void

This function configures the PWM instance trigger mode.

Definition at line 947 of file drv_mcc_extension_pwm.h.

Here is the caller graph for this function:

## ◆ PWM_UPDREQ_Broadcast_Enable()

static void PWM_UPDREQ_Broadcast_Enable | ( | uint16_t | pwmIndex,
|  | bool | enable
| ) |  |
| inlinestatic

Parameters

  pwmIndex | PWM instance
  enable | enable the Master bit of a PWM instance

Returns
  void

This function is used for register update synchronization between PWMs. Setting the MSTEN bit means that the UPDREQ flag is broadcast to other PWMs. If the UPDMOD field in the receiving PWM is set to "Client SOC" or "client immediate" then this will take effect and data update between different PWM modules can be implemented

Definition at line 353 of file drv_mcc_extension_pwm.h.

## ◆ RPnR_VirtualPin_Source()

static void RPnR_VirtualPin_Source | ( | RPnR_VIRTUAL_PIN_t | virtualPin,
|  | RPnR_SOURCE_t | peripheral
| ) |  |
| inlinestatic

Parameters

  virtualPin | Pointer to a power control data object of type RPnR_VIRTUAL_PIN_t
  peripheral | Pointer to a power control data object of type RPnR_SOURCE_t

Returns
  void

These pins provide a simple way for inter-peripheral connection without utilizing a physical pin. For example, the output of the analog comparator can be connected to RP176 and the PWM Fault input can be configured for RP176 as well. This configuration allows the analog comparator to trigger PWM Faults without the use of an actual physical pin on the device

Definition at line 610 of file drv_mcc_extension_pwm.h.