參數(shù)資料
型號: pic16ce623
廠商: Microchip Technology Inc.
英文描述: OTP 8-Bit CMOS MCU with EEPROM Data Memory(8位OTP CMOS微控制器)
中文描述: 檢察官辦公室8位CMOS微控制器EEPROM數(shù)據(jù)存儲器(8位檢察官辦公室的CMOS微控制器)
文件頁數(shù): 43/108頁
文件大?。?/td> 2355K
代理商: PIC16CE623
1998 Microchip Technology Inc.
Preliminary
DS40182A-page 43
PIC16CE62X
The code example in Example 8-1 depicts the steps
required to configure the comparator module. RA3 and
RA4 are configured as digital output. RA0 and RA1 are
configured as the V- inputs and RA2 as the V+ input to
both comparators.
EXAMPLE 8-1:
INITIALIZING
COMPARATOR MODULE
8.2
Comparator Operation
A single comparator is shown in Figure 8-3 along with
the relationship between the analog input levels and
the digital output. When the analog input at V
IN
+ is less
than the analog input V
IN
–, the output of the
comparator is a digital low level. When the analog input
at V
IN
+ is greater than the analog input V
IN
–, the output
of the comparator is a digital high level. The shaded
areas of the output of the comparator in Figure 8-3
represent the uncertainty due to input offsets and
response time.
FLAG_REG
CLRF
CLRF
MOVF
ANDLW
IORWF
MOVLW
MOVWF
BSF
MOVLW
MOVWF
EQU
FLAG_REG
PORTA
CMCON,W
0xC0
FLAG_REG,F
0x03
CMCON
STATUS,RP0
0x07
TRISA
0X20
;Init flag register
;Init PORTA
;Move comparator contents to W
;Mask comparator bits
;Store bits in flag register
;Init comparator mode
;CM<2:0> = 011
;Select Bank1
;Initialize data direction
;Set RA<2:0> as inputs
;RA<4:3> as outputs
;TRISA<7:5> always read ‘0’
;Select Bank 0
;10
μ
s delay
;Read CMCONtoend changecondition
;Clear pending interrupts
;Select Bank 1
;Enable comparator interrupts
;Select Bank 0
INTCON,PEIE ;Enable peripheral interrupts
INTCON,GIE
;Global interrupt enable
BCF
CALL
MOVF
BCF
BSF
BSF
BCF
BSF
BSF
STATUS,RP0
DELAY 10
CMCON,F
PIR1,CMIF
STATUS,RP0
PIE1,CMIE
STATUS,RP0
8.3
Comparator Reference
An external or internal reference signal may be used
depending on the comparator operating mode. The
analog signal that is present at V
IN
– is compared to the
signal at V
IN
+, and the digital output of the comparator
is adjusted accordingly (Figure 8-3).
FIGURE 8-3:
SINGLE COMPARATOR
8.3.1
EXTERNAL REFERENCE SIGNAL
When external voltage references are used, the
comparator module can be configured to have the com-
parators operate from the same or different reference
sources. However, threshold detector applications may
require the same reference. The reference signal must
be between V
SS
and V
DD
, and can be applied to either
pin of the comparator(s).
8.3.2
INTERNAL REFERENCE SIGNAL
The comparator module also allows the selection of an
internally generated voltage reference for the
comparators. Section 13, Instruction Sets, contains a
detailed description of the Voltage Reference Module
that provides this signal. The internal reference signal
is used when the comparators are in mode
CM<2:0>=010 (Figure 8-2). In this mode, the internal
voltage reference is applied to the V
IN
+ pin of both com-
parators.
+
V
IN
+
V
IN
Output
V
IN–
V
IN+
Output
相關(guān)PDF資料
PDF描述
pic16ce624 OTP 8-Bit CMOS MCU with EEPROM Data Memory(8位OTP CMOS微控制器)
pic16ce625 OTP 8-Bit CMOS MCU with EEPROM Data Memory(8位OTP CMOS微控制器)
pic16cr54c ROM-Based 8-Bit CMOS Microcontroller Series(8位CMOS微控制器)
PIC16CR73 28/40-Pin, 8-Bit CMOS ROM Microcontrollers
PIC16CR74 28/40-Pin, 8-Bit CMOS ROM Microcontrollers
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
PIC16CE623/JW 功能描述:8位微控制器 -MCU .875KB 96 RAM 13 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16CE623-04/P 功能描述:8位微控制器 -MCU .875KB 96 RAM 13 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16CE623-04/SO 功能描述:8位微控制器 -MCU .875KB 96 RAM 13 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16CE623-04/SS 功能描述:8位微控制器 -MCU .875KB 96 RAM 13 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT
PIC16CE623-04E/P 功能描述:8位微控制器 -MCU .875KB 96 RAM 13 I/O RoHS:否 制造商:Silicon Labs 核心:8051 處理器系列:C8051F39x 數(shù)據(jù)總線寬度:8 bit 最大時鐘頻率:50 MHz 程序存儲器大小:16 KB 數(shù)據(jù) RAM 大小:1 KB 片上 ADC:Yes 工作電源電壓:1.8 V to 3.6 V 工作溫度范圍:- 40 C to + 105 C 封裝 / 箱體:QFN-20 安裝風(fēng)格:SMD/SMT