亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? jry9524_63723_asm.htm

?? Cy7c63723的完整固件 cy7c63723和CY7C63001相比
?? HTM
?? 第 1 頁 / 共 5 頁
字號:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<!-- saved from url=(0053)http://www.driverdevelop.com/source/jry9524_63723.asm -->
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=gb2312">
<META content="MSHTML 6.00.2800.1528" name=GENERATOR></HEAD>
<BODY><PRE>;***************************************************************************
;
; File: 637mouse.asm
; Version: 1.02
; Description: This code provides both PS/2 and USB support for a combi
;              mouse
; Target: Cypress CY7C63743
;
; Overview
;        On power up, the firmware starts executing code at address 0h. 
; After some housekeeping tasks it will determine whether it is attached to
; a USB or a PS2 interface. From that, it will branch either to USB_Main or
; PS2_Main.
;
; PS2 Overview
;        There are four main tasks:
;        * PS2_Main
;        * buttons (common to USB and PS2)
;        * optics (common to USB and PS2)
;        * PS2_DoCommand - processing of PS2 commands from host
;
; PS2_Main
;        This routine initializes the PS2 variables, the IO ports, computes
; the (X,Y) coordinates of mouse movement, the Z-coordinate of wheel motion,
; if needed, determines which button has been pressed and sends out a mouse 
; packet to a host.
;
; PS2_DoCommand
;        When a host wants to send data to the mouse it will drive the
; SDATA line low. The PS2_Main task will continuously poll it and will clock 
; in the data. The latter will be parsed and processed.
;
; USB Overview
;        There are also four main tasks: 
;        * USB_Main
;        * buttons (common to USB and PS2)
;        * optics (common to USB and PS2)
;        * suspend/resume 
;
; USB_Main
;        This routine initializes the USB variables, the IO ports, the mouse
; logic, and the data space. All USB communication occurs on an interrupt 
; basis.
; 
;        Endpoint 0 is used to support Control Transfers and vendor specific
; requests.  During enumeration setup commands are sent to endpoint1 to 
; initialize the USB device and to extract configuration information from the
; device
;
;        Endpoint 1 is used to transfer interrupt data back to the host.  
; In this case we transfer data from the button and optics back to the host. 
;
; Buttons
;        The buttons are polled every millisecond inside the 1ms handler and
; processed in the main task loop.
;
; Optics
;        The optics for mouse mouvement (X,Y,Z) are continuously polled
; and processed in the main task loop.  The quadrature state of the optics
; tells us which direction the mouse is moving in. This data is sent back to
; the host as an offset from the last time the mouse was polled for data by
; the host. Further, for PS/2, the optics will be polled and processed every
; time a bit is sent out or received. This prevents missing any optics count
; during PS2 data transfer.
;
; Suspend/Resume
;        Every millisecond, the USB is polled for activity. If no activity
; occurs for three milliseconds, then it is assumed that the USB is in 
; suspend.  Because this device supports remote wakeup, pressing the buttons
; or moving the mouse causes the firmware to send resume signalling back 
; to the host to wakeup and resume operation.
;
; Endpoint1 packet definition
;     Byte      Usage
;      0    Button Data 7-3 Not used, 2=middle, 1=right, 0=left
;      1    horizontal displacement measured via the optics
;      2    vertical displacement measured via the optics
;      3    z-displacement (wheel) measured via the optics
;
; Revisions:
;    10/09/00: Original Version. Taken from u5combi.asm, v.1.03
;
;    1.00    
;       Fixed the Chapter 9 Test - device remote wakeup
;
;    1.01    
;       Fixed the suspend current requirements by explicitly writing SUSPEND
; and RUN bits of the processor status control register when going into 
; suspend
;
;    1.02
;	Convert TABS into spaces. No code change.
;    
;***************************************************************************
;
;        Copyright 2000 Cypress Semiconductor
;    This code is provided by Cypress as a reference.  Cypress makes no
;    claims or warranties to this firmware's suitability for any 
;    application. 
;
;*************************************************************************** 

    CPU    63743

    XPAGEON

    INCLUDE "637xx.inc"
    INCLUDE "USB.inc"
    INCLUDE "PS2.inc"
    INCLUDE "macros.inc"

;
; Supported Interfaces 
;
USB_MOUSE:                      equ    01h
PS2_MOUSE:                      equ    00h

;
; EP0 In-Transaction State Machine
;
EP0_IN_IDLE:                    equ    00h
CONTROL_READ_DATA:              equ    02h
NO_DATA_STATUS:                 equ    04h
EP0_IN_STALL:                   equ    06h

;
; EP0 No-Data Control Flags
;
ADDRESS_CHANGE_PENDING:         equ    00h
NO_CHANGE_PENDING:              equ    02h

;
; Response Sizes
;
DEVICE_STATUS_LENGTH:           equ    2
DEVICE_CONFIG_LENGTH:           equ    1
ENDPOINT_STALL_LENGTH:          equ    2
INTERFACE_STATUS_LENGTH:        equ    2
INTERFACE_ALTERNATE_LENGTH:     equ    1
INTERFACE_PROTOCOL_LENGTH:      equ    1

;
; General Constants
;
BIT0:                           equ    01h
BIT1:                           equ    02h
BIT2:                           equ    04h
BIT3:                           equ    08h
BIT4:                           equ    10h
BIT5:                           equ    20h
BIT6:                           equ    40h
BIT7:                           equ    80h

;
; Interface Constants - they need to be redefined for a new hardware platform
;
DUAL_DSP_DATA:                  equ    20h      ; top of data stack 
                                                ; (for PUSH/POP instructions)
LEFT_BUTTON_PORT:               equ    PORT0
LEFT_BUTTON_MASK:               equ    BIT7

RIGHT_BUTTON_PORT:              equ    PORT1
RIGHT_BUTTON_MASK:              equ    BIT0

MIDDLE_BUTTON_PORT:             equ    PORT1
MIDDLE_BUTTON_MASK:             equ    BIT1

OPTICS_PORT:                    equ    PORT0

X_LEFT_OPTICS_PORT:             equ    PORT0
X_LEFT_OPTICS_MASK:             equ    BIT0
X_RIGHT_OPTICS_PORT:            equ    PORT0
X_RIGHT_OPTICS_MASK:            equ    BIT1

Y_LEFT_OPTICS_PORT:             equ    PORT0
Y_LEFT_OPTICS_MASK:             equ    BIT2
Y_RIGHT_OPTICS_PORT:            equ    PORT0
Y_RIGHT_OPTICS_MASK:            equ    BIT3

Z_UP_OPTICS_PORT:               equ    PORT0
Z_UP_OPTICS_MASK:               equ    BIT4
Z_DOWN_OPTICS_PORT:             equ    PORT0
Z_DOWN_OPTICS_MASK:             equ    BIT5

LED_PORT:                       equ    PORT0
LED_MASK:                       equ    BIT6
    ;
    ; Normal operating mode - configure buttons as resistive/CMOS
    ; LED as medium sink/CMOS and optics (x,y,z) as HI-Z/CMOS
    ;
PORT0_NORMAL:                   equ    80h
PORT0_MODE1_NORMAL:             equ    80h
PORT0_MODE0_NORMAL:             equ    40h

PORT1_NORMAL:                   equ    03h
PORT1_MODE1_NORMAL:             equ    03h
PORT1_MODE0_NORMAL:             equ    00h

    ;
    ; Suspend operating mode (no wake up) - configure buttons as 
    ; medium sink/CMOS, LED as resistive/CMOS and 
    ; optics (x,y,z) as HI-Z/CMOS
    ;
PORT0_SUSPEND:                  equ    40h
PORT0_MODE1_SUSPEND:            equ    40h
PORT0_MODE0_SUSPEND:            equ    80h

PORT1_SUSPEND:                  equ    00h
PORT1_MODE1_SUSPEND:            equ    00h
PORT1_MODE0_SUSPEND:            equ    03h

    ;
    ; Suspend with remote wake-up - configure buttons as resistive/CMOS
    ; LED as resistive/CMOS and optics (x,y,z) as HI-Z/CMOS
    ;
PORT0_SUSRW:                    equ    0C0h
PORT0_MODE1_SUSRW:              equ    0C0h
PORT0_MODE0_SUSRW:              equ    00h

PORT1_SUSRW:                    equ    03h
PORT1_MODE1_SUSRW:              equ    03h
PORT1_MODE0_SUSRW:              equ    00h

BUTTON_DEBOUNCE:                equ    15       ; 15ms debouce time
MOUSE_PACKET_4:                 equ    4        ; 4-byte mouse packet
MOUSE_PACKET_3:                 equ    3        ; 3-byte mouse packet

;
; Button State Machine
;
NO_BUTTON_DATA_PENDING:         equ    00h
BUTTON_DATA_PENDING:            equ    02h       ; state defined any time
                                                 ; we read a button
;
; Optics State Machine
;
NO_OPTIC_DATA_PENDING:          equ    00h
OPTIC_DATA_PENDING:             equ    02h       ; state defined any time
                                                 ; we read the optics
;
; Event State Machine
;
NO_EVENT_PENDING:               equ    00h
EVENT_PENDING:                  equ    02h       ; state defined any time 
                                                 ; we have mouse packet to
                                                 ; be sent back to host
;
; Transaction Types
;
TRANS_NONE:                     equ    00h
TRANS_CONTROL_READ:             equ    02h
TRANS_CONTROL_WRITE:            equ    04h
TRANS_NO_DATA_CONTROL:          equ    06h

;
; Optics &amp; Button Variables
;
debounceCount:                  equ    20h      ; debounce counters for buttons
currentButtonState:             equ    21h      ; current button status 
lastButtonState:                equ    22h      ; last read value of buttons

opticStatus:                    equ    23h      ; current optic status
xCount:                         equ    24h      ; current optics x state
yCount:                         equ    25h      ; current optics y state
zCount:                         equ    26h      ; current wheel button state
                            
buttonMachine:                  equ    27h      ; buttons/optics state machine
eventMachine:                   equ    28h      ; state machine for sending data back to host
vertMachine:                    equ    29h      ; y-axis state machine
horzMachine:                    equ    2Ah      ; x-axis state machine
zMachine:                       equ    2Bh      ; z-axis (wheel) state machine

lastVertState:                  equ    2Ch      ; last read y-axis optics
lastHorzState:                  equ    2Dh      ; last read x-axis optics
lastZstate:                     equ    2Eh      ; last read z-axis optics
                                                ; (wheel)

temp:                           equ    2Fh      ; temporary register
buttonValue:                    equ    30h
buttonTemp:                     equ    31h

;
; Dual Interface Variables
;
                                          
dualInterfaceMouse:             equ    32h      ; mouse type
delayCounter:                   equ    33h      ; delay counter
dualInterface1ms:               equ    34h      ; 1ms counter

;
; USB Variables
;
suspendCount:                   equ    35h      ; usb suspend counter
ep1DataToggle:                  equ    36h      ; endpoint 1 data toggle
ep0DataToggle:                  equ    37h      ; endpoint 0 data toggle
dataStart:                      equ    38h      ; ROM table address, start of data
dataCount:                      equ    39h      ; data count to return to host
maximumDataCount:               equ    3Ah      ; maximum size of data to return to host
ep0InMachine:                   equ    3Bh      ; endpoint 0 IN state machine
ep0InFlag:                      equ    3Ch      ; endpoint 0 flag for no-data control
configuration:                  equ    3Dh      ; configured/not configured state
remoteWakeup:                   equ    3Eh      ; remote wakeup on/off
ep1Stall:                       equ    3Fh      ; endpoint 1 stall on/off
idle:                           equ    40h      ; HID idle timer
intTemp:                        equ    41h      ; interrupt routine temp variable
idleTimer:                      equ    42h      ; HID idle timer
idlePrescaler:                  equ    43h      ; HID idle prescale (4ms)
ep0Transtype:                   equ    44h      ; Endpoint 0 transaction type
pendingData:                    equ    45h      ; data pending during no-data control
protocol:                       equ    46h      ; mouse protocol boot/report

;
; PS2 Variables - written on top of USB variables
;
ps2Temp0:                       equ    35h

ps2LastValidCmd:                equ    36h
ps2InvalidCmdCount:             equ    37h
ps2ReportRate:                  equ    38h
ps2ReportInterval:              equ    39h
ps2Scale:                       equ    3Ah
ps2StreamMode:                  equ    3Bh
ps2Resolution:                  equ    3Ch
ps2MouseEnabled:                equ    3Dh
ps2Wheel:                       equ    3Eh
ps2WrapMode:                    equ    3Fh

ps2IntervalCount:               equ    40h       ; send back a mouse packet
                                                 ; when this interval expires
sequence:                       equ    41h
saveCmd:                        equ    42h
ps2XmitBuffer:                  equ    43h
ps2XmitBuffer0:                 equ    ps2XmitBuffer+0
ps2XmitBuffer1:                 equ    ps2XmitBuffer+1
ps2XmitBuffer2:                 equ    ps2XmitBuffer+2
ps2XmitBuffer3:                 equ    ps2XmitBuffer+3

ps2XmitBufferLen:               equ    ps2XmitBuffer+4    ; total bytes to send
ps2XmitLen:                     equ    ps2XmitBuffer+5    ; remaining bytes to send


;********************************************************************
;
; Interrupt Vector Table
;
;********************************************************************
    ORG 00h            

jmp    dualMain                         ; power up        
jmp    dualUsbBusReset_ps2Error         ; USB reset / error
jmp    errorHandler                     ; 128us interrupt
jmp    dual1msTimer                     ; 1.024ms interrupt
jmp    dualUsbEndpoint0_ps2Error        ; Endpoint 0 interrupt / error
jmp    dualUsbEndpoint1_ps2Error        ; Endpoint 1 interrupt / error
jmp    errorHandler                     ; Endpoint 2 interrupt
jmp    errorHandler                     ; Reserved
jmp    errorHandler                     ; Capture timer A interrupt Vector
jmp    errorHandler                     ; Capture timer B interrupt Vector
jmp    errorHandler                     ; GPIO interrupt vector
jmp    dualUsbWakeup_ps2Error           ; Wake-up interrupt / error


