Freelance Electronics Components Distributor
Closed Dec 25th-26th
800-300-1968
We Stock Hard to Find Parts

C8051F041-GQ

Part # C8051F041-GQ
Description MCU 8BIT CISC 64KB FLASH 3V 64TQFP - Trays
Category IC
Availability In Stock
Qty 2
Qty Price
1 + $20.05559
Manufacturer Available Qty
SILICON LABORATORIES
Date Code: 0903
  • Shipping Freelance Stock: 2
    Ships Immediately



Technical Document


DISCLAIMER: The information provided herein is solely for informational purposes. Customers must be aware of the suitability of this product for their application, and consider that variable factors such as Manufacturer, Product Category, Date Codes, Pictures and Descriptions may differ from available inventory.

C8051F040/1/2/3/4/5/6/7
154 Rev. 1.5
12.3.2. External Interrupts
The external interrupt sources (/INT0 and /INT1) are configurable as active-low level-sensitive or active-
low edge-sensitive inputs depending on the setting of bits IT0 (TCON.0) and IT1 (TCON.2). IE0 (TCON.1)
and IE1 (TCON.3) serve as the interrupt-pending flag for the /INT0 and /INT1 external interrupts, respec-
tively. If an /INT0 or /INT1 external interrupt is configured as edge-sensitive, the corresponding interrupt-
pending flag is automatically cleared by the hardware when the CPU vectors to the ISR. When configured
as level sensitive, the interrupt-pending flag follows the state of the external interrupt's input pin. The exter-
nal interrupt source must hold the input active until the interrupt request is recognized. It must then deacti-
vate the interrupt request before execution of the ISR completes or another interrupt request will be
generated.
Table 12.4. Interrupt Summary
Interrupt Source
Interrupt
Vector
Priority
Order
Pending Flag
Bit addressable?
Cleared by HW?
SFRPAGE (SFRPGEN = 1)
Enable
Flag
Priority
Control
Reset 0x0000 Top None N/A N/A 0
Always
Enabled
Always
Highe
st
External Interrupt 0
(/INT0)
0x0003 0 IE0 (TCON.1) Y Y 0 EX0 (IE.0) PX0 (IP.0)
Timer 0 Overflow 0x000B 1 TF0 (TCON.5) Y Y 0 ET0 (IE.1) PT0 (IP.1)
External Interrupt 1
(/INT1)
0x0013 2 IE1 (TCON.3) Y Y 0 EX1 (IE.2) PX1 (IP.2)
Timer 1 Overflow 0x001B 3 TF1 (TCON.7) Y Y 0 ET1 (IE.3) PT1 (IP.3)
UART0 0x0023 4
RI0 (SCON0.0)
TI0 (SCON0.1)
Y 0 ES0 (IE.4) PS0 (IP.4)
Timer 2 0x002B 5 TF2 (TMR2CN.7) Y 0 ET2 (IE.5) PT2 (IP.5)
Serial Peripheral
Interf
ace
0x0033 6
SPIF (SPI0CN.7)
WCOL (SPI0CN.6)
MODF (SPI0CN.5)
RXOVRN
(S
PI0CN.4)
Y 0
ESPI0
(EIE1.0)
PSPI0
(EIP1.0)
SMBus Interface 0x003B 7 SI (SMB0CN.3) Y 0
ESMB0
(EIE1.1)
PSMB0
(EIP1.1)
ADC0 Window
Comp
arator
0x0043 8
AD0WINT
(A
DC0CN.2)
Y 0
EWADC0
(EIE1.2)
PWADC0
(EIP1.2)
Programmable
Coun
ter Array
0x004B 9
CF (PCA0CN.7)
CCFn (PCA0CN.n)
Y 0
EPCA0
(EIE1.3)
PPCA0
(EIP1.3)
Comparator 0 0x0053 10
CP0FIF/CP0RIF
(C
PT0CN.4/.5)
1
CP0IE
(EIE1.4)
PCP0
(EIP1.4)
C8051F040/1/2/3/4/5/6/7
Rev. 1.5 155
Comparator 1 0x005B 11
CP1FIF/CP1RIF
(C
PT1CN.4/.5)
2
CP1IE
(EIE1.5)
PCP1
(EIP1.5)
Comparator 2 0x0063 12
CP2FIF/CP2RIF
(C
PT2CN.4/.5)
3
CP2IE
(EIE1.6)
PCP2
(EIP1.6)
Timer 3 0x0073 14 TF3 (TMR3CN.7) 1
ET3
(EIE2.0)
PT3
(EIP2.0)
ADC0 End of
Conver
sion
0x007B 15
ADC0INT
(A
DC0CN.5)
Y 0
EADC0
(EIE2.1)
PADC0
(EIP2.1)
Timer 4 0x0083 16 TF4 (TMR4CN.7) 2
ET4
(EIE2.2)
PT4
(EIP2.2)
ADC2 Window
Comp
arator
0x0093 17
AD2WINT
(ADC2CN.0)
2
EWADC2
(EIE2.3)
PWADC2
(EIP2.3)
ADC2 End of
Conver
sion
0x008B 18
ADC2INT
(A
DC1CN.5)
2
EADC1
(EIE2.4)
PADC1
(EIP2.4)
CAN Interrupt 0x009B 19 CAN0CN.7 Y 1
ECAN0
(EIE2.5)
PCAN0
(EIP2.5)
UART1 0x00A3 20
RI1 (SCON1.0)
TI1 (SCON1.1)
1
ES1
(EIE2.6)
PS1
(EIP2.6)
Table 12.4. Interrupt Summary (Continued)
Interrupt Source
Interrupt
Vector
Priority
Order
Pending Flag
Bit addressable?
Cleared by HW?
SFRPAGE (SFRPGEN = 1)
Enable
Flag
Priority
Control
C8051F040/1/2/3/4/5/6/7
156 Rev. 1.5
12.3.3. Interrupt Priorities
Each interrupt source can be individually programmed to one of two priority levels: low or high. A low prior-
ity interrupt service routine can be preempted by a high priority interrupt. A high priority interrupt cannot be
preempted. Each interrupt has an associated interrupt priority bit in an SFR (IP-EIP2) used to configure its
priority level. Low priority is the default. If two interrupts are recognized simultaneously, the interrupt with
the higher priority is serviced first. If both interrupts have the same priority level, a fixed priority order is
used to arbitrate, given in Table 12.4.
12.3.4. Interrupt Latency
Interrupt response time depends on the state of the CPU when the interrupt occurs. Pending interrupts are
sampled and priority decoded each system clock cycle. The fastest possible response time is 5 system
clock cycles: 1 clock cycle to detect the interrupt and 4 clock cycles to complete the LCALL to the ISR. If
an interrupt is pending when a RETI is executed, a single instruction is executed before an LCALL is made
to service the pending interrupt. Therefore, the slowest response time for an interrupt (when no other inter-
rupt is currently being serviced or the new interrupt is of greater priority) occurs when the CPU is perform-
ing an RETI instruction followed by a DIV as the next instruction. In this case, the response time is
18 system clock cycles: 1 clock cycle to detect the interrupt, 5 clock cycles to execute the RETI, 8 clock
cycles to complete the DIV instruction and 4 clock cycles to execute the LCALL to the ISR. If the CPU is
executing an ISR for an interrupt with equal or higher priority, the new interrupt will not be serviced until the
current ISR completes, including the RETI and following instruction.
12.3.5. Interrupt Register Descriptions
The SFRs used to enable the interrupt sources and set their priority level are described below. Refer to the
datasheet section associated with a particular on-chip peripheral for information regarding valid interrupt
conditions for the peripheral and the behavior of its interrupt-pending flag(s).
PREVIOUS4546474849505152535455565758NEXT