| Electronic Components Datasheet Search |
|
AT89LP51RB2 Datasheet(PDF) 101 Page - ATMEL Corporation |
|
|
|||||||||||||||||||||||||||||
AT89LP51RB2 Datasheet(HTML) 101 Page - ATMEL Corporation |
|
101 / 254 page ![]() 101 3722A–MICRO–10/11 AT89LP51RB2/RC2/IC2 Preliminary 15.3 PCA Capture Mode To use one of the PCA modules in the capture mode either one or both of the CCAPM bits CAPN and CAPP for that module must be set. The external CEX input for the module (on port 1) is sampled for a transition. When a valid transition occurs the PCA hardware loads the value of the PCA counter registers (CH and CL) into the module's capture registers (CCAPnL and CCA- PnH). If the CCFn bit for the module in the CCON SFR and the ECCFn bit in the CCAPMn SFR are set then an interrupt will be generated (Refer to Figure 15-3). Figure 15-3. PCA Capture Mode 15.4 16-bit Software Timer/ Compare Mode The PCA modules can be used as software timers by setting both the ECOM and MAT bits in the modules CCAPMn register. The PCA timer will be compared to the module's capture regis- ters and when a match occurs an interrupt will occur if the CCFn (CCON SFR) and the ECCFn (CCAPMn SFR) bits for the module are both set (See Figure 15-4). Figure 15-4. PCA Compare Mode and PCA Watchdog Timer Before enabling ECOM bit, CCAPnL and CCAPnH should be set with a non zero value, other- wise an unwanted match could happen. Writing to CCAPnH will set the ECOM bit. Once ECOM is set, writing CCAPnL will clear ECOM so that an unwanted match doesn’t occur while modify- ing the compare value. Writing to CCAPnH will set ECOM. For this reason, user software should write CCAPnL first, and then CCAPnH. Of course, the ECOM bit can still be controlled by accessing to CCAPMn register. CL CH CCAPnL CCAPnH Interrupt CEXn CCFn CCAPMn.0 ECCFn CAPNn CCAPMn.4 CAPPn CCAPMn.5 Module n CL CH CCAPnL CCAPnH Interrupt CCFn = MATn CCAPMn.3 ECOMn 0 1 Write to CCAPnH Write to CCAPnL ECCFn CCAPMn.0 WDTE CMOD.6 (Module 4 only) Module n Reset |
|
Link URL |
| Does ALLDATASHEET help your business so far? [ DONATE ] |
About Alldatasheet | Advertisement | Contact us | Privacy Policy | Link to Datasheet | Link Exchange | Manufacturer List All Rights Reserved©Alldatasheet.com |
| Russian : Alldatasheetru.com | Korean : Alldatasheet.co.kr | Spanish : Alldatasheet.es | French : Alldatasheet.fr | Italian : Alldatasheetit.com Portuguese : Alldatasheetpt.com | Polish : Alldatasheet.pl | Vietnamese : Alldatasheet.vn Indian : Alldatasheet.in | Mexican : Alldatasheet.com.mx | British : Alldatasheet.co.uk | New Zealand : Alldatasheet.co.nz |
|
Family Site : ic2ic.com |
icmetro.com |