;********************************************************************
; Error Handler
;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
精品一区二区三区在线播放视频| 中文字幕中文字幕在线一区| 午夜久久福利影院| 欧美日韩一级片在线观看| 亚洲成人免费在线观看| 欧美精品第一页| 精品一区二区三区影院在线午夜| 日韩你懂的电影在线观看| 黑人精品欧美一区二区蜜桃 | 国产精品久久久久久久久免费桃花 | 国产偷国产偷亚洲高清人白洁| 国产一区999| 国产精品高潮久久久久无| 91蜜桃视频在线| 日韩福利电影在线| 久久久久高清精品| 色悠久久久久综合欧美99| 日韩成人一区二区三区在线观看| 精品人在线二区三区| av成人免费在线观看| 亚洲成人免费观看| 国产亚洲一区二区三区| 91国产丝袜在线播放| 精品系列免费在线观看| 亚洲人成精品久久久久| 欧美一级精品在线| 91在线小视频| 久草热8精品视频在线观看| 国产精品视频在线看| 欧美日韩激情在线| 成人一级片网址| 日韩不卡一区二区| 亚洲视频免费观看| 精品久久久久久最新网址| 99视频在线观看一区三区| 欧美aⅴ一区二区三区视频| 中文字幕一区二区三区蜜月| 91精品久久久久久久久99蜜臂| 成人动漫av在线| 免费成人在线网站| 一区二区三区精品| 久久久美女毛片| 欧美一区二区三区在线看| 91麻豆文化传媒在线观看| 精品一区二区三区免费毛片爱| 亚洲精品国产无天堂网2021| 久久九九99视频| 欧美一卡2卡3卡4卡| 欧美午夜精品久久久久久超碰| 国产91综合一区在线观看| 天堂蜜桃一区二区三区| 有码一区二区三区| 国产精品每日更新| 国产午夜一区二区三区| 欧美xxx久久| 欧美一激情一区二区三区| 精品视频一区三区九区| www.亚洲免费av| 国产成人免费9x9x人网站视频| 免费成人小视频| 日韩av午夜在线观看| 国产精品第四页| 中文字幕精品一区| 久久久精品影视| 2017欧美狠狠色| 精品国产乱码久久久久久浪潮| 欧美一级欧美三级| 日韩午夜av电影| 欧美一区二区三区在线电影| 欧美久久久久久久久中文字幕| 欧洲在线/亚洲| 欧美视频一二三区| 精品1区2区3区| 欧美日韩一级大片网址| 欧美视频一区二区三区四区| 欧美性受极品xxxx喷水| 欧美午夜一区二区三区免费大片| 欧美性受xxxx黑人xyx| 精品视频在线看| 欧美一区二区三区日韩| 欧美videos大乳护士334| 精品国产乱码91久久久久久网站| 久久久亚洲精品一区二区三区| 欧美精品一区二区久久久| 国产女同性恋一区二区| 国产精品国产成人国产三级| 亚洲人吸女人奶水| 亚洲va在线va天堂| 另类调教123区| 国产精品亚洲а∨天堂免在线| 丁香婷婷综合五月| 91在线porny国产在线看| 欧美三级视频在线播放| 91精品国产欧美一区二区| 精品人伦一区二区色婷婷| 国产欧美日韩在线| 亚洲人成7777| 日韩1区2区3区| 国产精品一区二区x88av| 99精品一区二区三区| 欧美日韩国产精选| 久久久久久久久免费| 亚洲欧美日韩在线不卡| 青青草原综合久久大伊人精品优势| 久久电影国产免费久久电影| 不卡电影一区二区三区| 欧美日韩国产成人在线91| 久久看人人爽人人| 亚洲精品视频在线| 麻豆传媒一区二区三区| 成人av电影观看| 欧美精品久久一区二区三区| 久久久99精品免费观看不卡| 亚洲狼人国产精品| 免费成人结看片| 91视频com| 久久综合九色综合97婷婷女人| 亚洲色图在线看| 久久精品国产一区二区三| 99精品国产热久久91蜜凸| 欧美一级片在线| 有坂深雪av一区二区精品| 精品在线免费观看| 91精品91久久久中77777| 久久亚区不卡日本| 亚洲大片在线观看| 成人精品gif动图一区| 91精品国产黑色紧身裤美女| 中文字幕一区二区三区四区不卡| 日韩电影在线观看电影| 91亚洲精品久久久蜜桃| 精品入口麻豆88视频| 亚洲一级电影视频| 成人黄色在线网站| 日韩一区二区免费视频| 一区二区三区成人| 99久久国产综合精品女不卡| 精品国产123| 爽好久久久欧美精品| 色综合久久88色综合天天 | 4438x亚洲最大成人网| 中文字幕日韩一区| 国产精品亚洲午夜一区二区三区| 日韩限制级电影在线观看| 亚洲综合偷拍欧美一区色| 99视频精品在线| 国产三级久久久| 国产一区二区在线看| 欧美高清激情brazzers| 一区二区理论电影在线观看| av资源网一区| 中文字幕不卡一区| 国产麻豆成人传媒免费观看| 欧美一级日韩不卡播放免费| 图片区小说区国产精品视频| 色婷婷国产精品| 亚洲精品乱码久久久久| www.亚洲人| 亚洲日穴在线视频| 91在线精品秘密一区二区| 国产精品二三区| 成人精品免费视频| 国产精品久久久久三级| 不卡一二三区首页| 中文字幕一区二区不卡| 成人av综合一区| 亚洲天堂福利av| 色拍拍在线精品视频8848| 悠悠色在线精品| 欧美日韩在线精品一区二区三区激情| 亚洲综合自拍偷拍| 欧美日本一区二区在线观看| 五月婷婷综合激情| 日韩视频在线永久播放| 久久精品72免费观看| 精品日韩成人av| 国产99久久久久久免费看农村| 国产女同性恋一区二区| 91片黄在线观看| 亚洲影院在线观看| 777xxx欧美| 国产一区二区免费视频| 国产精品伦一区| 色婷婷亚洲精品| 日韩激情在线观看| 久久久精品综合| 91社区在线播放| 人妖欧美一区二区| 国产日韩欧美电影| 91国在线观看| 久久精品国产一区二区三| 国产欧美一区二区精品久导航| 色综合天天综合网国产成人综合天 | 亚洲3atv精品一区二区三区| 91精品国产综合久久久久久久久久| 日韩avvvv在线播放| 国产视频一区在线观看| 91一区一区三区| 九九精品视频在线看| 专区另类欧美日韩|