Timer 5 (only available for processors with Timer 5)

Functions

void timer5_compare_output_A_mode_set (uint8_t mode)
void timer5_compare_output_B_mode_set (uint8_t mode)
void timer5_compare_output_C_mode_set (uint8_t mode)
void timer5_config (uint8_t config)
uint16_t timer5_output_compare_A_read (void)
void timer5_output_compare_A_set (uint16_t val)
uint16_t timer5_output_compare_B_read (void)
void timer5_output_compare_B_set (uint16_t val)
uint16_t timer5_output_compare_C_read (void)
void timer5_output_compare_C_set (uint16_t val)
void timer5_output_compare_config (uint8_t config)
uint16_t timer5_read (void)
void timer5_set (uint16_t val)
void timer5_enable (void)
void timer5_disable (void)

Function Documentation

void timer5_compare_output_A_mode_set ( uint8_t  mode  ) 

Configure the timer 5 compare output A mode.

Parameters:
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
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_compare_output_B_mode_set ( uint8_t  mode  ) 

Configure the timer 5 compare output B mode.

Parameters:
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
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_compare_output_C_mode_set ( uint8_t  mode  ) 

Configure the timer 5 compare output C mode.

Parameters:
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
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_config ( uint8_t  config  ) 

Determine the clock source for timer 5

Parameters:
config One of:
TIMER1_NOCLK: no input clock
TIMER5_NOPRE: No prescalar
TIMER5_PRE_8: Prescalar of 8
TIMER5_PRE_64: Prescalar of 64
TIMER5_PRE_256: Prescalar of 256
TIMER5_PRE_1024: Prescalar of 1024
TIMER5_EXT_FALLING: Count on falling edge of external pin T5
TIMER5_EXT_RISING: Count on rising edge of external pin T5
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_disable ( void   )  [inline]

Disable the timer 5 overflow interrupt.

Author:
Andrew H. Fagg
void timer5_enable ( void   )  [inline]

Enable the timer 5 overflow interrupt.

Author:
Andrew H. Fagg
uint16_t timer5_output_compare_A_read ( void   ) 

Read the state of the timer 5 output compare unit A register.

Note: this implementation is thread safe.

Returns:
The current state of the timer 5 output compare unit A register.
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_output_compare_A_set ( uint16_t  val  ) 

Set the state of the timer 5 output compare unit A register.

Note: this implementation is thread safe.

Parameters:
val The new value of the timer 5 output compare unit A register.
Author:
Andrew H. Fagg

Only available for the following processors:

uint16_t timer5_output_compare_B_read ( void   ) 

Read the state of the timer 5 output compare unit B register.

Note: this implementation is thread safe.

Returns:
The current state of the timer 5 output compare unit B register.
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_output_compare_B_set ( uint16_t  val  ) 

Set the state of the timer 5 output compare unit B register.

Note: this implementation is thread safe.

Parameters:
val The new value of the timer 5 output compare unit B register.
Author:
Andrew H. Fagg

Only available for the following processors:

uint16_t timer5_output_compare_C_read ( void   ) 

Read the state of the timer 5 output compare unit C register.

Note: this implementation is thread safe.

Returns:
The current state of the timer 5 output compare unit C register.
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_output_compare_C_set ( uint16_t  val  ) 

Set the state of the timer 5 output compare unit C register.

Note: this implementation is thread safe.

Parameters:
val The new value of the timer 5 output compare unit C register.
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_output_compare_config ( uint8_t  config  ) 

Configure the timer 5 output compare unit.

Parameters:
config One of:
TIMER5_OUTPUT_COMPARE_CONFIG_NORMAL: Normal operation
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_PC_08: PWM, Phase Correct, 8-bit
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_PC_09: PWM, Phase Correct, 9-bit
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_PC_10: PWM, Phase Correct, 10-bit
TIMER5_OUTPUT_COMPARE_CONFIG_CTC_OCR5A: CTC, Top = OCRA5
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_F_08: Fast PWM, 8-bit
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_F_09: Fast PWM, 9-bit
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_F_10: Fast PWM, 10-bit
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_PFC_ICR5: PWM, Phase and Frequency Correct, Top = ICR5
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_PFC_OCR5A: PWM, Phase and Frequency Correct, Top = OCR5A
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_PC_ICR5: PWM, Phase Correct, Top = ICR5
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_PC_OCR5A: PWM, Phase Correct, Top = OCR5A
TIMER5_OUTPUT_COMPARE_CONFIG_CTC_ICR5: CTC, Top = ICR5
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_F_ICR5: Fast PWM, Top = ICR5
TIMER5_OUTPUT_COMPARE_CONFIG_PWM_F_OCR5A: Fast PWM, Top = OCR5A
Author:
Andrew H. Fagg

Only available for the following processors:

uint16_t timer5_read ( void   ) 

Read the state of the timer 5 counter.

Note: this implementation is thread safe.

Returns:
The current state of the timer 5 counter
Author:
Andrew H. Fagg

Only available for the following processors:

void timer5_set ( uint16_t  val  ) 

Set the state of the timer 5 counter

Note: this implementation is thread safe.

Parameters:
val The new value of the timer 5 counter.
Author:
Andrew H. Fagg

Only available for the following processors:

Generated on Tue Feb 14 00:23:58 2012 for OU Atmel Utilities Library by  doxygen 1.6.3