參數(shù)資料
型號: ADNS-2051
英文描述: Optical Mouse Sensor
中文描述: 光學(xué)鼠標傳感器
文件頁數(shù): 23/40頁
文件大?。?/td> 454K
代理商: ADNS-2051
23
SPI communication code for the Cypress CY7C63000 or CY7C63001
(Please consult factory for the CY7C63722 or CY7C63723 codes.)
Note: This programming sequence is not covered in Agilent's product warranty. It is only a recommended example when using the
mentioned Cypress microcontrollers. For the latest updates on Cypress microcontrollers, please contact Cypress at email:
usbapps@cypress.com or call (858) 613-7929 (US).
The following code can be used to implement the SPI data communications. See the schematic in Figure 9.
;
;
;
;
;
;
Notes:
CY7C63001 20pin package
ADNS-2051
SDIO line connected to pin5 (P1.0)
PD connected to pin 16 (P1.1)
SCLK line connected to pin15 (P1.3)
;
PoI/O port
Port1_Interrupt: equ
Port1_Pullup:
01h
05h
09h
; GPIO data port 1
; Interrupt enable for port 1
; Pullup resistor control for port 1
equ
;
;
SDPort bit definequ
PD:
SCLK:
Pt1_Current:
;
;
PoGPIO Isink regequ
Port1_Isink0:
Port1_Isink1:
Port1_Isink3:
;
;
;
spdata memory vaequ
spi_data:
bit_counter:
port1_wrote:
;
equ
equ
equ
01h
02h
08h
00h
; bit 0
; bit 1
; bit 3
; port1 current setting
equ
equ
equ
38h
38h
39h
3Bh
equ
equ
equ
40h
41h
44h
45h
; address of spi writes
; data of spi writes
; SPI bit counter
; what we wrote last
;
;
;
initialize Port 1
mov A, Pt1_Current
iowr Port1_Isink0
iowr Port1_Isink1
iowr Port1_Isink3
; select DAC setting
; isink current Port 1 bit[0]
; isink current Port 1 bit[1]
; isink current Port 1 bit[3]
mov A, 0h
iowr Port1_Pullup
; enable Port 1 bit [7:0] pullups
mov A, ~(PD|SDIO)
mov [port1_wrote], A
mov A, [port1_wrote]
iowr Port1_Data
; turn on the ADNS-2051
; PD low, SCLK, SDIO
mov A, 0
iowr Port1_Interrupt
; disable port 1 interrupts
;
;
;
;
There are possible problems with the SPI port if the microcontroller starts executing
instructionsbefore the ADNS-2051 sensor has powered up. See page 18 for details.
It is assumed that power to the microcontroller is OK if the next instructions can be executed.
These instructions will reset the SPI port of the sensor.
Resync_sensor:
mov A,~(SCLK|SDIO|PD) ; set the SCLK, SDIO and PD lines low
and [port1_wrote], A
mov A, [port1_wrote]
相關(guān)PDF資料
PDF描述
ADP1109A Micropower Low Cost Fixed 3.3 V, 5 V, 12 V and Adjustable DC-to-DC Converter(微功耗,低成本固定或可調(diào)輸出DC-DC轉(zhuǎn)換器)
ADP1109 Micropower DC-DC Converter(可調(diào)/固定輸出,微功耗DC-DC轉(zhuǎn)換器)
ADP1147-3.3 High Efficiency Step-Down Switching Regulator Controllers(高效率步降開關(guān)穩(wěn)壓控制器)
ADP1147-5 High Efficiency Step-Down Switching Regulator Controllers(高效率步降開關(guān)穩(wěn)壓控制器)
ADP1148-5 500kHz and 1MHz High Efficiency 1.5A Switching Regulators; Package: SO; No of Pins: 8; Temperature Range: -40?°C to 85?°C
相關(guān)代理商/技術(shù)參數(shù)
參數(shù)描述
ADNS-2080 功能描述:光學(xué)導(dǎo)航傳感器 LED Sensor RoHS:否 制造商:Avago Technologies 工作電源電壓: 封裝 / 箱體: 最大工作溫度: 最小工作溫度:
ADNS-2120 功能描述:光學(xué)導(dǎo)航傳感器 Round Mouse Lens RoHS:否 制造商:Avago Technologies 工作電源電壓: 封裝 / 箱體: 最大工作溫度: 最小工作溫度:
ADNS-2120-001 功能描述:光學(xué)導(dǎo)航傳感器 Trim Mouse Lens RoHS:否 制造商:Avago Technologies 工作電源電壓: 封裝 / 箱體: 最大工作溫度: 最小工作溫度:
ADNS-2220 功能描述:光學(xué)導(dǎo)航傳感器 Black Optical Mouse Clip RoHS:否 制造商:Avago Technologies 工作電源電壓: 封裝 / 箱體: 最大工作溫度: 最小工作溫度:
ADNS-2220-001 功能描述:光學(xué)導(dǎo)航傳感器 Clear Optical Mouse Clip RoHS:否 制造商:Avago Technologies 工作電源電壓: 封裝 / 箱體: 最大工作溫度: 最小工作溫度: