Timer unit with 8Bit counter and one output compare unit. More...
#include <hwtimer.h>
Public Member Functions | |
HWTimer8_1C (AvrDevice *core, PrescalerMultiplexer *p, int unit, IRQLine *tov, IRQLine *tcompA, PinAtPort *outA) | |
void | Reset (void) |
Perform a reset of this unit. | |
Public Attributes | |
IOReg< HWTimer8_1C > | tccr_reg |
control register | |
Protected Member Functions | |
void | Set_TCCR (unsigned char val) |
Register access to set control register. | |
unsigned char | Get_TCCR () |
Register access to read control register. | |
Protected Attributes | |
unsigned char | tccr_val |
register value TCCR |
Timer unit with 8Bit counter and one output compare unit.
This timer unit is used by following devices: ATMega128.
TCCRx register contains the following configuration bits (x=timer):
+----+-----+-----+-----+-----+----+----+----+ |FOCx|WGMx0|COMx1|COMx0|WGMx1|CSx2|CSx1|CSx0| +----+-----+-----+-----+-----+----+----+----+
Definition at line 358 of file hwtimer.h.
HWTimer8_1C::HWTimer8_1C | ( | AvrDevice * | core, | |
PrescalerMultiplexer * | p, | |||
int | unit, | |||
IRQLine * | tov, | |||
IRQLine * | tcompA, | |||
PinAtPort * | outA | |||
) |
Definition at line 907 of file hwtimer.cpp.
unsigned char HWTimer8_1C::Get_TCCR | ( | ) | [inline, protected] |
void HWTimer8_1C::Reset | ( | void | ) | [virtual] |
Perform a reset of this unit.
Reimplemented from HWTimer8.
Definition at line 937 of file hwtimer.cpp.
References tccr_val.
void HWTimer8_1C::Set_TCCR | ( | unsigned char | val | ) | [protected] |
Register access to set control register.
Definition at line 917 of file hwtimer.cpp.
References HWTimer8::ChangeWGM(), BasicTimerUnit::SetClockMode(), BasicTimerUnit::SetCompareOutput(), BasicTimerUnit::SetCompareOutputMode(), tccr_val, BasicTimerUnit::wgm, BasicTimerUnit::WGM_CTC_OCRA, BasicTimerUnit::WGM_FASTPWM_8BIT, BasicTimerUnit::WGM_NORMAL, BasicTimerUnit::WGM_PCPWM_8BIT, and BasicTimerUnit::WGMisPWM().
control register
Definition at line 369 of file hwtimer.h.
Referenced by AvrDevice_at90canbase::AvrDevice_at90canbase(), AvrDevice_atmega128::AvrDevice_atmega128(), and AvrDevice_atmega16_32::AvrDevice_atmega16_32().
unsigned char HWTimer8_1C::tccr_val [protected] |
register value TCCR
Definition at line 361 of file hwtimer.h.
Referenced by Get_TCCR(), Reset(), and Set_TCCR().