Data SheetTable of ContentsGraphics Controller Features:3Universal Serial Bus Features:3Peripheral Features:3High-Performance CPU4Power Management:4Analog Features:4Special Microcontroller Features:4Pin Diagram (64-Pin TQFP/QFN)5Pin Diagram (100-Pin TQFP)7Pin Diagram – Top View (121-Pin BGA)10Table of Contents13Most Current Data Sheet14Errata14Customer Notification System141.0 Device Overview151.1 Core Features151.1.1 16-Bit Architecture151.1.2 Power-Saving Technology151.1.3 Oscillator Options and Features151.1.4 Easy Migration151.2 Graphics Controller161.3 USB On-The-Go161.4 Other Special Features161.5 Details on Individual Family Members17TABLE 1-1: DEVICE FEATURES FOR THE PIC24FJ256DA210 family: 64-PIN18TABLE 1-2: Device Features for the PIC24FJ256DA210 family: 100-pin Devices19FIGURE 1-1: PIC24FJ256DA210 family General Block Diagram20TABLE 1-3: PIC24FJ256DA210 family Pinout Descriptions212.0 Guidelines for Getting Started with 16-bit Microcontrollers332.1 Basic Connection Requirements33FIGURE 2-1: Recommended Minimum connections332.2 Power Supply Pins342.2.1 Decoupling Capacitors342.2.2 Tank Capacitors342.3 Master Clear (MCLR) Pin34FIGURE 2-2: Example of MCLR Pin Connections342.4 Voltage Regulator Pins (ENVREG/DISVREG and Vcap/Vddcore)35FIGURE 2-3: Frequency vs. ESR Performance for Suggested Vcap352.5 ICSP Pins352.6 External Oscillator Pins36FIGURE 2-4: Suggested Placement of the Oscillator Circuit362.7 Configuration of Analog and Digital Pins During ICSP Operations372.8 Unused I/Os373.0 CPU393.1 Programmer’s Model39FIGURE 3-1: PIC24F CPU Core Block Diagram40TABLE 3-1: CPU Core Registers40FIGURE 3-2: Programmer’s Model413.2 CPU Control Registers42Register 3-1: SR: ALU STATUS Register42Register 3-2: CORCON: CPU Control Register433.3 Arithmetic Logic Unit (ALU)433.3.1 Multiplier433.3.2 Divider443.3.3 Multi-Bit Shift Support44TABLE 3-2: Instructions that Use the Single Bit and Multi-Bit Shift Operation444.0 Memory Organization454.1 Program Memory Space45FIGURE 4-1: Program Space Memory Map for PIC24FJ256DA210 family Devices454.1.1 Program Memory Organization464.1.2 Hard Memory Vectors464.1.3 Flash Configuration Words46TABLE 4-1: Flash Configuration Words for PIC24FJ256DA210 family Devices46FIGURE 4-2: Program Memory Organization464.2 Data Memory Space47TABLE 4-2: Total Memory Accessible by the Device474.2.1 Data Space Width48FIGURE 4-3: Data Space Memory Map for PIC24FJ256DA210 family Devices(4)484.2.2 Data Memory Organization and Alignment494.2.3 Near Data Space494.2.4 Special Function Register (SFR) Space49TABLE 4-3: Implemented Regions of SFR Data Space49TABLE 4-4: CPU CORE Registers Map50TABLE 4-5: ICN Register Map51TABLE 4-6: Interrupt Controller Register Map52TABLE 4-7: Timer Register Map53TABLE 4-8: Input Capture Register Map54TABLE 4-9: Output Compare Register Map55TABLE 4-10: I2C™ Register Map56TABLE 4-11: UART Register Maps57TABLE 4-12: SPI Register Maps58TABLE 4-13: PORTA Register Map(1)58TABLE 4-14: PORTb Register Map58TABLE 4-15: PORTC Register Map59TABLE 4-16: PORTD Register Map59TABLE 4-17: PORTE Register Map59TABLE 4-18: PORTF Register Map60TABLE 4-19: PORTG Register Map60TABLE 4-20: Pad Configuration Register Map60TABLE 4-21: ADC Register Map61TABLE 4-22: CTMU Register Map62TABLE 4-23: USB OTG Register Map63TABLE 4-24: ANCFG Register Map64TABLE 4-25: ANSEL Register Map64TABLE 4-26: Enhanced Parallel Master/Slave Port Register Map(1)65TABLE 4-27: Real-Time Clock and Calendar Register Map65TABLE 4-28: Comparators Register Map66TABLE 4-29: CRC Register Map66TABLE 4-30: Peripheral Pin Select Register Map67TABLE 4-31: Graphics Register Map69TABLE 4-32: System Register Map70TABLE 4-33: NVM Register Map70TABLE 4-34: PMD Register Map704.2.5 Extended Data Space (EDS)71FIGURE 4-4: Extended Data Space71FIGURE 4-5: EDS Address Generation for Read Operations72EXAMPLE 4-1: EDS Read Code In Assembly72FIGURE 4-6: EDS Address Generation for Write Operations73EXAMPLE 4-2: EDS Write Code In Assembly73TABLE 4-35: EDS Memory Address with Different Pages and Addresses744.2.6 Software Stack75FIGURE 4-7: CALL Stack Frame754.3 Interfacing Program and Data Memory Spaces754.3.1 Addressing Program Space75TABLE 4-36: Program Space Address Construction76FIGURE 4-8: Data Access from Program Space Address Generation764.3.2 Data Access from Program Memory Using Table Instructions77FIGURE 4-9: Accessing Program Memory with Table Instructions774.3.3 Reading Data from Program Memory Using EDS78TABLE 4-37: EDS Program Address with different Pages and Addresses78FIGURE 4-10: Program Space Visibility Operation to Access Lower Word79FIGURE 4-11: Program Space Visibility Operation to Access Higher Word79EXAMPLE 4-3: EDS Read Code from Program Memory In Assembly805.0 Flash Program Memory815.1 Table Instructions and Flash Programming81FIGURE 5-1: Addressing for Table Registers815.2 RTSP Operation825.3 JTAG Operation825.4 Enhanced In-Circuit Serial Programming825.5 Control Registers825.6 Programming Operations82Register 5-1: NVMCON: Flash Memory Control Register835.6.1 Programming Algorithm for Flash Program Memory84EXAMPLE 5-1: Erasing a Program Memory Block (Assembly Language Code)84EXAMPLE 5-2: Erasing a Program Memory Block (‘C’ Language Code)85EXAMPLE 5-3: LOADING THE WRITE BUFFERS85EXAMPLE 5-4: Initiating a Programming Sequence855.6.2 Programming a single word of flash program memory86EXAMPLE 5-5: Programming a Single Word of Flash Program Memory86EXAMPLE 5-6: Programming a Single Word of Flash Program Memory (‘C’ Language Code)866.0 Resets87FIGURE 6-1: Reset System Block Diagram87Register 6-1: RCON: Reset Control Register(1)88TABLE 6-1: Reset Flag Bit Operation896.1 Special Function Register Reset States906.2 Device Reset Times906.3 Clock Source Selection at Reset90TABLE 6-2: Oscillator Selection vs. Type of Reset (Clock Switching Enabled)90TABLE 6-3: Reset Delay Times for Various Device Resets916.3.1 POR and Long Oscillator Start-up Times916.3.2 Fail-Safe Clock Monitor (FSCM) and Device Resets917.0 Interrupt Controller937.1 Interrupt Vector Table937.1.1 Alternate Interrupt Vector Table937.2 Reset Sequence93FIGURE 7-1: PIC24F Interrupt Vector Table94TABLE 7-1: Trap Vector Details94TABLE 7-2: Implemented Interrupt Vectors957.3 Interrupt Control and Status Registers96Register 7-1: SR: ALU STATUS Register (in CPU)97Register 7-2: CORCON: CPU Control Register98Register 7-3: INTCON1: Interrupt Control Register 199Register 7-4: INTCON2: Interrupt Control Register 2100Register 7-5: IFS0: Interrupt Flag Status Register 0101Register 7-6: IFS1: Interrupt Flag Status Register 1102Register 7-7: IFS2: Interrupt Flag Status Register 2103Register 7-8: IFS3: Interrupt Flag Status Register 3105Register 7-9: IFS4: Interrupt Flag Status Register 4106Register 7-10: IFS5: Interrupt Flag Status Register 5107Register 7-11: IFS6: Interrupt Flag Status Register 6108Register 7-12: IEC0: Interrupt Enable Control Register 0109Register 7-13: IEC1: Interrupt Enable Control Register 1110Register 7-14: IEC2: Interrupt Enable Control Register 2112Register 7-15: IEC3: Interrupt Enable Control Register 3113Register 7-16: IEC4: Interrupt Enable Control Register 4114Register 7-17: IEC5: Interrupt Enable Control Register 5115Register 7-18: IEC6: Interrupt Enable Control Register 6116Register 7-19: IPC0: Interrupt Priority Control Register 0117Register 7-20: IPC1: Interrupt Priority Control Register 1118Register 7-21: IPC2: Interrupt Priority Control Register 2119Register 7-22: IPC3: Interrupt Priority Control Register 3120Register 7-23: IPC4: Interrupt Priority Control Register 4121Register 7-24: IPC5: Interrupt Priority Control Register 5122Register 7-25: IPC6: Interrupt Priority Control Register 6123Register 7-26: IPC7: Interrupt Priority Control Register 7124Register 7-27: IPC8: Interrupt Priority Control Register 8125Register 7-28: IPC9: Interrupt Priority Control Register 9126Register 7-29: IPC10: Interrupt Priority Control Register 10127Register 7-30: IPC11: Interrupt Priority Control Register 11128Register 7-31: IPC12: Interrupt Priority Control Register 12129Register 7-32: IPC13: Interrupt Priority Control Register 13130Register 7-33: IPC15: Interrupt Priority Control Register 15131Register 7-34: IPC16: Interrupt Priority Control Register 16132Register 7-35: IPC18: Interrupt Priority Control Register 18133Register 7-36: IPC19: Interrupt Priority Control Register 19133Register 7-37: IPC20: Interrupt Priority Control Register 20134Register 7-38: IPC21: Interrupt Priority Control Register 21135Register 7-39: IPC22: Interrupt Priority Control Register 22136Register 7-40: IPC23: Interrupt Priority Control Register 23137Register 7-41: IPC25: Interrupt Priority Control Register 25138Register 7-42: INTTREG: Interrupt Controller Test Register1397.4 Interrupt Setup Procedures1407.4.1 Initialization1407.4.2 Interrupt Service Routine (ISR)1407.4.3 Trap Service Routine (TSR)1407.4.4 Interrupt Disable1408.0 Oscillator Configuration141FIGURE 8-1: PIC24FJ256DA210 family Clock Diagram1418.1 CPU Clocking Scheme1428.2 Initial Configuration on POR1428.2.1 Clock Switching Mode Configuration Bits142TABLE 8-1: Configuration Bit Values for Clock Selection1428.3 Control Registers143Register 8-1: OSCCON: Oscillator Control Register143Register 8-2: CLKDIV: Clock Divider Register145Register 8-3: OSCTUN: FRC Oscillator Tune Register146Register 8-4: CLKDIV2: Clock Divider Register 21478.4 Clock Switching Operation1488.4.1 Enabling Clock Switching1488.4.2 Oscillator Switching Sequence148EXAMPLE 8-1: Basic Code Sequence for Clock Switching in Assembly1498.5 96 MHz PLL Block149FIGURE 8-2: 96 MHz PLL Block1508.5.1 System Clock Generation150TABLE 8-2: System Clock Options for 96 MHz PLL Block1508.5.2 USB Clock Generation151TABLE 8-3: Valid Oscillator Configurations for USB Operations1518.5.3 Considerations for USB Operation1518.5.4 Graphics Clock Generation151TABLE 8-4: Display Module Clock Frequency Division1528.6 Reference Clock Output152Register 8-5: REFOCON: Reference Oscillator Control Register1539.0 Power-Saving Features1559.1 Clock Frequency and Clock Switching1559.2 Instruction-Based Power-Saving Modes1559.2.1 Sleep Mode155EXAMPLE 9-1: PWRSAV Instruction Syntax1559.2.2 Idle Mode1569.2.3 Interrupts Coincident with Power Save Instructions1569.3 Doze Mode1569.4 Selective Peripheral Module Control15610.0 I/O Ports15710.1 Parallel I/O (PIO) Ports157FIGURE 10-1: Block Diagram of a Typical Shared Port Structure15710.1.1 I/O Port Write/Read Timing15810.1.2 Open-Drain Configuration15810.1.3 Configuring D+ and D- Pins (RG2 and RG3)15810.2 Configuring Analog Port Pins (ANSEL)15810.2.1 Analog Input Pins and Voltage Considerations158TABLE 10-1: Configuring Analog/Digital Function of an I/O Pin158TABLE 10-2: Input Voltage Levels for Port or Pin Tolerated Description Input158Register 10-1: ANSA: PortA Analog Function Selection Register(1)159Register 10-2: ANSB: PortB Analog Function Selection Register160Register 10-3: ANSC: PortC Analog Function Selection Register160Register 10-4: ANSD: PortD Analog Function Selection Register161Register 10-5: ANSE: PortE Analog Function Selection Register(1)161Register 10-6: ANSF: PortF Analog Function Selection Register162Register 10-7: ANSG: PortG Analog Function Selection Register16210.3 Input Change Notification163EXAMPLE 10-1: Port Write/Read in Assembly163EXAMPLE 10-2: Port Write/Read in ‘C’16310.4 Peripheral Pin Select (PPS)16410.4.1 Available Pins16410.4.2 Available Peripherals16410.4.3 Controlling Peripheral Pin Select164TABLE 10-3: Selectable Input Sources (Maps Input to Function)(1)165TABLE 10-4: Selectable Output Sources (Maps Function to Output)16610.4.4 Controlling Configuration Changes167TABLE 10-5: Remappable Pin Exceptions for PIC24FJ256DA210 family Devices16710.4.5 Considerations for Peripheral Pin Selection168EXAMPLE 10-3: Configuring UART1 Input and Output Functions16810.4.6 Peripheral Pin Select Registers169Register 10-8: RPINR0: Peripheral Pin Select Input Register 0169Register 10-9: RPINR1: Peripheral Pin Select Input Register 1169Register 10-10: RPINR2: Peripheral Pin Select Input Register 2170Register 10-11: RPINR3: Peripheral Pin Select Input Register 3170Register 10-12: RPINR4: Peripheral Pin Select Input Register 4171Register 10-13: RPINR7: Peripheral Pin Select Input Register 7171Register 10-14: RPINR8: Peripheral Pin Select Input Register 8172Register 10-15: RPINR9: Peripheral Pin Select Input Register 9172Register 10-16: RPINR10: Peripheral Pin Select Input Register 10173Register 10-17: RPINR11: Peripheral Pin Select Input Register 11173Register 10-18: RPINR15: Peripheral Pin Select Input Register 15174Register 10-19: RPINR17: Peripheral Pin Select Input Register 17174Register 10-20: RPINR18: Peripheral Pin Select Input Register 18175Register 10-21: RPINR19: Peripheral Pin Select Input Register 19175Register 10-22: RPINR20: Peripheral Pin Select Input Register 20176Register 10-23: RPINR21: Peripheral Pin Select Input Register 21176Register 10-24: RPINR22: Peripheral Pin Select Input Register 22177Register 10-25: RPINR23: Peripheral Pin Select Input Register 23177Register 10-26: RPINR27: Peripheral Pin Select Input Register 27178Register 10-27: RPINR28: Peripheral Pin Select Input Register 28178Register 10-28: RPINR29: Peripheral Pin Select Input Register 29179Register 10-29: RPOR0: Peripheral Pin Select Output Register 0180Register 10-30: RPOR1: Peripheral Pin Select Output Register 1180Register 10-31: RPOR2: Peripheral Pin Select Output Register 2181Register 10-32: RPOR3: Peripheral Pin Select Output Register 3181Register 10-33: RPOR4: Peripheral Pin Select Output Register 4182Register 10-34: RPOR5: Peripheral Pin Select Output Register 5182Register 10-35: RPOR6: Peripheral Pin Select Output Register 6183Register 10-36: RPOR7: Peripheral Pin Select Output Register 7183Register 10-37: RPOR8: Peripheral Pin Select Output Register 8184Register 10-38: RPOR9: Peripheral Pin Select Output Register 9184Register 10-39: RPOR10: Peripheral Pin Select Output Register 10185Register 10-40: RPOR11: Peripheral Pin Select Output Register 11185Register 10-41: RPOR12: Peripheral Pin Select Output Register 12186Register 10-42: RPOR13: Peripheral Pin Select Output Register 13186Register 10-43: RPOR14: Peripheral Pin Select Output Register 14187Register 10-44: RPOR15: Peripheral Pin Select Output Register 15(1)18711.0 Timer1189FIGURE 11-1: 16-bit Timer1 Module Block Diagram189Register 11-1: T1CON: Timer1 Control Register(1)19012.0 Timer2/3 and Timer4/5191FIGURE 12-1: Timer2/3 and Timer4/5 (32-bit) Block Diagram192FIGURE 12-2: Timer2 and Timer4 (16-bit Synchronous) Block Diagram193FIGURE 12-3: Timer3 and Timer5 (16-bit Asynchronous) Block Diagram193Register 12-1: TxCON: Timer2 and Timer4 Control Register(3)194Register 12-2: TyCON: Timer3 and Timer5 Control Register(3)19513.0 Input Capture with Dedicated Timers19713.1 General Operating Modes19713.1.1 Synchronous and Trigger modes197FIGURE 13-1: Input Capture Block Diagram19713.1.2 Cascaded (32-bit) Mode19813.2 Capture Operations198Register 13-1: ICxCON1: Input Capture x Control Register 1199Register 13-2: ICxCON2: Input Capture x Control Register 220014.0 Output Compare with Dedicated Timers20114.1 General Operating Modes20114.1.1 Synchronous and Trigger modes20114.1.2 Cascaded (32-bit) Mode201FIGURE 14-1: Output Compare Block Diagram (16-bit Mode)20214.2 Compare Operations20214.3 Pulse-Width Modulation (PWM) Mode203FIGURE 14-2: Output Compare Block Diagram (Double-Buffered, 16-bit PWM Mode)20414.3.1 PWM Period204EQUATION 14-1: Calculating the PWM Period(1)20414.3.2 PWM Duty Cycle205EQUATION 14-2: Calculation for Maximum PWM Resolution(1)205EXAMPLE 14-1: PWM Period and Duty Cycle Calculations(1)205TABLE 14-1: Example PWM Frequencies and Resolutions at 4 MIPS (Fcy = 4 MHz)(1)205TABLE 14-2: Example PWM Frequencies and Resolutions at 16 MIPS (Fcy = 16 MHz)(1)205Register 14-1: OCxCON1: Output Compare x Control Register 1206Register 14-2: OCxCON2: Output Compare x Control Register 220815.0 Serial Peripheral Interface (SPI)211FIGURE 15-1: SPIx Module Block Diagram (Standard Mode)212FIGURE 15-2: SPIx Module Block Diagram (Enhanced Mode)213Register 15-1: SPIxSTAT: SPIx Status and Control Register214Register 15-2: SPIxCON1: SPIx Control Register 1216Register 15-3: SPIxCON2: SPIx Control Register 2218FIGURE 15-3: SPI Master/Slave Connection (Standard Mode)219FIGURE 15-4: SPI Master/Slave Connection (Enhanced Buffer Modes)219FIGURE 15-5: SPI Master, Frame Master Connection Diagram220FIGURE 15-6: SPI Master, Frame Slave Connection Diagram220FIGURE 15-7: SPI Slave, Frame Master Connection Diagram220FIGURE 15-8: SPI Slave, Frame Slave Connection Diagram220EQUATION 15-1: Relationship Between Device and SPI Clock Speed(1)221TABLE 15-1: Sample SCKx Frequencies(1,2)22116.0 Inter-Integrated Circuit™ (I2C™)22316.1 Communicating as a Master in a Single Master Environment223FIGURE 16-1: I2C™ Block Diagram22416.2 Setting Baud Rate When Operating as a Bus Master225EQUATION 16-1: Computing Baud Rate Reload Value(1,2)22516.3 Slave Address Masking225TABLE 16-1: I2C™ Clock Rates(1,2)225TABLE 16-2: I2C™ reserved addresses(1)225Register 16-1: I2CxCON: I2Cx Control Register226Register 16-2: I2CxSTAT: I2Cx Status Register228Register 16-3: I2CxMSK: I2Cx Slave Mode Address Mask Register23017.0 Universal Asynchronous Receiver Transmitter (UART)231FIGURE 17-1: UART Simplified Block Diagram23117.1 UART Baud Rate Generator (BRG)232EQUATION 17-1: UART Baud Rate with BRGH = 0(1,2)232EQUATION 17-2: UART Baud Rate with BRGH = 1(1,2)232EXAMPLE 17-1: Baud Rate Error Calculation (BRGH = 0)(1)23217.2 Transmitting in 8-Bit Data Mode23317.3 Transmitting in 9-Bit Data Mode23317.4 Break and Sync Transmit Sequence23317.5 Receiving in 8-Bit or 9-Bit Data Mode23317.6 Operation of UxCTS and UxRTS Control Pins23317.7 Infrared Support23317.7.1 IrDA Clock Output for External IrDA Support23317.7.2 Built-in IrDA Encoder and Decoder233Register 17-1: UxMODE: UARTx Mode Register234Register 17-2: UxSTA: UARTx Status and Control Register23618.0 Universal Serial Bus with On-The-Go Support (USB OTG)239TABLE 18-1: Controller-Centric Data Direction for USB Host or Target239FIGURE 18-1: USB OTG Module Block Diagram24018.1 Hardware Configuration24118.1.1 Device Mode241FIGURE 18-2: External Pull-Up for Full-Speed Device Mode241FIGURE 18-3: Bus Power Only241FIGURE 18-4: Self-power Only241FIGURE 18-5: Dual Power Example24118.1.2 Host and OTG Modes242FIGURE 18-6: Host Interface Example242FIGURE 18-7: OTG Interface Example24218.1.3 Using An External Interface24318.1.4 Calculating Transceiver Power Requirements243EQUATION 18-1: Estimating USB Transceiver Current Consumption24318.2 USB Buffer Descriptors and the BDT244FIGURE 18-8: BDT Mapping for Endpoint Buffering Modes24418.2.1 Buffer Ownership24518.2.2 DMA Interface245TABLE 18-2: Assignment of Buffer Descriptors for the Different Buffering Modes245Register 18-1: BDnSTAT: Buffer Descriptor n Status Register Prototype, USB Mode (BD0STAT through BD63STAT)246Register 18-2: BDnSTAT: Buffer Descriptor n Status Register Prototype, CPU Mode (BD0STAT Through BD63STAT)24718.3 USB Interrupts248FIGURE 18-9: USB OTG Interrupt Funnel24818.3.1 Clearing USB OTG Interrupts249FIGURE 18-10: Example of a USB Transaction and Interrupt Events24918.4 Device Mode Operation24918.4.1 Enabling device mode24918.4.2 Receiving an IN token in device mode25018.4.3 Receiving an OUT token in device mode25018.5 Host Mode Operation25018.5.1 Enable Host Mode and Discover a Connected Device25018.5.2 Complete a Control Transaction to a Connected Device25118.5.3 Send a Full-Speed Bulk Data Transfer to a Target Device25218.6 OTG Operation25218.6.1 Session Request Protocol (SRP)25218.6.2 Host Negotiation Protocol (HNP)25318.6.3 EXTERNAL Vbus COMPARATORS253TABLE 18-3: EXTERNAL Vbus COMPARATOR STATES25318.7 USB OTG Module Registers25418.7.1 USB OTG Module Control Registers255Register 18-3: U1OTGSTAT: USB OTG Status Register (Host Mode Only)255Register 18-4: U1OTGCON: USB On-the-Go Control Register256Register 18-5: U1PWRC: USB Power Control Register257Register 18-6: U1STAT: USB Status Register258Register 18-7: U1CON: USB Control Register (Device Mode)259Register 18-8: U1CON: USB Control Register (Host Mode Only)260Register 18-9: U1ADDR: USB Address Register261Register 18-10: U1TOK: USB Token Register (Host Mode Only)261Register 18-11: U1SOF: USB OTG Start-of-token Threshold Register (Host Mode Only)262Register 18-12: U1CNFG1: USB Configuration Register 1262Register 18-13: U1CNFG2: USB Configuration Register 226318.7.2 USB Interrupt Registers264Register 18-14: U1OTGIR: USB OTG Interrupt Status Register (Host mode Only)264Register 18-15: U1OTGIE: USB OTG Interrupt Enable Register (Host Mode Only)265Register 18-16: U1IR: USB Interrupt Status Register (Device Mode Only)266Register 18-17: U1IR: USB Interrupt Status Register (Host Mode Only)267Register 18-18: U1IE: USB Interrupt Enable Register (All USB Modes)268Register 18-19: U1EIR: USB Error Interrupt Status Register269Register 18-20: U1EIE: USB Error Interrupt Enable Register27018.7.3 USB Endpoint Management Registers271Register 18-21: U1EPn: USB Endpoint n Control Registers (n = 0 to 15)27118.7.4 USB Vbus Power Control Register272Register 18-22: U1PWMCON: USB Vbus PWM Generator Control Register27219.0 Enhanced Parallel Master Port (EPMP)27319.1 ALTPMP Setting273TABLE 19-1: Alternate EPMP Pins273TABLE 19-2: Parallel Master Port Pin Description274Register 19-1: PMCON1: EPMP Control Register 1275Register 19-2: PMCON2: EPMP Control Register 2276Register 19-3: PMCON3: EPMP Control Register 3277Register 19-4: PMCON4: EPMP Control Register 4278Register 19-5: PMCSxCF: Chip Select x Configuration Register279Register 19-6: PMCSxBS: Chip Select x Base Address Register280Register 19-7: PMCSxMD: Chip Select x Mode Register281Register 19-8: PMSTAT: EPMP Status Register (Slave mode only)282Register 19-9: PADCFG1: Pad Configuration Control Register28320.0 Real-Time Clock and Calendar (RTCC)285FIGURE 20-1: RTCC Block Diagram28520.1 RTCC Module Registers28620.1.1 Register Mapping286TABLE 20-1: RTCVAL Register Mapping286TABLE 20-2: ALRMVAL Register Mapping28620.1.2 Write Lock286EXAMPLE 20-1: Setting the RTCWREN Bit28620.1.3 RTCC Control Registers287Register 20-1: RCFGCAL: RTCC Calibration and Configuration Register(1)287Register 20-2: PADCFG1: Pad Configuration Control Register288Register 20-3: ALCFGRPT: Alarm Configuration Register28920.1.4 RTCVAL Register Mappings290Register 20-4: YEAR: Year Value Register(1)290Register 20-5: MTHDY: Month and Day Value Register(1)290Register 20-6: WKDYHR: Weekday and Hours Value Register(1)291Register 20-7: MINSEC: Minutes and Seconds Value Register29120.1.5 ALRMVAL Register Mappings292Register 20-8: ALMTHDY: Alarm Month and Day Value Register(1)292Register 20-9: ALWDHR: Alarm Weekday and Hours Value Register(1)293Register 20-10: ALMINSEC: Alarm Minutes and Seconds Value Register29320.2 Calibration294EQUATION 20-1: RTCC Calibration29420.3 Alarm29420.3.1 Configuring the Alarm29420.3.2 Alarm Interrupt294FIGURE 20-2: Alarm Mask Settings29521.0 32-Bit Programmable Cyclic Redundancy Check (CRC) Generator297FIGURE 21-1: CRC Block Diagram297FIGURE 21-2: CRC Shift Engine Detail29721.1 User Interface29821.1.1 Polynomial Interface298EQUATION 21-1: 16-Bit, 32-bit CRC Polynomials29821.1.2 DATA INTERFACE298TABLE 21-1: CRC SETUP EXAMPLES FOR 16 AND 32-BIT POLYNOMIALs29821.1.3 Data Shift Direction29921.1.4 Interrupt Operation29921.1.5 Typical Operation299Register 21-1: CRCCON1: CRC Control 1 Register300Register 21-2: CRCCON2: CRC Control 2 Register301Register 21-3: CRCXORL: CRC XOR POLYNOMIAL REGISTER, LOW BYTE301Register 21-4: CRCXORH: CRC XOR High Register302Register 21-5: CRCDATL: CRC Data Low Register302Register 21-6: CRCDATH: CRC Data High Register302Register 21-7: CRCWDATL: CRC Shift Low Register303Register 21-8: CRCWDATH: CRC Shift High Register30322.0 Graphics Controller Module (GFX)305FIGURE 22-1: Graphics Module Overview30522.1 GFX Module Registers306Register 22-1: G1CMDL: GPU COMMAND LOW REGISTER306Register 22-2: G1CMDH: GPU COMMAND HIGH REGISTER306Register 22-3: G1CON1: DISPLAY CONTROL REGISTER 1307Register 22-4: G1CON2: DISPLAY CONTROL REGISTER 2308Register 22-5: G1CON3: DISPLAY CONTROL REGISTER 3309Register 22-6: G1STAT: GFX Status REGISTER310Register 22-7: G1IE: GFX INTERRUPT ENABLE REGISTER311Register 22-8: G1IR: GFX INTERRUPT STATUS REGISTER312Register 22-9: G1W1ADRL: GPU WORK AREA 1 START ADDRESS REGISTER LOW313Register 22-10: G1W1ADRH: GPU WORK AREA 1 START ADDRESS REGISTER HIGH313Register 22-11: G1W2ADRL: GPU WORK AREA 2 START ADDRESS REGISTER LOW313Register 22-12: G1W2ADRH: GPU WORK AREA 2 START ADDRESS REGISTER HIGH314Register 22-13: G1PUW: GPU WORK AREA WIDTH REGISTER314Register 22-14: G1PUH: GPU WORK AREA HEIGHT REGISTER314Register 22-15: G1DPADRL: DISPLAY BUFFER START ADDRESS REGISTER LOW315Register 22-16: G1DPADRH: DISPLAY BUFFER START ADDRESS REGISTER HIGH315Register 22-17: G1DPW: DISPLAY Buffer WIDTH REGISTER315Register 22-18: G1DPH: DISPLAY Buffer HEIGHT REGISTER316Register 22-19: G1DPWT: DISPLAY TOTAL WIDTH REGISTER316Register 22-20: G1DPHT: DISPLAY TOTAL HEIGHT REGISTER316Register 22-21: G1ACTDA: ACTIVE DISPLAY AREA REGISTER317Register 22-22: G1HSYNC: HORIZONTAL SYNCHRONIZATION CONTROL REGISTER317Register 22-23: G1VSYNC: VERTICAL SYNCHRONIZATION CONTROL REGISTER318Register 22-24: G1DBLCON: DISPLAY BLANKING CONTROL REGISTER318Register 22-25: G1CLUT: COLOR LOOK-UP TABLE CONTROL REGISTER319Register 22-26: G1CLUTWR: COLOR LOOK-UP TABLE (CLUT) Memory WRITE DATA REGISTER320Register 22-27: G1CLUTRD: COLOR LOOK-UP TABLE (CLUT) MEMORY READ DATA REGISTER320Register 22-28: G1MRGN: INTERRUPT ADVANCE REGISTER321Register 22-29: G1CHRX: CHARACTER-X COORDINATE PRINT POSITION REGISTER321Register 22-30: G1CHRY: CHARACTER Y-COORDINATE PRINT POSITION REGISTER322Register 22-31: G1IPU: INFLATE PROCESSOR STATUS REGISTER322Register 22-32: G1DBEN: DATA I/O PAD ENABLE REGISTER32322.2 Display Resolution and Memory Requirements32422.3 Display Clock (GCLK) Source32422.4 Display Buffer and Work Areas Memory Locations324TABLE 22-1: Buffer Memory Requirements vs. Display Configuration32423.0 10-Bit High-Speed A/D Converter325FIGURE 23-1: 10-Bit High-Speed A/D Converter Block Diagram326Register 23-1: AD1CON1: A/D Control Register 1327Register 23-2: AD1CON2: A/D Control Register 2328Register 23-3: AD1CON3: A/D Control Register 3329Register 23-4: AD1CHS: A/D Input Select Register330Register 23-5: ANCFG: A/D Band gap Reference Configuration Register331Register 23-6: AD1CSSL: A/D Input Scan Select Register (Low)331Register 23-7: AD1CSSH: A/D Input Scan Select Register (High)332EQUATION 23-1: A/D Conversion Clock Period(1)332FIGURE 23-2: 10-bit A/D Converter Analog Input Model333FIGURE 23-3: A/D Transfer Function33324.0 Triple Comparator Module335FIGURE 24-1: Triple Comparator Module Block Diagram335FIGURE 24-2: Individual Comparator Configurations when CREF = 0336FIGURE 24-3: Individual Comparator Configurations when CREF = 1 and CVREFP = 0337FIGURE 24-4: Individual Comparator Configurations when CREF = 1 and CVREFP = 1337Register 24-1: CMxCON: Comparator x Control Registers (Comparators 1 Through 3)338Register 24-2: CMSTAT: Comparator Module Status Register33925.0 Comparator Voltage Reference34125.1 Configuring the Comparator Voltage Reference341FIGURE 25-1: Comparator Voltage Reference Block Diagram341Register 25-1: CVRCON: Comparator Voltage Reference Control Register34226.0 Charge Time Measurement Unit (CTMU)34326.1 Measuring Capacitance343FIGURE 26-1: Typical Connections and Internal Configuration for Capacitance Measurement34326.2 Measuring Time34426.3 Pulse Generation and Delay344FIGURE 26-2: Typical Connections and Internal Configuration for Time Measurement Time344FIGURE 26-3: Typical Connections and Internal Configuration for Pulse Delay Generation344Register 26-1: CTMUCON: CTMU Control Register345Register 26-2: CTMUICON: CTMU current Control Register34627.0 Special Features34727.1 Configuration Bits34727.1.1 Considerations for Configuring PIC24FJ256DA210 family Devices347TABLE 27-1: Flash Configuration Word Locations for PIC24FJ256DA210 family Devices347Register 27-1: CW1: Flash Configuration Word 1348Register 27-2: CW2: Flash Configuration Word 2350Register 27-3: CW3: Flash Configuration Word 3351Register 27-4: CW4: Flash Configuration Word 4352Register 27-5: DEVID: Device ID Register353Register 27-6: DEVREV: Device Revision Register35427.2 On-Chip Voltage Regulator35427.2.1 Voltage Regulator Low-Voltage Detection354FIGURE 27-1: Connections for the On-Chip Regulator35427.2.2 On-Chip Regulator and POR35427.2.3 On-Chip Regulator and BOR35527.2.4 Voltage Regulator Standby Mode35527.3 Watchdog Timer (WDT)35527.3.1 Windowed Operation35627.3.2 Control Register356FIGURE 27-2: WDT Block Diagram35627.4 Program Verification and Code Protection35727.4.1 General Segment Protection35727.4.2 Code Segment Protection35727.4.3 Configuration Register Protection358TABLE 27-2: Code Segment Protection Configuration Options35827.5 JTAG Interface35827.6 In-Circuit Serial Programming™35827.7 In-Circuit Debugger35828.0 Development Support35928.1 MPLAB Integrated Development Environment Software35928.2 MPLAB C Compilers for Various Device Families36028.3 HI-TECH C for Various Device Families36028.4 MPASM Assembler36028.5 MPLINK Object Linker/ MPLIB Object Librarian36028.6 MPLAB Assembler, Linker and Librarian for Various Device Families36028.7 MPLAB SIM Software Simulator36128.8 MPLAB REAL ICE In-Circuit Emulator System36128.9 MPLAB ICD 3 In-Circuit Debugger System36128.10 PICkit 3 In-Circuit Debugger/Programmer and PICkit 3 Debug Express36128.11 PICkit 2 Development Programmer/Debugger and PICkit 2 Debug Express36228.12 MPLAB PM3 Device Programmer36228.13 Demonstration/Development Boards, Evaluation Kits, and Starter Kits36229.0 Instruction Set Summary363TABLE 29-1: Symbols Used in Opcode Descriptions364TABLE 29-2: Instruction Set Overview36530.0 Electrical Characteristics371Absolute Maximum Ratings(†)37130.1 DC Characteristics372FIGURE 30-1: PIC24FJ256DA210 family Voltage-Frequency Graph (Industrial)372TABLE 30-1: Thermal Operating Conditions372TABLE 30-2: Thermal Packaging Characteristics372TABLE 30-3: DC Characteristics: Temperature and Voltage Specifications373TABLE 30-4: DC Characteristics: Operating Current (Idd)374TABLE 30-5: DC Characteristics: Idle Current (Iidle)375TABLE 30-6: DC Characteristics: Power-Down Current (Ipd)376TABLE 30-7: DC Characteristics: I/O Pin Input Specifications377TABLE 30-8: DC Characteristics: I/O Pin Output Specifications378TABLE 30-9: DC Characteristics: Program Memory378TABLE 30-10: Internal Voltage Regulator Specifications37930.2 AC Characteristics and Timing Parameters379TABLE 30-11: Temperature and Voltage Specifications – AC379FIGURE 30-2: Load Conditions for Device Timing Specifications379TABLE 30-12: Capacitive Loading Requirements on Output Pins380FIGURE 30-3: External Clock Timing380TABLE 30-13: External Clock Timing Requirements381TABLE 30-14: PLL Clock Timing Specifications (Vdd = 2.2V to 3.6V)381TABLE 30-15: Internal RC Accuracy382TABLE 30-16: RC Oscillator Start-Up Time382TABLE 30-17: Reset and Brown-out Reset Requirements382FIGURE 30-4: CLKO and I/O Timing Characteristics383TABLE 30-18: CLKO and I/O Timing Requirements383TABLE 30-19: ADC Module Specifications384TABLE 30-20: ADC Conversion Timing Requirements(1)38531.0 Packaging Information38731.1 Package Marking Information38731.2 Package Details388Appendix A: Revision History397Revision A (February 2010)397Revision B (May 2010)397INDEX399The Microchip Web Site405Customer Change Notification Service405Customer Support405Reader Response406Product Identification System407Worldwide Sales and Service408Size: 3.12 MBPages: 408Language: EnglishOpen manual