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

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

?? descript.asm

?? This example implements a gameport translator on the PIC16C765. The firmware translates a gaming d
?? ASM
?? 第 1 頁 / 共 2 頁
字號:
;                            Software License Agreement
;
; The software supplied herewith by Microchip Technology Incorporated (the "Company")
; for its PICmicro(r) Microcontroller is intended and supplied to you, the Company's
; customer, for use solely and exclusively on Microchip PICmicro Microcontroller
; products.
;
; The software is owned by the Company and/or its supplier, and is protected under
; applicable copyright laws. All rights are reserved. Any use in violation of the
; foregoing restrictions may subject the user to criminal sanctions under applicable
; laws, as well as to civil liability for the breach of the terms and conditions of
; this license.
;
; THIS SOFTWARE IS PROVIDED IN AN "AS IS" CONDITION. NO WARRANTIES, WHETHER EXPRESS,
; IMPLIED OR STATUTORY, INCLUDING, BUT NOT LIMITED TO, IMPLIED WARRANTIES OF
; MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE APPLY TO THIS SOFTWARE. THE
; COMPANY SHALL NOT, IN ANY CIRCUMSTANCES, BE LIABLE FOR SPECIAL, INCIDENTAL OR
; CONSEQUENTIAL DAMAGES, FOR ANY REASON WHATSOEVER.
;
; ###############################################################################
;   filename:           DESCRIPT.ASM
;
; This file contains a set of descriptors for a gamepad.  
;
; ###############################################################################
;
;   Author:             Dan Butler and Reston Condit
;   Company:            Microchip Technology Inc
;
;   Revision:           1.21
;   Date:               08 August 2001
;   Assembled using     MPASM 2.61
;   Revision History:
;   23 August 2000      DZB Changed descriptor pointers to 16 bits.
;   24 August 2000      DZB Moved EP1 & 2 configuration from USBReset
;                           to Set_Configuration to implement requirement in
;                           USB V1.1 spec paragraph 5.3.1.2
;   28 August 2000      DZB Force data toggle on OUT packets in PutUSB
;   20 March 2001       DZB Reduced use of common RAM
;   20 March 2001       DZB Put and Get use their own temp variable (GPtemp) to
;                           avoid collisions with the ISR's use of temp.
;   29 March 2001       DZB Fixed saving of bank bits in GetUSB
;   02 May 2001         DZB Implemented SHOW_ENUM_STATUS to show enumeration
;                           status on the PORTB LEDs: 0- Powered, 1- Default,
;                           2- addressed, 3- configured, 4- sleep, 
;                           5- EP0 Activity, 6- EP1 Activity, 7- EP2 Activity
;   03 August 2001      RAC Made distinct GetEP and PutEP macros for endpoints 1 
;                           and 2.  These functions are GetEP1, GetEP2, PutEP1, and 
;                           PutEP2.  Instances of the these macros are created in
;                           usb_ch9.asm.
;   08 August 2001      RAC Corrected various banking and paging issues.
;   15 August           RAC Added Report_desc_index function in descript.asm.
;                           This function allows more than one report descriptor
;                           to be used.  
;
;################################################################################
;
;   include files:
;       P16C765.inc     Rev 1.00
;       usb_defs.inc    Rev 1.00
;
;################################################################################
#include <p16C765.inc>
#include "usb_defs.inc"

USBBANK code
    global  Config_desc_index
    global  Report_desc_index
    global  Descriptions
    global  string_index
    global  DeviceDescriptor
    global  ReportDescriptor
    global  ReportDescriptorLen
    global  String0
    global  String0_end
    global  StringDescriptions
    global  HID_Descriptor

    extern  EP0_start
    extern  temp    ; temp var used in get config index
    extern  temp2   ; another temp, in bank2 

; ******************************************************************
; Given a configuration descriptor index, returns the beginning address
; of the descriptor within the descriptions table
; ******************************************************************
Config_desc_index
    movwf   temp
    movlw   HIGH CDI_start
    movwf   PCLATH
    movlw   low  CDI_start
    addwf   temp,w
    btfsc   STATUS,C
    incf    PCLATH,f
    movwf   PCL
CDI_start           ; this table calculates the offsets for each configuration
    retlw   low  Config1       ; descriptor from the beginning
    retlw   high Config1       ; of the table, effectively
    ; more configurations can be added here
    ; retlw   low Config2
    ; retlw   high Config2
    ; etc....

