Datasheet

PIC18F87K90 FAMILY
DS39957D-page 202 2009-2011 Microchip Technology Inc.
REGISTER 15-1: TxCON: TIMER3/5/7 CONTROL REGISTER
R/W-0 R/W-0 R/W-0 R/W-0 R/W-0 R/W-0 R/W-0 R/W-0
TMRxCS1 TMRxCS0 TxCKPS1 TxCKPS0 SOSCEN TxSYNC
RD16 TMRxON
bit 7 bit 0
Legend:
R = Readable bit W = Writable bit U = Unimplemented bit, read as ‘0’
-n = Value at POR ‘1’ = Bit is set ‘0’ = Bit is cleared x = Bit is unknown
bit 7-6 TMRxCS<1:0>: Timerx Clock Source Select bits
10 = The Timer1 clock source is either a pin or an oscillator depending on the SOSCEN bit.
SOSCEN =
0:
External clock is from the T1CKI pin (on the rising edge).
SOSCEN =
1:
Crystal oscillator is on the SOSCI/SOSCO pins.
01 = Timerx clock source is the system clock (F
OSC)
(1)
00 = Timerx clock source is the instruction clock (FOSC/4)
bit 5-4 TxCKPS<1:0>: Timerx Input Clock Prescale Select bits
11 = 1:8 Prescale value
10 = 1:4 Prescale value
01 = 1:2 Prescale value
00 = 1:1 Prescale value
bit 3 SOSCEN: SOSC Oscillator Enable bit
1 = SOSC is enabled for Timerx (based on SOSCSEL fuses)
0 = SOSC is disabled for Timerx
bit 2 TxSYNC: Timerx External Clock Input Synchronization Control bit
(Not usable if the device clock comes from Timer1/Timer3.)
When TMRxCS<1:0> =
10:
1 = Do not synchronize external clock input
0 = Synchronize external clock input
When TMRxCS<1:0> =
0x:
This bit is ignored; Timer3 uses the internal clock.
bit 1 RD16: 16-Bit Read/Write Mode Enable bit
1 = Enables register read/write of Timerx in one 16-bit operation
0 = Enables register read/write of Timerx in two 8-bit operations
bit 0 TMRxON: Timerx On bit
1 = Enables Timerx
0 = Stops Timerx
Note 1: The F
OSC clock source should not be selected if the timer will be used with the ECCP capture/compare
features.