欢迎访问ic37.com |
会员登录 免费注册
发布采购

SN8P2742PDB 参数 Datasheet PDF下载

SN8P2742PDB图片预览
型号: SN8P2742PDB
PDF下载: 下载PDF文件 查看货源
内容描述: [ADC, OP-amp, Comparator 8-Bit Micro-Controller]
分类和应用:
文件页数/大小: 136 页 / 3074 K
品牌: SONIX [ SONIX TECHNOLOGY COMPANY ]
 浏览型号SN8P2742PDB的Datasheet PDF文件第69页浏览型号SN8P2742PDB的Datasheet PDF文件第70页浏览型号SN8P2742PDB的Datasheet PDF文件第71页浏览型号SN8P2742PDB的Datasheet PDF文件第72页浏览型号SN8P2742PDB的Datasheet PDF文件第74页浏览型号SN8P2742PDB的Datasheet PDF文件第75页浏览型号SN8P2742PDB的Datasheet PDF文件第76页浏览型号SN8P2742PDB的Datasheet PDF文件第77页  
SN8P2740 Series  
ADC, OP-amp, Comparator 8-Bit Micro-Controller  
Example: Set P4.1 to be general purpose input mode. P4CON.1 must be set as 0.  
; Check GCHS and CHS[2:0] status.  
B0BCLR  
B0BCLR  
FGCHS  
;If CHS[2:0] point to P4.1 (CHS[2:0] = 001B), set GCHS=0  
;If CHS[2:0] don’t point to P4.1 (CHS[2:0] 001B), don’t  
care GCHS status.  
; Clear P4CON.  
P4CON.1  
P4M.1  
; Enable P4.1 digital function.  
; Set P4.1 as input mode.  
; Enable P4.1 input mode.  
B0BCLR  
Example: Set P4.1 to be general purpose output. P4CON.1 must be set as 0.  
; Check GCHS and CHS[2:0] status.  
B0BCLR  
FGCHS  
;If CHS[2:0] point to P4.1 (CHS[2:0] = 001B), set GCHS=0.  
;If CHS[2:0] don’t point to P4.1 (CHS[2:0] 001B), don’t  
care GCHS status.  
; Clear P4CON.  
B0BCLR  
P4CON.1  
; Enable P4.1 digital function.  
; Set P4.1 output buffer to avoid glitch.  
B0BSET  
P4.1  
; Set P4.1 buffer as 1.  
; Set P4.1 buffer as 0.  
; or  
B0BCLR  
P4.1  
; Enable P4.1 output mode.  
B0BSET  
P4M.1  
; Set P4.1 as input mode.  
P4.0 is shared with general purpose I/O, ADC input (AIN0) and ADC external high reference voltage input. AVREFH  
flag of ADM register is external ADC high reference voltage input control bit. If AVREFH is enabled, P4.0 general  
purpose I/O and ADC analog input (AIN0) functions are disabled. P4.0 pin is connected to ADC high reference voltage  
directly.  
Note: For P4.0 general purpose I/O and AIN0 functions, AVREFH must be set as 0.  
Example: Set P4.0 to be general purpose input mode. AVREFH and P4CON.0 bits must be set as 0.  
; Check AVREFH status.  
B0BTS0  
FAVREFH  
; Check AVREFH = 0.  
B0BCLR  
FAVREFH  
; AVREFH = 1, clear it to disable external ADC high  
reference input.  
; AVREFH = 0, execute next routine.  
; Check GCHS and CHS[2:0] status.  
B0BCLR  
FGCHS  
;If CHS[2:0] point to P4.0 (CHS[2:0] = 000B), set GCHS=0  
;If CHS[2:0] don’t point to P4.0 (CHS[2:0] 000B), don’t  
care GCHS status.  
; Clear P4CON.  
B0BCLR  
P4CON.0  
P4M.0  
; Enable P4.0 digital function.  
; Set P4.0 as input mode.  
; Enable P4.0 input mode.  
B0BCLR  
SONiX TECHNOLOGY CO., LTD  
Page 73  
Version 2.0  
 复制成功!