; ******************************************************************
; Given a report descriptor index, returns the beginning address
; of the descriptor within the descriptions table
; ******************************************************************
Report_desc_index
    movwf   temp
    movlw   HIGH RDI_start
    movwf   PCLATH
    movlw   low  RDI_start
    addwf   temp,w
    btfsc   STATUS,C
    incf    PCLATH,f
    movwf   PCL
RDI_start       ; this table calculates the offsets for each report
    retlw   low  ReportDescriptorLen  ; descriptor from the beginning
    retlw   high ReportDescriptorLen  ; of the table, effectively
    ; more reports can be added here
    ; retlw   low  ReportDescriptorLen2
    ; retlw   high ReportDescriptorLen2
    ; etc....

; ******************************************************************
; This table is polled by the host immediately after USB Reset has been released.
; This table defines the maximum packet size EP0 can take.
; See section 9.6.1 of the Rev 1.0 USB specification.
; These fields are application DEPENDENT. Modify these to meet
; your specifications.
; the offset is passed in P0 and P1 (P0 is low order byte).
; ******************************************************************
Descriptions
    banksel EP0_start
    movf    EP0_start+1,w
    movwf   PCLATH
    movf    EP0_start,w
    movwf   PCL

DeviceDescriptor
StartDevDescr
	retlw	0x12    ; bLength	Length of this descriptor
	retlw	0x01    ; bDescType This is a DEVICE descriptor
	retlw	0x00  	; bcdUSB	USB revision 1.10 (low byte)
	retlw	0x01    ; high byte
	retlw	0x00    ; bDeviceClass	zero means each interface operates independently
	retlw	0x00    ; bDeviceSubClass
	retlw	0x00    ; bDeviceProtocol
	retlw	0x08	; bMaxPacketSize0 - inited in UsbInit()
	retlw	0xD8	; idVendor	0x04D8 is Microchip Vendor ID
	retlw	0x04	; high order byte
	retlw	0x03	; idProduct
	retlw	0x00
	retlw	0x00	; bcdDevice
	retlw	0x00
	retlw	0x01	; iManufacturer
	retlw	0x02	; iProduct
	; somehow, changing iSerialNumber will cause windows to display
	; "New Hardware found" dialog. The device will function normally,
	; however, USBCheck will NOT start. From CATC we can see that
	; the string is correctly transmitted.
	retlw	0;0x0	; iSerialNumber - 3
	retlw	NUM_CONFIGURATIONS	; bNumConfigurations

; ******************************************************************
; This table is retrieved by the host after the address has been set.
; This table defines the configurations available for the device.
; See section 9.6.2 of the Rev 1.0 USB specification (page 184).
; These fields are application DEPENDENT. 
; Modify these to meet your specifications.
; ******************************************************************
Config1
	retlw	0x09	; bLength	Length of this descriptor
	retlw	0x02	; bDescType	2=CONFIGURATION

	retlw	EndConfig1 - Config1
	retlw	0x00   
	retlw	0x01   	; bNumInterfaces	Number of interfaces

	retlw	0x01   	; bConfigValue	Configuration Value
	retlw	0x04   	; iConfig	String Index for this config = #01
	retlw	0x80	; bmAttributes	attributes - bus powered
	retlw	0x32	; MaxPower	self-powered draws 0 mA from the bus.
Interface1
	retlw	0x09	; length of descriptor
	retlw	INTERFACE;
	retlw	0x00	; number of interface, 0 based array
	retlw	0x00	; alternate setting
	retlw	0x01	; number of endpoints used in this interface
	retlw	0x03	; interface class - assigned by the USB
	retlw	0x00	; boot device
	retlw	0x00	; interface protocol
	retlw 	0x05    ; index to string descriptor that describes this interface
HID_Descriptor
    retlw	0x09    ; descriptor size (9 bytes)
    retlw	0x21    ; descriptor type (HID)
    retlw	0x00
	retlw	0x01    ; HID class release number (1.00)
    retlw	0x00    ; Localized country code (none)
    retlw	0x01    ; # of HID class descriptor to follow (1)
    retlw	0x22    ; Report descriptor type (HID)
    retlw	(end_ReportDescriptor - ReportDescriptor)
    retlw	0x00
Endpoint1
	retlw	0x07    ; length of descriptor
	retlw	ENDPOINT
	retlw	0x81	; EP1, In
	retlw	0x03   	; Interrupt
	retlw	0x03	; max packet size (3 bytes) low order byte
	retlw	0x00	; max packet size (3 bytes) high order byte
	retlw	0x0A	; polling interval (10ms)
EndConfig1

ReportDescriptorLen
	retlw	low  (end_ReportDescriptor-ReportDescriptor)

