This powerful 10 MIPS (100 nanosecond instruction execution), yet easy-to-program (only 77 single word instructions) CMOS Flash-based 8-bit microcontroller packs Microchip's powerful PIC® architecture into an 28-pin package and is upwards compatible with the PIC16C5X, PIC12CXXX, PIC16CXX and PIC17CXX devices and provides a seamless migration path of software code to higher levels of hardware integration. The PIC18F2321 features a C compiler-friendly development environment, 256 bytes of EEPROM, self-programming, an ICD, 2 capture/compare/PWM functions, 10 channels of 10-bit Analog-to-Digital (A/D) converter, 2 comparators, the synchronous serial port can be configured as either 3-wire Serial Peripheral Interface (SPI™) or the 2-wire Inter-Integrated Circuit (I²C™) bus and Enhanced Universal Asynchronous Receiver Transmitter (EUSART), 8 MHz internal RC oscillator and advanced low power oscillator controls. All of these features make it ideal for battery powered and power consumption critical applications including instrumentation and monitoring, data acquisition, power conditioning, environmental monitoring, telecom and consumer audio/video applications.
Parameter Name Value Program Memory Type Flash Program Memory (KB) 8 CPU Speed (MIPS) 10 RAM Bytes 512 Data EEPROM (bytes) 256 Digital Communication Peripherals 1-A/E/USART, 1-MSSP(SPI/I2C) Capture/Compare/PWM Peripherals 2 CCP Timers 1 x 8-bit, 3 x 16-bit ADC 10 ch, 10-bit Comparators 2 Temperature Range (C) -40 to 125 Operating Voltage Range (V) 2 to 5.5 Pin Count 28
Features
CPU
Up to 10 MIPS performance
C compiler optimized RISC architecture
8 x 8 Single Cycle Hardware Multiply
System
Internal oscillator support - 31 kHz to 8 MHz, up to 32 MHz with 4X PLL
Fail-Safe Clock Monitor – allows safe shutdown if clock fails
Watchdog Timer with separate RC oscillator
Wide operating Voltage range; 2.0V to 5.5V
nanoWatt Power Managed Modes
Run, Idle and Sleep modes
Idle mode currents down to 5.8uA typical
Sleep mode currents down to 0.1uA typical
Analog Features
10-bit ADC, 10 channels, 100K samples per second
Programmable Low Voltage Detection Module
Programmable Brown-out Reset module
Two Analog comparators with input multiplexing
Peripherals
Master Synchronous Serial Port supports SPI ™ and I2C™ Master and Slave Mode
EUSART module including LIN bus support
Four Timer Modules
Up to 5 PWM outputs
Up to 2 Capture / Compare
PIC18F2221/2321/4221/4321 Family Data Sheet