PIC18F26K80-E/SP Microchip Technology, PIC18F26K80-E/SP Datasheet - Page 246
![ECAN, 64KB Flash, 4KB RAM, 16 MIPS, 12-bit ADC, CTMU 28 SPDIP .300in TUBE](/photos/16/11/161110/pdip28_sml.jpg)
PIC18F26K80-E/SP
Manufacturer Part Number
PIC18F26K80-E/SP
Description
ECAN, 64KB Flash, 4KB RAM, 16 MIPS, 12-bit ADC, CTMU 28 SPDIP .300in TUBE
Manufacturer
Microchip Technology
Series
PIC® XLP™ 18Fr
Datasheet
1.PIC18F25K80-ISO.pdf
(628 pages)
Specifications of PIC18F26K80-E/SP
Core Processor
PIC
Core Size
8-Bit
Speed
64MHz
Connectivity
ECAN, I²C, LIN, SPI, UART/USART
Peripherals
Brown-out Detect/Reset, LVD, POR, PWM, WDT
Number Of I /o
24
Program Memory Size
64KB (32K x 16)
Program Memory Type
FLASH
Eeprom Size
1K x 8
Ram Size
3.6K x 8
Voltage - Supply (vcc/vdd)
1.8 V ~ 5.5 V
Data Converters
A/D 8x12b
Oscillator Type
Internal
Operating Temperature
-40°C ~ 125°C
Package / Case
*
Processor Series
PIC18F26K80
Core
PIC
Data Bus Width
8 bit
Data Ram Size
1 KB
Interface Type
I2C, SPI, USART
Maximum Clock Frequency
64 MHz
Number Of Programmable I/os
24
Number Of Timers
5
Operating Supply Voltage
1.8 V to 5.5 V
Maximum Operating Temperature
+ 125 C
Mounting Style
Through Hole
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
Available stocks
Company
Part Number
Manufacturer
Quantity
Price
Company:
Part Number:
PIC18F26K80-E/SP
Manufacturer:
SILICON
Quantity:
210
- Current page: 246 of 628
- Download datasheet (6Mb)
PIC18F66K80 FAMILY
18.2.5
The CTMU sets its interrupt flag (PIR3<3>) whenever
the current source is enabled, then disabled. An inter-
rupt is generated only if the corresponding interrupt
enable bit (PIE3<3>) is also set. If edge sequencing is
not enabled (i.e., Edge 1 must occur before Edge 2), it
is necessary to monitor the edge status bits and
determine which edge occurred last and caused the
interrupt.
18.3
The following sequence is a general guideline used to
initialize the CTMU module:
1.
2.
3.
4.
5.
6.
7.
8.
9.
10. Disable the module by clearing the CTMUEN bit
11. Clear the Edge Status bits, EDG2STAT and
12. Enable both edge inputs by setting the EDGEN
13. Enable the module by setting the CTMUEN bit.
DS39977C-page 246
Select the current source range using the
IRNGx bits (CTMUICON<1:0>).
Adjust the current source trim using the ITRIMx
bits (CTMUICON<7:2>).
Configure the edge input sources for Edge 1 and
Edge 2 by setting the EDG1SEL and EDG2SEL
bits (CTMUCONL<3:2> and <6:5>, respectively).
Configure the input polarities for the edge inputs
using the EDG1POL and EDG2POL bits
(CTMUCONL<4,7>).
The default configuration is for negative edge
polarity (high-to-low transitions).
Enable edge sequencing using the EDGSEQEN
bit (CTMUCONH<2>).
By default, edge sequencing is disabled.
Select the operating mode (Measurement or
Time
(CTMUCONH<4>).
The
Measurement.
Configure the module to automatically trigger
an A/D conversion when the second edge
event has occurred using the CTTRIG bit
(CTMUCONH<0>).
The conversion trigger is disabled by default.
Discharge the connected circuit by setting the
IDISSEN bit (CTMUCONH<1>).
After waiting a sufficient time for the circuit to
discharge, clear the IDISSEN bit.
(CTMUCONH<7>).
EDG1STAT (CTMUCONL<1:0>).
Both bits should be cleared simultaneously, if
possible, to avoid re-enabling the CTMU current
source.
bit (CTMUCONH<3>).
CTMU Module Initialization
default
INTERRUPTS
Delay)
mode
with
is
the
Time/Capacitance
TGEN
bit
Preliminary
Depending on the type of measurement or pulse
generation being performed, one or more additional
modules may also need to be initialized and configured
with the CTMU module:
• Edge Source Generation: In addition to the
• Capacitance or Time Measurement: The CTMU
• Pulse Generation: When generating system clock
18.4
The CTMU requires calibration for precise measure-
ments of capacitance and time, as well as for accurate
time delay. If the application only requires measurement
of a relative change in capacitance or time, calibration is
usually not necessary. An example of a less precise
application is a capacitive touch switch, in which the
touch circuit has a baseline capacitance and the added
capacitance of the human body changes the overall
capacitance of a circuit.
If actual capacitance or time measurement is required,
two hardware calibrations must take place:
• The current source needs calibration to set it to a
• The circuit being measured needs calibration to
18.4.1
The current source on board the CTMU module has a
range of ±62% nominal for each of three current
ranges. For precise measurements, it is possible to
measure and adjust this current source by placing a
high-precision resistor, R
channel. An example circuit is shown in
To measure the current source:
1.
2.
3.
4.
5.
6.
external edge input pins, ECCP1/CCP2 Special
Event Triggers can be used as edge sources for
the CTMU.
module uses the A/D Converter to measure the
voltage across a capacitor that is connected to one
of the analog input channels.
independent, output pulses, the CTMU module
uses Comparator 2 and the associated
comparator voltage reference.
precise current.
measure or nullify any capacitance other than that
to be measured.
Initialize the A/D Converter.
Initialize the CTMU.
Enable the current source by setting EDG1STAT
(CTMUCONL<0>).
Issue time delay for voltage across R
stabilize and ADC sample/hold capacitor to
charge.
Perform the A/D conversion.
Calculate the current source current using
I = V / R
resistance and V is measured by performing an
A/D conversion.
Calibrating the CTMU Module
CURRENT SOURCE CALIBRATION
CAL
, where R
2011 Microchip Technology Inc.
CAL
CAL
, onto an unused analog
is a high-precision
Figure
CAL
18-2.
to
Related parts for PIC18F26K80-E/SP
Image
Part Number
Description
Manufacturer
Datasheet
Request
R
![TC1014-2.7VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1014-5.0VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-2.5VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-2.7VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-2.8VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1055-4.0VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1186-2.5VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet:
![TC1186-2.85VCT](/images/manufacturer_photos/0/4/440/microchip_technology_inc__tmb.jpg)
Part Number:
Description:
Manufacturer:
Microchip Technology Inc.
Datasheet: