Functions | |
void | timer4_compare_output_A_mode_set (uint8_t mode) |
void | timer4_compare_output_B_mode_set (uint8_t mode) |
void | timer4_compare_output_C_mode_set (uint8_t mode) |
void | timer4_config (uint8_t config) |
uint16_t | timer4_output_compare_A_read (void) |
void | timer4_output_compare_A_set (uint16_t val) |
uint16_t | timer4_output_compare_B_read (void) |
void | timer4_output_compare_B_set (uint16_t val) |
uint16_t | timer4_output_compare_C_read (void) |
void | timer4_output_compare_C_set (uint16_t val) |
void | timer4_output_compare_config (uint8_t config) |
uint16_t | timer4_read (void) |
void | timer4_set (uint16_t val) |
void | timer4_enable (void) |
void | timer4_disable (void) |
void timer4_compare_output_A_mode_set | ( | uint8_t | mode | ) |
Configure the timer 4 compare output A mode.
mode | One of: TIMER16B_COMPARE_OUTPUT_MODE_NORMAL: Normal operation TIMER16B_COMPARE_OUTPUT_MODE_TOGGLE: Toggle on output compare TIMER16B_COMPARE_OUTPUT_MODE_CLEAR: Clear on output compare TIMER16B_COMPARE_OUTPUT_MODE_SET: Set on output compare |
Only available for the following processors:
void timer4_compare_output_B_mode_set | ( | uint8_t | mode | ) |
Configure the timer 4 compare output B mode.
mode | One of: TIMER16B_COMPARE_OUTPUT_MODE_NORMAL: Normal operation TIMER16B_COMPARE_OUTPUT_MODE_TOGGLE: Toggle on output compare TIMER16B_COMPARE_OUTPUT_MODE_CLEAR: Clear on output compare TIMER16B_COMPARE_OUTPUT_MODE_SET: Set on output compare |
Only available for the following processors:
void timer4_compare_output_C_mode_set | ( | uint8_t | mode | ) |
Configure the timer 4 compare output C mode.
mode | One of: TIMER16B_COMPARE_OUTPUT_MODE_NORMAL: Normal operation TIMER16B_COMPARE_OUTPUT_MODE_TOGGLE: Toggle on output compare TIMER16B_COMPARE_OUTPUT_MODE_CLEAR: Clear on output compare TIMER16B_COMPARE_OUTPUT_MODE_SET: Set on output compare |
Only available for the following processors:
void timer4_config | ( | uint8_t | config | ) |
Determine the clock source for timer 4
config | One of: TIMER1_NOCLK: no input clock TIMER4_NOPRE: No prescalar TIMER4_PRE_8: Prescalar of 8 TIMER4_PRE_64: Prescalar of 64 TIMER4_PRE_256: Prescalar of 256 TIMER4_PRE_1024: Prescalar of 1024 TIMER4_EXT_FALLING: Count on falling edge of external pin T4 TIMER4_EXT_RISING: Count on rising edge of external pin T4 |
Only available for the following processors:
void timer4_disable | ( | void | ) | [inline] |
Disable the timer 4 overflow interrupt.
void timer4_enable | ( | void | ) | [inline] |
Enable the timer 4 overflow interrupt.
uint16_t timer4_output_compare_A_read | ( | void | ) |
Read the state of the timer 4 output compare unit A register.
Note: this implementation is thread safe.
Only available for the following processors:
void timer4_output_compare_A_set | ( | uint16_t | val | ) |
Set the state of the timer 4 output compare unit A register.
Note: this implementation is thread safe.
val | The new value of the timer 4 output compare unit A register. |
Only available for the following processors:
uint16_t timer4_output_compare_B_read | ( | void | ) |
Read the state of the timer 4 output compare unit B register.
Note: this implementation is thread safe.
Only available for the following processors:
void timer4_output_compare_B_set | ( | uint16_t | val | ) |
Set the state of the timer 4 output compare unit B register.
Note: this implementation is thread safe.
val | The new value of the timer 4 output compare unit B register. |
Only available for the following processors:
uint16_t timer4_output_compare_C_read | ( | void | ) |
Read the state of the timer 4 output compare unit C register.
Note: this implementation is thread safe.
Only available for the following processors:
void timer4_output_compare_C_set | ( | uint16_t | val | ) |
Set the state of the timer 4 output compare unit C register.
Note: this implementation is thread safe.
val | The new value of the timer 4 output compare unit C register. |
Only available for the following processors:
void timer4_output_compare_config | ( | uint8_t | config | ) |
Configure the timer 4 output compare unit.
config | One of: TIMER4_OUTPUT_COMPARE_CONFIG_NORMAL: Normal operation TIMER4_OUTPUT_COMPARE_CONFIG_PWM_PC_08: PWM, Phase Correct, 8-bit TIMER4_OUTPUT_COMPARE_CONFIG_PWM_PC_09: PWM, Phase Correct, 9-bit TIMER4_OUTPUT_COMPARE_CONFIG_PWM_PC_10: PWM, Phase Correct, 10-bit TIMER4_OUTPUT_COMPARE_CONFIG_CTC_OCR4A: CTC, Top = OCRA4 TIMER4_OUTPUT_COMPARE_CONFIG_PWM_F_08: Fast PWM, 8-bit TIMER4_OUTPUT_COMPARE_CONFIG_PWM_F_09: Fast PWM, 9-bit TIMER4_OUTPUT_COMPARE_CONFIG_PWM_F_10: Fast PWM, 10-bit TIMER4_OUTPUT_COMPARE_CONFIG_PWM_PFC_ICR4: PWM, Phase and Frequency Correct, Top = ICR4 TIMER4_OUTPUT_COMPARE_CONFIG_PWM_PFC_OCR4A: PWM, Phase and Frequency Correct, Top = OCR4A TIMER4_OUTPUT_COMPARE_CONFIG_PWM_PC_ICR4: PWM, Phase Correct, Top = ICR4 TIMER4_OUTPUT_COMPARE_CONFIG_PWM_PC_OCR4A: PWM, Phase Correct, Top = OCR4A TIMER4_OUTPUT_COMPARE_CONFIG_CTC_ICR4: CTC, Top = ICR4 TIMER4_OUTPUT_COMPARE_CONFIG_PWM_F_ICR4: Fast PWM, Top = ICR4 TIMER4_OUTPUT_COMPARE_CONFIG_PWM_F_OCR4A: Fast PWM, Top = OCR4A |
Only available for the following processors:
uint16_t timer4_read | ( | void | ) |
Read the state of the timer 4 counter.
Note: this implementation is thread safe.
Only available for the following processors:
void timer4_set | ( | uint16_t | val | ) |
Set the state of the timer 4 counter
Note: this implementation is thread safe.
val | The new value of the timer 4 counter. |
Only available for the following processors: