Timer/Counter
[AT91 Support]

Collaboration diagram for Timer/Counter:

Detailed Description

Timer / Counter registers.


Timer Counter Control Register



#define TC0_CCR   (TC_BASE + 0x00)
 Channel 0 control register address.
#define TC1_CCR   (TC_BASE + 0x40)
 Channel 1 control register address.
#define TC2_CCR   (TC_BASE + 0x80)
 Channel 2 control register address.
#define TC_CLKEN   0x00000001
 Clock enable command.
#define TC_CLKDIS   0x00000002
 Clock disable command.
#define TC_SWTRG   0x00000004
 Software trigger command.

Timer Counter Channel Mode Register



#define TC0_CMR   (TC_BASE + 0x04)
 Channel 0 mode register address.
#define TC1_CMR   (TC_BASE + 0x44)
 Channel 1 mode register address.
#define TC2_CMR   (TC_BASE + 0x84)
 Channel 2 mode register address.
#define TC_CLKS   0x00000007
 Clock selection mask.
#define TC_CLKS_MCK2   0x00000000
 Selects MCK / 2.
#define TC_CLKS_MCK8   0x00000001
 Selects MCK / 8.
#define TC_CLKS_MCK32   0x00000002
 Selects MCK / 32.
#define TC_CLKS_MCK128   0x00000003
 Selects MCK / 128.
#define TC_CLKS_MCK1024   0x00000004
 Selects MCK / 1024.
#define TC_CLKS_XC0   0x00000005
 Selects external clock 0.
#define TC_CLKS_XC1   0x00000006
 Selects external clock 1.
#define TC_CLKS_XC2   0x00000007
 Selects external clock 2.
#define TC_CLKI   0x00000008
 Increments on falling edge.
#define TC_BURST   0x00000030
 Burst signal selection mask.
#define TC_BURST_NONE   0x00000000
 Clock is not gated by an external signal.
#define TC_BUSRT_XC0   0x00000010
 ANDed with external clock 0.
#define TC_BURST_XC1   0x00000020
 ANDed with external clock 1.
#define TC_BURST_XC2   0x00000030
 ANDed with external clock 2.
#define TC_CPCTRG   0x00004000
 RC Compare Enable Trigger Enable.
#define TC_WAVE   0x00008000
 Selects waveform mode.
#define TC_CAPT   0x00000000
 Selects capture mode.

Capture Mode



#define TC_LDBSTOP   0x00000040
 Counter clock stopped on RB loading.
#define TC_LDBDIS   0x00000080
 Counter clock disabled on RB loading.
#define TC_ETRGEDG   0x00000300
 External trigger edge selection mask.
#define TC_ETRGEDG_RISING_EDGE   0x00000100
 Trigger on external rising edge.
#define TC_ETRGEDG_FALLING_EDGE   0x00000200
 Trigger on external falling edge.
#define TC_ETRGEDG_BOTH_EDGE   0x00000300
 Trigger on both external edges.
#define TC_ABETRG   0x00000400
 TIOA or TIOB external trigger selection mask.
#define TC_ABETRG_TIOB   0x00000000
 TIOB used as an external trigger.
#define TC_ABETRG_TIOA   0x00000400
 TIOA used as an external trigger.
#define TC_LDRA   0x00030000
 RA loading selection mask.
#define TC_LDRA_RISING_EDGE   0x00010000
 Load RA on rising edge of TIOA.
#define TC_LDRA_FALLING_EDGE   0x00020000
 Load RA on falling edge of TIOA.
#define TC_LDRA_BOTH_EDGE   0x00030000
 Load RA on any edge of TIOA.
#define TC_LDRB   0x000C0000
 RB loading selection mask.
#define TC_LDRB_RISING_EDGE   0x00040000
 Load RB on rising edge of TIOA.
#define TC_LDRB_FALLING_EDGE   0x00080000
 Load RB on falling edge of TIOA.
#define TC_LDRB_BOTH_EDGE   0x000C0000
 Load RB on any edge of TIOA.

Waveform Mode



#define TC_CPCSTOP   0x00000040
 Counter clock stopped on RC compare.
#define TC_CPCDIS   0x00000080
 Counter clock disabled on RC compare.
#define TC_EEVTEDG   0x00000300
 External event edge selection mask.
#define TC_EEVTEDG_RISING_EDGE   0x00000100
 External event on rising edge..
#define TC_EEVTEDG_FALLING_EDGE   0x00000200
 External event on falling edge..
#define TC_EEVTEDG_BOTH_EDGE   0x00000300
 External event on any edge..
#define TC_EEVT   0x00000C00
 External event selection mask.
#define TC_EEVT_TIOB   0x00000000
 TIOB selected as external event.
#define TC_EEVT_XC0   0x00000400
 XC0 selected as external event.
#define TC_EEVT_XC1   0x00000800
 XC1 selected as external event.
#define TC_EEVT_XC2   0x00000C00
 XC2 selected as external event.
#define TC_ENETRG   0x00001000
 External event trigger enable.
#define TC_ACPA   0x00030000
 Masks RA compare effect on TIOA.
#define TC_ACPA_SET_OUTPUT   0x00010000
 RA compare sets TIOA.
#define TC_ACPA_CLEAR_OUTPUT   0x00020000
 RA compare clears TIOA.
#define TC_ACPA_TOGGLE_OUTPUT   0x00030000
 RA compare toggles TIOA.
#define TC_ACPC   0x000C0000
 Masks RC compare effect on TIOA.
#define TC_ACPC_SET_OUTPUT   0x00040000
 RC compare sets TIOA.
#define TC_ACPC_CLEAR_OUTPUT   0x00080000
 RC compare clears TIOA.
#define TC_ACPC_TOGGLE_OUTPUT   0x000C0000
 RC compare toggles TIOA.
#define TC_AEEVT   0x00300000
 Masks external event effect on TIOA.
#define TC_AEEVT_SET_OUTPUT   0x00100000
 External event sets TIOA.
#define TC_AEEVT_CLEAR_OUTPUT   0x00200000
 External event clears TIOA.
#define TC_AEEVT_TOGGLE_OUTPUT   0x00300000
 External event toggles TIOA.
#define TC_ASWTRG   0x00C00000
 Masks software trigger effect on TIOA.
#define TC_ASWTRG_SET_OUTPUT   0x00400000
 Software trigger sets TIOA.
#define TC_ASWTRG_CLEAR_OUTPUT   0x00800000
 Software trigger clears TIOA.
#define TC_ASWTRG_TOGGLE_OUTPUT   0x00C00000
 Software trigger toggles TIOA.
#define TC_BCPB   0x03000000
 Masks RB compare effect on TIOB.
#define TC_BCPB_SET_OUTPUT   0x01000000
 RB compare sets TIOB.
#define TC_BCPB_CLEAR_OUTPUT   0x02000000
 RB compare clears TIOB.
#define TC_BCPB_TOGGLE_OUTPUT   0x03000000
 RB compare toggles TIOB.
#define TC_BCPC   0x0C000000
 Masks RC compare effect on TIOB.
#define TC_BCPC_SET_OUTPUT   0x04000000
 RC compare sets TIOB.
#define TC_BCPC_CLEAR_OUTPUT   0x08000000
 RC compare clears TIOB.
#define TC_BCPC_TOGGLE_OUTPUT   0x0C000000
 RC compare toggles TIOB.
#define TC_BEEVT   0x30000000
 Masks external event effect on TIOB.
#define TC_BEEVT_SET_OUTPUT   0x10000000
 External event sets TIOB.
#define TC_BEEVT_CLEAR_OUTPUT   0x20000000
 External event clears TIOB.
#define TC_BEEVT_TOGGLE_OUTPUT   0x30000000
 External event toggles TIOB.
#define TC_BSWTRG   0xC0000000
 Masks software trigger effect on TIOB.
#define TC_BSWTRG_SET_OUTPUT   0x40000000
 Software trigger sets TIOB.
#define TC_BSWTRG_CLEAR_OUTPUT   0x80000000
 Software trigger clears TIOB.
#define TC_BSWTRG_TOGGLE_OUTPUT   0xC0000000
 Software trigger toggles TIOB.

Counter Value Register



#define TC0_CV   (TC_BASE + 0x10)
 Counter 0 value.
#define TC1_CV   (TC_BASE + 0x50)
 Counter 1 value.
#define TC2_CV   (TC_BASE + 0x90)
 Counter 2 value.

Timer Counter Register A



#define TC0_RA   (TC_BASE + 0x14)
 Channel 0 register A.
#define TC1_RA   (TC_BASE + 0x54)
 Channel 1 register A.
#define TC2_RA   (TC_BASE + 0x94)
 Channel 2 register A.

Timer Counter Register B



#define TC0_RB   (TC_BASE + 0x18)
 Channel 0 register B.
#define TC1_RB   (TC_BASE + 0x58)
 Channel 1 register B.
#define TC2_RB   (TC_BASE + 0x98)
 Channel 2 register B.

Timer Counter Register C



#define TC0_RC   (TC_BASE + 0x1C)
 Channel 0 register C.
#define TC1_RC   (TC_BASE + 0x5C)
 Channel 1 register C.
#define TC2_RC   (TC_BASE + 0x9C)
 Channel 2 register C.

Timer Counter Status and Interrupt Registers



#define TC0_SR   (TC_BASE + 0x20)
 Status register address.
#define TC1_SR   (TC_BASE + 0x60)
 Status register address.
#define TC2_SR   (TC_BASE + 0xA0)
 Status register address.
#define TC0_IER   (TC_BASE + 0x24)
 Channel 0 interrupt enable register address.
#define TC1_IER   (TC_BASE + 0x64)
 Channel 1 interrupt enable register address.
#define TC2_IER   (TC_BASE + 0xA4)
 Channel 2 interrupt enable register address.
#define TC0_IDR   (TC_BASE + 0x28)
 Channel 0 interrupt disable register address.
#define TC1_IDR   (TC_BASE + 0x68)
 Channel 1 interrupt disable register address.
#define TC2_IDR   (TC_BASE + 0xA8)
 Channel 2 interrupt disable register address.
#define TC0_IMR   (TC_BASE + 0x2C)
 Channel 0 interrupt mask register address.
#define TC1_IMR   (TC_BASE + 0x6C)
 Channel 1 interrupt mask register address.
#define TC2_IMR   (TC_BASE + 0xAC)
 Channel 2 interrupt mask register address.
#define TC_COVFS   0x00000001
 Counter overflow flag.
#define TC_LOVRS   0x00000002
 Load overrun flag.
#define TC_CPAS   0x00000004
 RA compare flag.
#define TC_CPBS   0x00000008
 RB compare flag.
#define TC_CPCS   0x00000010
 RC compare flag.
#define TC_LDRAS   0x00000020
 RA loading flag.
#define TC_LDRBS   0x00000040
 RB loading flag.
#define TC_ETRGS   0x00000080
 External trigger flag.
#define TC_CLKSTA   0x00010000
 Clock enable flag.
#define TC_MTIOA   0x00020000
 TIOA flag.
#define TC_MTIOB   0x00040000
 TIOB flag.

Timer Counter Block Control Register



#define TC_BCR   (TC_BASE + 0xC0)
 Block control register address.
#define TC_SYNC   0x00000001
 Synchronisation trigger.

Timer Counter Block Mode Register



#define TC_BMR   (TC_BASE + 0xC4)
 Block mode register address.
#define TC_TC0XC0S   0x00000003
 External clock signal 0 selection mask.
#define TC_TCLK0XC0   0x00000000
 Selects TCLK0.
#define TC_NONEXC0   0x00000001
 None selected.
#define TC_TIOA1XC0   0x00000002
 Selects TIOA1.
#define TC_TIOA2XC0   0x00000003
 Selects TIOA2.
#define TC_TC1XC1S   0x0000000C
 External clock signal 1 selection mask.
#define TC_TCLK1XC1   0x00000000
 Selects TCLK1.
#define TC_NONEXC1   0x00000004
 None selected.
#define TC_TIOA0XC1   0x00000008
 Selects TIOA0.
#define TC_TIOA2XC1   0x0000000C
 Selects TIOA2.
#define TC_TC2XC2S   0x00000030
 External clock signal 2 selection mask.
#define TC_TCLK2XC2   0x00000000
 Selects TCLK2.
#define TC_NONEXC2   0x00000010
 None selected.
#define TC_TIOA0XC2   0x00000020
 Selects TIOA0.
#define TC_TIOA1XC2   0x00000030
 Selects TIOA1.


Define Documentation

#define TC0_CCR   (TC_BASE + 0x00)

Channel 0 control register address.

Definition at line 57 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC1_CCR   (TC_BASE + 0x40)

Channel 1 control register address.

Definition at line 58 of file at91_tc.h.

#define TC2_CCR   (TC_BASE + 0x80)

Channel 2 control register address.

Definition at line 59 of file at91_tc.h.

#define TC_CLKEN   0x00000001

Clock enable command.

Definition at line 60 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC_CLKDIS   0x00000002

Clock disable command.

Definition at line 61 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC_SWTRG   0x00000004

Software trigger command.

Definition at line 62 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC0_CMR   (TC_BASE + 0x04)

Channel 0 mode register address.

Definition at line 67 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC1_CMR   (TC_BASE + 0x44)

Channel 1 mode register address.

Definition at line 68 of file at91_tc.h.

#define TC2_CMR   (TC_BASE + 0x84)

Channel 2 mode register address.

Definition at line 69 of file at91_tc.h.

#define TC_CLKS   0x00000007

Clock selection mask.

Definition at line 71 of file at91_tc.h.

#define TC_CLKS_MCK2   0x00000000

Selects MCK / 2.

Definition at line 72 of file at91_tc.h.

#define TC_CLKS_MCK8   0x00000001

Selects MCK / 8.

Definition at line 73 of file at91_tc.h.

#define TC_CLKS_MCK32   0x00000002

Selects MCK / 32.

Definition at line 74 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC_CLKS_MCK128   0x00000003

Selects MCK / 128.

Definition at line 75 of file at91_tc.h.

#define TC_CLKS_MCK1024   0x00000004

Selects MCK / 1024.

Definition at line 76 of file at91_tc.h.

#define TC_CLKS_XC0   0x00000005

Selects external clock 0.

Definition at line 77 of file at91_tc.h.

#define TC_CLKS_XC1   0x00000006

Selects external clock 1.

Definition at line 78 of file at91_tc.h.

#define TC_CLKS_XC2   0x00000007

Selects external clock 2.

Definition at line 79 of file at91_tc.h.

#define TC_CLKI   0x00000008

Increments on falling edge.

Definition at line 81 of file at91_tc.h.

#define TC_BURST   0x00000030

Burst signal selection mask.

Definition at line 83 of file at91_tc.h.

#define TC_BURST_NONE   0x00000000

Clock is not gated by an external signal.

Definition at line 84 of file at91_tc.h.

#define TC_BUSRT_XC0   0x00000010

ANDed with external clock 0.

Definition at line 85 of file at91_tc.h.

#define TC_BURST_XC1   0x00000020

ANDed with external clock 1.

Definition at line 86 of file at91_tc.h.

#define TC_BURST_XC2   0x00000030

ANDed with external clock 2.

Definition at line 87 of file at91_tc.h.

#define TC_CPCTRG   0x00004000

RC Compare Enable Trigger Enable.

Definition at line 89 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC_WAVE   0x00008000

Selects waveform mode.

Definition at line 91 of file at91_tc.h.

#define TC_CAPT   0x00000000

Selects capture mode.

Definition at line 92 of file at91_tc.h.

#define TC_LDBSTOP   0x00000040

Counter clock stopped on RB loading.

Definition at line 97 of file at91_tc.h.

#define TC_LDBDIS   0x00000080

Counter clock disabled on RB loading.

Definition at line 98 of file at91_tc.h.

#define TC_ETRGEDG   0x00000300

External trigger edge selection mask.

Definition at line 100 of file at91_tc.h.

#define TC_ETRGEDG_RISING_EDGE   0x00000100

Trigger on external rising edge.

Definition at line 101 of file at91_tc.h.

#define TC_ETRGEDG_FALLING_EDGE   0x00000200

Trigger on external falling edge.

Definition at line 102 of file at91_tc.h.

#define TC_ETRGEDG_BOTH_EDGE   0x00000300

Trigger on both external edges.

Definition at line 103 of file at91_tc.h.

#define TC_ABETRG   0x00000400

TIOA or TIOB external trigger selection mask.

Definition at line 105 of file at91_tc.h.

#define TC_ABETRG_TIOB   0x00000000

TIOB used as an external trigger.

Definition at line 106 of file at91_tc.h.

#define TC_ABETRG_TIOA   0x00000400

TIOA used as an external trigger.

Definition at line 107 of file at91_tc.h.

#define TC_LDRA   0x00030000

RA loading selection mask.

Definition at line 109 of file at91_tc.h.

#define TC_LDRA_RISING_EDGE   0x00010000

Load RA on rising edge of TIOA.

Definition at line 110 of file at91_tc.h.

#define TC_LDRA_FALLING_EDGE   0x00020000

Load RA on falling edge of TIOA.

Definition at line 111 of file at91_tc.h.

#define TC_LDRA_BOTH_EDGE   0x00030000

Load RA on any edge of TIOA.

Definition at line 112 of file at91_tc.h.

#define TC_LDRB   0x000C0000

RB loading selection mask.

Definition at line 114 of file at91_tc.h.

#define TC_LDRB_RISING_EDGE   0x00040000

Load RB on rising edge of TIOA.

Definition at line 115 of file at91_tc.h.

#define TC_LDRB_FALLING_EDGE   0x00080000

Load RB on falling edge of TIOA.

Definition at line 116 of file at91_tc.h.

#define TC_LDRB_BOTH_EDGE   0x000C0000

Load RB on any edge of TIOA.

Definition at line 117 of file at91_tc.h.

#define TC_CPCSTOP   0x00000040

Counter clock stopped on RC compare.

Definition at line 123 of file at91_tc.h.

#define TC_CPCDIS   0x00000080

Counter clock disabled on RC compare.

Definition at line 124 of file at91_tc.h.

#define TC_EEVTEDG   0x00000300

External event edge selection mask.

Definition at line 126 of file at91_tc.h.

#define TC_EEVTEDG_RISING_EDGE   0x00000100

External event on rising edge..

Definition at line 127 of file at91_tc.h.

#define TC_EEVTEDG_FALLING_EDGE   0x00000200

External event on falling edge..

Definition at line 128 of file at91_tc.h.

#define TC_EEVTEDG_BOTH_EDGE   0x00000300

External event on any edge..

Definition at line 129 of file at91_tc.h.

#define TC_EEVT   0x00000C00

External event selection mask.

Definition at line 131 of file at91_tc.h.

#define TC_EEVT_TIOB   0x00000000

TIOB selected as external event.

Definition at line 132 of file at91_tc.h.

#define TC_EEVT_XC0   0x00000400

XC0 selected as external event.

Definition at line 133 of file at91_tc.h.

#define TC_EEVT_XC1   0x00000800

XC1 selected as external event.

Definition at line 134 of file at91_tc.h.

#define TC_EEVT_XC2   0x00000C00

XC2 selected as external event.

Definition at line 135 of file at91_tc.h.

#define TC_ENETRG   0x00001000

External event trigger enable.

Definition at line 137 of file at91_tc.h.

#define TC_ACPA   0x00030000

Masks RA compare effect on TIOA.

Definition at line 139 of file at91_tc.h.

#define TC_ACPA_SET_OUTPUT   0x00010000

RA compare sets TIOA.

Definition at line 140 of file at91_tc.h.

#define TC_ACPA_CLEAR_OUTPUT   0x00020000

RA compare clears TIOA.

Definition at line 141 of file at91_tc.h.

#define TC_ACPA_TOGGLE_OUTPUT   0x00030000

RA compare toggles TIOA.

Definition at line 142 of file at91_tc.h.

#define TC_ACPC   0x000C0000

Masks RC compare effect on TIOA.

Definition at line 144 of file at91_tc.h.

#define TC_ACPC_SET_OUTPUT   0x00040000

RC compare sets TIOA.

Definition at line 145 of file at91_tc.h.

#define TC_ACPC_CLEAR_OUTPUT   0x00080000

RC compare clears TIOA.

Definition at line 146 of file at91_tc.h.

#define TC_ACPC_TOGGLE_OUTPUT   0x000C0000

RC compare toggles TIOA.

Definition at line 147 of file at91_tc.h.

#define TC_AEEVT   0x00300000

Masks external event effect on TIOA.

Definition at line 149 of file at91_tc.h.

#define TC_AEEVT_SET_OUTPUT   0x00100000

External event sets TIOA.

Definition at line 150 of file at91_tc.h.

#define TC_AEEVT_CLEAR_OUTPUT   0x00200000

External event clears TIOA.

Definition at line 151 of file at91_tc.h.

#define TC_AEEVT_TOGGLE_OUTPUT   0x00300000

External event toggles TIOA.

Definition at line 152 of file at91_tc.h.

#define TC_ASWTRG   0x00C00000

Masks software trigger effect on TIOA.

Definition at line 154 of file at91_tc.h.

#define TC_ASWTRG_SET_OUTPUT   0x00400000

Software trigger sets TIOA.

Definition at line 155 of file at91_tc.h.

#define TC_ASWTRG_CLEAR_OUTPUT   0x00800000

Software trigger clears TIOA.

Definition at line 156 of file at91_tc.h.

#define TC_ASWTRG_TOGGLE_OUTPUT   0x00C00000

Software trigger toggles TIOA.

Definition at line 157 of file at91_tc.h.

#define TC_BCPB   0x03000000

Masks RB compare effect on TIOB.

Definition at line 159 of file at91_tc.h.

#define TC_BCPB_SET_OUTPUT   0x01000000

RB compare sets TIOB.

Definition at line 160 of file at91_tc.h.

#define TC_BCPB_CLEAR_OUTPUT   0x02000000

RB compare clears TIOB.

Definition at line 161 of file at91_tc.h.

#define TC_BCPB_TOGGLE_OUTPUT   0x03000000

RB compare toggles TIOB.

Definition at line 162 of file at91_tc.h.

#define TC_BCPC   0x0C000000

Masks RC compare effect on TIOB.

Definition at line 164 of file at91_tc.h.

#define TC_BCPC_SET_OUTPUT   0x04000000

RC compare sets TIOB.

Definition at line 165 of file at91_tc.h.

#define TC_BCPC_CLEAR_OUTPUT   0x08000000

RC compare clears TIOB.

Definition at line 166 of file at91_tc.h.

#define TC_BCPC_TOGGLE_OUTPUT   0x0C000000

RC compare toggles TIOB.

Definition at line 167 of file at91_tc.h.

#define TC_BEEVT   0x30000000

Masks external event effect on TIOB.

Definition at line 169 of file at91_tc.h.

#define TC_BEEVT_SET_OUTPUT   0x10000000

External event sets TIOB.

Definition at line 170 of file at91_tc.h.

#define TC_BEEVT_CLEAR_OUTPUT   0x20000000

External event clears TIOB.

Definition at line 171 of file at91_tc.h.

#define TC_BEEVT_TOGGLE_OUTPUT   0x30000000

External event toggles TIOB.

Definition at line 172 of file at91_tc.h.

#define TC_BSWTRG   0xC0000000

Masks software trigger effect on TIOB.

Definition at line 174 of file at91_tc.h.

#define TC_BSWTRG_SET_OUTPUT   0x40000000

Software trigger sets TIOB.

Definition at line 175 of file at91_tc.h.

#define TC_BSWTRG_CLEAR_OUTPUT   0x80000000

Software trigger clears TIOB.

Definition at line 176 of file at91_tc.h.

#define TC_BSWTRG_TOGGLE_OUTPUT   0xC0000000

Software trigger toggles TIOB.

Definition at line 177 of file at91_tc.h.

#define TC0_CV   (TC_BASE + 0x10)

Counter 0 value.

Definition at line 182 of file at91_tc.h.

#define TC1_CV   (TC_BASE + 0x50)

Counter 1 value.

Definition at line 183 of file at91_tc.h.

#define TC2_CV   (TC_BASE + 0x90)

Counter 2 value.

Definition at line 184 of file at91_tc.h.

#define TC0_RA   (TC_BASE + 0x14)

Channel 0 register A.

Definition at line 189 of file at91_tc.h.

#define TC1_RA   (TC_BASE + 0x54)

Channel 1 register A.

Definition at line 190 of file at91_tc.h.

#define TC2_RA   (TC_BASE + 0x94)

Channel 2 register A.

Definition at line 191 of file at91_tc.h.

#define TC0_RB   (TC_BASE + 0x18)

Channel 0 register B.

Definition at line 196 of file at91_tc.h.

#define TC1_RB   (TC_BASE + 0x58)

Channel 1 register B.

Definition at line 197 of file at91_tc.h.

#define TC2_RB   (TC_BASE + 0x98)

Channel 2 register B.

Definition at line 198 of file at91_tc.h.

#define TC0_RC   (TC_BASE + 0x1C)

Channel 0 register C.

Definition at line 203 of file at91_tc.h.

Referenced by NutGetTickClock(), and NutRegisterTimer().

#define TC1_RC   (TC_BASE + 0x5C)

Channel 1 register C.

Definition at line 204 of file at91_tc.h.

#define TC2_RC   (TC_BASE + 0x9C)

Channel 2 register C.

Definition at line 205 of file at91_tc.h.

#define TC0_SR   (TC_BASE + 0x20)

Status register address.

Definition at line 211 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC1_SR   (TC_BASE + 0x60)

Status register address.

Definition at line 212 of file at91_tc.h.

#define TC2_SR   (TC_BASE + 0xA0)

Status register address.

Definition at line 213 of file at91_tc.h.

#define TC0_IER   (TC_BASE + 0x24)

Channel 0 interrupt enable register address.

Definition at line 215 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC1_IER   (TC_BASE + 0x64)

Channel 1 interrupt enable register address.

Definition at line 216 of file at91_tc.h.

#define TC2_IER   (TC_BASE + 0xA4)

Channel 2 interrupt enable register address.

Definition at line 217 of file at91_tc.h.

#define TC0_IDR   (TC_BASE + 0x28)

Channel 0 interrupt disable register address.

Definition at line 219 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC1_IDR   (TC_BASE + 0x68)

Channel 1 interrupt disable register address.

Definition at line 220 of file at91_tc.h.

#define TC2_IDR   (TC_BASE + 0xA8)

Channel 2 interrupt disable register address.

Definition at line 221 of file at91_tc.h.

#define TC0_IMR   (TC_BASE + 0x2C)

Channel 0 interrupt mask register address.

Definition at line 223 of file at91_tc.h.

#define TC1_IMR   (TC_BASE + 0x6C)

Channel 1 interrupt mask register address.

Definition at line 224 of file at91_tc.h.

#define TC2_IMR   (TC_BASE + 0xAC)

Channel 2 interrupt mask register address.

Definition at line 225 of file at91_tc.h.

#define TC_COVFS   0x00000001

Counter overflow flag.

Definition at line 227 of file at91_tc.h.

#define TC_LOVRS   0x00000002

Load overrun flag.

Definition at line 228 of file at91_tc.h.

#define TC_CPAS   0x00000004

RA compare flag.

Definition at line 229 of file at91_tc.h.

#define TC_CPBS   0x00000008

RB compare flag.

Definition at line 230 of file at91_tc.h.

#define TC_CPCS   0x00000010

RC compare flag.

Definition at line 231 of file at91_tc.h.

Referenced by NutRegisterTimer().

#define TC_LDRAS   0x00000020

RA loading flag.

Definition at line 232 of file at91_tc.h.

#define TC_LDRBS   0x00000040

RB loading flag.

Definition at line 233 of file at91_tc.h.

#define TC_ETRGS   0x00000080

External trigger flag.

Definition at line 234 of file at91_tc.h.

#define TC_CLKSTA   0x00010000

Clock enable flag.

Definition at line 235 of file at91_tc.h.

#define TC_MTIOA   0x00020000

TIOA flag.

Definition at line 236 of file at91_tc.h.

#define TC_MTIOB   0x00040000

TIOB flag.

Definition at line 237 of file at91_tc.h.

#define TC_BCR   (TC_BASE + 0xC0)

Block control register address.

Definition at line 242 of file at91_tc.h.

#define TC_SYNC   0x00000001

Synchronisation trigger.

Definition at line 243 of file at91_tc.h.

#define TC_BMR   (TC_BASE + 0xC4)

Block mode register address.

Definition at line 248 of file at91_tc.h.

#define TC_TC0XC0S   0x00000003

External clock signal 0 selection mask.

Definition at line 249 of file at91_tc.h.

#define TC_TCLK0XC0   0x00000000

Selects TCLK0.

Definition at line 250 of file at91_tc.h.

#define TC_NONEXC0   0x00000001

None selected.

Definition at line 251 of file at91_tc.h.

#define TC_TIOA1XC0   0x00000002

Selects TIOA1.

Definition at line 252 of file at91_tc.h.

#define TC_TIOA2XC0   0x00000003

Selects TIOA2.

Definition at line 253 of file at91_tc.h.

#define TC_TC1XC1S   0x0000000C

External clock signal 1 selection mask.

Definition at line 255 of file at91_tc.h.

#define TC_TCLK1XC1   0x00000000

Selects TCLK1.

Definition at line 256 of file at91_tc.h.

#define TC_NONEXC1   0x00000004

None selected.

Definition at line 257 of file at91_tc.h.

#define TC_TIOA0XC1   0x00000008

Selects TIOA0.

Definition at line 258 of file at91_tc.h.

#define TC_TIOA2XC1   0x0000000C

Selects TIOA2.

Definition at line 259 of file at91_tc.h.

#define TC_TC2XC2S   0x00000030

External clock signal 2 selection mask.

Definition at line 261 of file at91_tc.h.

#define TC_TCLK2XC2   0x00000000

Selects TCLK2.

Definition at line 262 of file at91_tc.h.

#define TC_NONEXC2   0x00000010

None selected.

Definition at line 263 of file at91_tc.h.

#define TC_TIOA0XC2   0x00000020

Selects TIOA0.

Definition at line 264 of file at91_tc.h.

#define TC_TIOA1XC2   0x00000030

Selects TIOA1.

Definition at line 265 of file at91_tc.h.


© 2000-2007 by egnite Software GmbH - visit http://www.ethernut.de/