ReportDescriptor
    retlw	0x05
	retlw	0x01                ; USAGE_PAGE (Generic Desktop)
    retlw	0x09
	retlw	0x05                ; USAGE (Game Pad)
    retlw	0xa1
	retlw	0x01                ; COLLECTION (Application)
    retlw	0x09
	retlw	0x01                ;   USAGE (Pointer)
    retlw	0xa1
    retlw	0x00                ;   COLLECTION (Physical)
    retlw	0x09
	retlw	0x30                ;     USAGE (X)
    retlw	0x09
	retlw	0x31                ;     USAGE (Y)
    retlw	0x15
	retlw	0x00                ;     LOGICAL_MINIMUM (0)
    retlw	0x26
	retlw	0xFF                ;     LOGICAL_MAXIMUM (255)
    retlw   0x00
    retlw   0x75
	retlw	0x08                ;     REPORT_SIZE (8)	
    retlw	0x95
	retlw	0x02                ;     REPORT_COUNT (2)
    retlw	0x81
	retlw	0x02                ;     INPUT (Data,Var,Abs)
    retlw	0xc0                ;   END_COLLECTION
    retlw	0x05
	retlw	0x09                ;   USAGE_PAGE (Button)
    retlw	0x19
	retlw	0x01                ;   USAGE_MINIMUM (Button 1)
    retlw	0x29
	retlw	0x06                ;   USAGE_MAXIMUM (Button 6)
    retlw	0x15
	retlw	0x00                ;   LOGICAL_MINIMUM (0)
    retlw	0x25
	retlw	0x01                ;   LOGICAL_MAXIMUM (1)
    retlw	0x75
	retlw	0x01                ;   REPORT_SIZE (1)
    retlw	0x95
	retlw	0x06                ;   REPORT_COUNT (6)
    retlw	0x81
	retlw	0x02                ;   INPUT (Data,Var,Abs)
    retlw	0x95
	retlw	0x02                ;   REPORT_COUNT (2)
    retlw	0x81
	retlw	0x03                ;   INPUT (Constant,Var,Abs)
    retlw	0xc0                ; END_COLLECTION
end_ReportDescriptor

StringDescriptions
	banksel	EP0_start
	movf	EP0_start+1,w
	movwf	PCLATH
	movf	EP0_start,w
	movwf	PCL

; ******************************************************************
; Given a configuration descriptor index, returns the beginning address
; of the descriptor within the descriptions table
; ******************************************************************
string_index		; langid in W reg, string offset in EP0_start
	movwf	temp
	bcf	    STATUS,C
	rlf	    temp, f

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
91福利国产精品| 一本色道久久综合狠狠躁的推荐 | 亚洲自拍偷拍图区| 国产精品免费网站在线观看| 亚洲视频一区二区在线观看| 国产亚洲欧美在线| 久久精子c满五个校花| 久久无码av三级| 国产色一区二区| 国产精品伦理一区二区| 国产精品视频一二三| 中文字幕一区二区在线播放 | 成人免费三级在线| 成人免费视频视频| 色视频成人在线观看免| 欧美午夜一区二区| 欧美一区二区二区| 久久亚洲精精品中文字幕早川悠里| 精品欧美乱码久久久久久1区2区| 亚洲精品一区二区三区精华液 | 色综合久久久久网| 在线观看一区二区视频| 91麻豆精品久久久久蜜臀| 日韩欧美的一区| 国产色一区二区| 一区二区三区四区激情| 天天色综合天天| 国产黄色91视频| 色8久久精品久久久久久蜜 | 蜜桃视频在线观看一区二区| 国产一区二区毛片| av电影在线不卡| 欧美日韩精品一区二区| 久久久综合视频| 一区二区三区中文字幕| 另类小说图片综合网| 99国产精品久久久久久久久久久| 欧美主播一区二区三区| 久久久久久久久久久久久女国产乱| 中文字幕中文字幕一区| 美女视频一区在线观看| 色香蕉成人二区免费| 日韩女优电影在线观看| 一区二区三区不卡视频在线观看 | 国产乱一区二区| 在线一区二区观看| 国产视频一区二区三区在线观看| 亚洲午夜久久久久久久久电影网 | 中文乱码免费一区二区| 日韩福利视频导航| 99热99精品| 久久日韩精品一区二区五区| 亚洲影院免费观看| 国产**成人网毛片九色| 日韩欧美在线1卡| 亚洲一线二线三线久久久| 国产精品538一区二区在线| 69久久夜色精品国产69蝌蚪网| 国产日产欧美一区二区视频| 日韩**一区毛片| 在线观看亚洲精品| 韩国精品一区二区| 91精品国产高清一区二区三区| 日韩毛片一二三区| 99精品欧美一区| 国产日韩精品视频一区| 国产精品一二二区| 久久日韩精品一区二区五区| 免费成人你懂的| 在线成人午夜影院| 调教+趴+乳夹+国产+精品| 91成人在线精品| 亚洲理论在线观看| 91蜜桃免费观看视频| 亚洲欧洲精品一区二区三区| 成人在线综合网| 国产精品乱码人人做人人爱| 国产成人午夜精品5599| 国产欧美精品一区二区色综合| 美女一区二区视频| 精品国产乱码久久久久久蜜臀| 强制捆绑调教一区二区| 日韩欧美三级在线| 国产美女视频一区| 欧美激情中文字幕| 99久久99久久精品免费看蜜桃| 国产精品理伦片| 在线一区二区视频| 日韩中文欧美在线| 日韩精品在线一区| 国产91丝袜在线播放0| 亚洲欧洲日产国码二区| 91国偷自产一区二区三区成为亚洲经典| 亚洲精品成人悠悠色影视| 色天天综合久久久久综合片| 亚洲成人免费在线| 日韩欧美一级特黄在线播放| 国产高清亚洲一区| 亚洲精品日韩一| 在线不卡中文字幕播放| 韩日精品视频一区| 国产精品二区一区二区aⅴ污介绍| 色香蕉成人二区免费| 粉嫩aⅴ一区二区三区四区五区| 精品国产乱码久久久久久1区2区| 激情图片小说一区| **欧美大码日韩| 欧美群妇大交群的观看方式| 久久国产精品露脸对白| 国产精品日产欧美久久久久| 精品视频一区 二区 三区| 国产一区二区三区免费在线观看 | 日韩欧美国产综合在线一区二区三区| 欧美色图片你懂的| 九色综合狠狠综合久久| 最新国产精品久久精品| 日韩欧美亚洲国产另类| 97久久精品人人做人人爽50路| 天堂成人免费av电影一区| 欧美韩国日本一区| 宅男在线国产精品| 91麻豆免费在线观看| 青青草一区二区三区| 综合色中文字幕| 久久先锋影音av| 91精品久久久久久久99蜜桃| 成人av免费网站| 经典三级视频一区| 亚洲二区视频在线| 亚洲日本中文字幕区| 精品乱码亚洲一区二区不卡| 91久久国产综合久久| 国产成人午夜精品影院观看视频| 无码av中文一区二区三区桃花岛| 国产精品欧美久久久久无广告| 日韩一级欧美一级| 欧美日韩国产一级| 色一区在线观看| 成人精品国产免费网站| 国内精品久久久久影院一蜜桃| 天天射综合影视| 亚洲午夜精品一区二区三区他趣| 国产精品久久网站| 久久精品夜色噜噜亚洲aⅴ| 日韩久久久久久| 欧美一级黄色录像| 欧美一卡二卡在线| 666欧美在线视频| 9191久久久久久久久久久| 色一情一乱一乱一91av| 色爱区综合激月婷婷| 色天天综合色天天久久| 91黄色激情网站| 91国产精品成人| 欧美另类变人与禽xxxxx| 欧美揉bbbbb揉bbbbb| 欧美日本韩国一区| 51午夜精品国产| 日韩写真欧美这视频| 日韩三区在线观看| 欧美精品一区男女天堂| 久久综合网色—综合色88| 久久婷婷国产综合精品青草| 久久久久88色偷偷免费| 国产精品污www在线观看| 国产精品污www在线观看| 亚洲视频电影在线| 亚洲国产欧美日韩另类综合 | 中文一区一区三区高中清不卡| 精品播放一区二区| 中文字幕不卡的av| 亚洲精品视频一区二区| 日韩精品每日更新| 久久99精品视频| 成人在线综合网| 在线精品视频一区二区三四| 欧美精品一卡二卡| www日韩大片| 亚洲人成小说网站色在线| 亚洲资源在线观看| 精品一区二区三区久久| 成人av在线资源网| 欧美在线观看一区二区| 精品国产123| 亚洲日本电影在线| 免费美女久久99| 成人avav在线| 91麻豆精品国产91久久久久| 精品久久久久久综合日本欧美| 亚洲国产精品成人综合| 亚洲国产三级在线| 国产精品18久久久久久久网站| 91久久精品一区二区三| 欧美不卡在线视频| 亚洲精品大片www| 国产一区999| 精品视频一区二区不卡| 日本一区二区成人在线| 免费成人美女在线观看.| 99久久精品99国产精品|