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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? cciddriver.c

?? IAR5.2下 AT91SAM9260 ARM 對 MCP2515 控制源化碼
?? C
?? 第 1 頁 / 共 2 頁
字號:
    0x00,                                  // Subclass is specified in interface
    0x00,                                  // Protocol is specified in interface
    BOARD_USB_ENDPOINTS_MAXPACKETSIZE(0),    
    0x01,                                  // One possible configuration
    0x00                                   // Reserved for future use, must be zero
};

static const CCIDDriverConfigurationDescriptors sOtherSpeedConfigurationFS = {

    // Standard USB configuration descriptor
    {
        sizeof(USBConfigurationDescriptor),
        USBGenericDescriptor_OTHERSPEEDCONFIGURATION,
        sizeof(CCIDDriverConfigurationDescriptors),
        1, // One interface in this configuration
        1, // This is configuration #1
        0, // No associated string descriptor
        BOARD_USB_BMATTRIBUTES,
        USBConfigurationDescriptor_POWER(100)
    },
    // CCID interface descriptor
    // Table 4.3-1 Interface Descriptor
    // Interface descriptor
    {
        sizeof(USBInterfaceDescriptor),
        USBGenericDescriptor_INTERFACE,
        0,                       // Interface 0
        0,                       // No alternate settings
        3,                       // uses bulk-IN, bulk-OUT and interrupt朓N
        SMART_CARD_DEVICE_CLASS,
        0,                       // Subclass code
        0,                       // bulk transfers optional interrupt-IN
        0                        // No associated string descriptor
    },
    {
        sizeof(CCIDDescriptor), // bLength: Size of this descriptor in bytes
        CCID_DECRIPTOR_TYPE,    // bDescriptorType:Functional descriptor type
        CCID1_10,               // bcdCCID: CCID version
        0,               // bMaxSlotIndex: Value 0 indicates that one slot is supported
        VOLTS_5_0,       // bVoltageSupport
        PROTOCOL_TO,     // dwProtocols
        3580,            // dwDefaultClock
        3580,            // dwMaxClock
        0,               // bNumClockSupported
        9600,            // dwDataRate : 9600 bauds
        9600,            // dwMaxDataRate : 9600 bauds
        0,               // bNumDataRatesSupported
        0xfe,            // dwMaxIFSD
        0,               // dwSynchProtocols
        0,               // dwMechanical
        //0x00010042,      // dwFeatures: Short APDU level exchanges
        CCID_FEATURES_AUTO_PCONF | CCID_FEATURES_AUTO_PNEGO | CCID_FEATURES_EXC_TPDU,
        0x0000010F,      // dwMaxCCIDMessageLength: For extended APDU level the value shall be between 261 + 10
        0xFF,            // bClassGetResponse: Echoes the class of the APDU
        0xFF,            // bClassEnvelope: Echoes the class of the APDU
        0,               // wLcdLayout: no LCD
        0,               // bPINSupport: No PIN
        1                // bMaxCCIDBusySlot
    },
    // Bulk-OUT endpoint descriptor
    {
        sizeof(USBEndpointDescriptor),
        USBGenericDescriptor_ENDPOINT,
        USBEndpointDescriptor_ADDRESS( USBEndpointDescriptor_OUT, CCID_EPT_DATA_OUT ),
        USBEndpointDescriptor_BULK,
        MIN(BOARD_USB_ENDPOINTS_MAXPACKETSIZE(CCID_EPT_DATA_OUT),
            USBEndpointDescriptor_MAXBULKSIZE_FS),
        0x00                               // Does not apply to Bulk endpoints
    },
    // Bulk-IN endpoint descriptor
    {
        sizeof(USBEndpointDescriptor),
        USBGenericDescriptor_ENDPOINT,
        USBEndpointDescriptor_ADDRESS( USBEndpointDescriptor_IN, CCID_EPT_DATA_IN ),
        USBEndpointDescriptor_BULK,
        MIN(BOARD_USB_ENDPOINTS_MAXPACKETSIZE(CCID_EPT_DATA_IN),
            USBEndpointDescriptor_MAXBULKSIZE_FS),
        0x00                               // Does not apply to Bulk endpoints
    },
    // Notification endpoint descriptor
    {
        sizeof(USBEndpointDescriptor),
        USBGenericDescriptor_ENDPOINT,
        USBEndpointDescriptor_ADDRESS( USBEndpointDescriptor_IN, CCID_EPT_NOTIFICATION ),
        USBEndpointDescriptor_INTERRUPT,
        MIN(BOARD_USB_ENDPOINTS_MAXPACKETSIZE(CCID_EPT_NOTIFICATION),
            USBEndpointDescriptor_MAXINTERRUPTSIZE_FS),
        0x10                              
    }
};

static const CCIDDriverConfigurationDescriptors sOtherSpeedConfigurationHS = {

    // Standard USB configuration descriptor
    {
        sizeof(USBConfigurationDescriptor),
        USBGenericDescriptor_OTHERSPEEDCONFIGURATION,
        sizeof(CCIDDriverConfigurationDescriptors),
        1, // One interface in this configuration
        1, // This is configuration #1
        0, // No associated string descriptor
        BOARD_USB_BMATTRIBUTES,
        USBConfigurationDescriptor_POWER(100)
    },
    // CCID interface descriptor
    // Table 4.3-1 Interface Descriptor
    // Interface descriptor
    {
        sizeof(USBInterfaceDescriptor),
        USBGenericDescriptor_INTERFACE,
        0,                       // Interface 0
        0,                       // No alternate settings
        3,                       // uses bulk-IN, bulk-OUT and interrupt朓N
        SMART_CARD_DEVICE_CLASS,
        0,                       // Subclass code
        0,                       // bulk transfers optional interrupt-IN
        0                        // No associated string descriptor
    },
    {
        sizeof(CCIDDescriptor), // bLength: Size of this descriptor in bytes
        CCID_DECRIPTOR_TYPE,    // bDescriptorType:Functional descriptor type
        CCID1_10,               // bcdCCID: CCID version
        0,               // bMaxSlotIndex: Value 0 indicates that one slot is supported
        VOLTS_5_0,       // bVoltageSupport
        PROTOCOL_TO,     // dwProtocols
        3580,            // dwDefaultClock
        3580,            // dwMaxClock
        0,               // bNumClockSupported
        9600,            // dwDataRate : 9600 bauds
        9600,            // dwMaxDataRate : 9600 bauds
        0,               // bNumDataRatesSupported
        0xfe,            // dwMaxIFSD
        0,               // dwSynchProtocols
        0,               // dwMechanical
        //0x00010042,      // dwFeatures: Short APDU level exchanges
        CCID_FEATURES_AUTO_PCONF | CCID_FEATURES_AUTO_PNEGO | CCID_FEATURES_EXC_TPDU,
        0x0000010F,      // dwMaxCCIDMessageLength: For extended APDU level the value shall be between 261 + 10
        0xFF,            // bClassGetResponse: Echoes the class of the APDU
        0xFF,            // bClassEnvelope: Echoes the class of the APDU
        0,               // wLcdLayout: no LCD
        0,               // bPINSupport: No PIN
        1                // bMaxCCIDBusySlot
    },
    // Bulk-OUT endpoint descriptor
    {
        sizeof(USBEndpointDescriptor),
        USBGenericDescriptor_ENDPOINT,
        USBEndpointDescriptor_ADDRESS( USBEndpointDescriptor_OUT, CCID_EPT_DATA_OUT ),
        USBEndpointDescriptor_BULK,
        MIN(BOARD_USB_ENDPOINTS_MAXPACKETSIZE(CCID_EPT_DATA_OUT),
            USBEndpointDescriptor_MAXBULKSIZE_HS),
        0x00                               // Does not apply to Bulk endpoints
    },
    // Bulk-IN endpoint descriptor
    {
        sizeof(USBEndpointDescriptor),
        USBGenericDescriptor_ENDPOINT,
        USBEndpointDescriptor_ADDRESS( USBEndpointDescriptor_IN, CCID_EPT_DATA_IN ),
        USBEndpointDescriptor_BULK,
        MIN(BOARD_USB_ENDPOINTS_MAXPACKETSIZE(CCID_EPT_DATA_IN),
            USBEndpointDescriptor_MAXBULKSIZE_HS),
        0x00                               // Does not apply to Bulk endpoints
    },
    // Notification endpoint descriptor
    {
        sizeof(USBEndpointDescriptor),
        USBGenericDescriptor_ENDPOINT,
        USBEndpointDescriptor_ADDRESS( USBEndpointDescriptor_IN, CCID_EPT_NOTIFICATION ),
        USBEndpointDescriptor_INTERRUPT,
        MIN(BOARD_USB_ENDPOINTS_MAXPACKETSIZE(CCID_EPT_NOTIFICATION),
            USBEndpointDescriptor_MAXINTERRUPTSIZE_HS),
        0x10                              
    }
};
#endif
//------------------------------------------------------------------------------
//  Variables: String descriptors
//      languageIdDescriptor - Language ID string descriptor.
//      manufacturerDescriptor - Manufacturer name.
//      productDescriptor - Product name.
//      serialNumberDescriptor - Product serial number.
//      stringDescriptors - Array of pointers to string descriptors.
//------------------------------------------------------------------------------
static const unsigned char languageIdDescriptor[] = {

    USBStringDescriptor_LENGTH(1),
    USBGenericDescriptor_STRING,
    USBStringDescriptor_ENGLISH_US
};

static const unsigned char manufacturerDescriptor[] = {

    USBStringDescriptor_LENGTH(5),
    USBGenericDescriptor_STRING,
    USBStringDescriptor_UNICODE('A'),
    USBStringDescriptor_UNICODE('T'),
    USBStringDescriptor_UNICODE('M'),
    USBStringDescriptor_UNICODE('E'),
    USBStringDescriptor_UNICODE('L')
};

static const unsigned char productDescriptor[] = {

    USBStringDescriptor_LENGTH(23),
    USBGenericDescriptor_STRING,
    USBStringDescriptor_UNICODE('A'),
    USBStringDescriptor_UNICODE('T'),
    USBStringDescriptor_UNICODE('M'),
    USBStringDescriptor_UNICODE('E'),
    USBStringDescriptor_UNICODE('L'),
    USBStringDescriptor_UNICODE(' '),
    USBStringDescriptor_UNICODE('A'),
    USBStringDescriptor_UNICODE('T'),
    USBStringDescriptor_UNICODE('9'),
    USBStringDescriptor_UNICODE('1'),
    USBStringDescriptor_UNICODE(' '),
    USBStringDescriptor_UNICODE('C'),
    USBStringDescriptor_UNICODE('C'),
    USBStringDescriptor_UNICODE('I'),
    USBStringDescriptor_UNICODE('D'),
    USBStringDescriptor_UNICODE(' '),
    USBStringDescriptor_UNICODE('D'),
    USBStringDescriptor_UNICODE('R'),
    USBStringDescriptor_UNICODE('I'),
    USBStringDescriptor_UNICODE('V'),
    USBStringDescriptor_UNICODE('E'),
    USBStringDescriptor_UNICODE('R'),
    USBStringDescriptor_UNICODE(' ')
};

static const unsigned char serialNumberDescriptor[] = {

    USBStringDescriptor_LENGTH(12),
    USBGenericDescriptor_STRING,
    USBStringDescriptor_UNICODE('0'),
    USBStringDescriptor_UNICODE('1'),
    USBStringDescriptor_UNICODE('2'),
    USBStringDescriptor_UNICODE('3'),
    USBStringDescriptor_UNICODE('4'),
    USBStringDescriptor_UNICODE('5'),
    USBStringDescriptor_UNICODE('6'),
    USBStringDescriptor_UNICODE('7'),
    USBStringDescriptor_UNICODE('8'),
    USBStringDescriptor_UNICODE('9'),
    USBStringDescriptor_UNICODE('A'),
    USBStringDescriptor_UNICODE('F')
};

static const unsigned char *stringDescriptors[] = {

    languageIdDescriptor,
    manufacturerDescriptor,
    productDescriptor,
    serialNumberDescriptor
};


//------------------------------------------------------------------------------
//  Variable: ccidDriverDescriptors
//      List of standard descriptors for the serial driver.
//------------------------------------------------------------------------------
const USBDDriverDescriptors ccidDriverDescriptors = {

    &deviceDescriptor, // FS
    (USBConfigurationDescriptor *) &configurationDescriptorsFS,
#ifdef BOARD_USB_UDPHS
    (USBDeviceQualifierDescriptor *) &deviceQualifierDescriptor, // FS
    (USBConfigurationDescriptor *) &sOtherSpeedConfigurationFS,
    &deviceDescriptor, // HS
    (USBConfigurationDescriptor *) &configurationDescriptorsHS,
    (USBDeviceQualifierDescriptor *) &deviceQualifierDescriptor, // HS
    (USBConfigurationDescriptor *) &sOtherSpeedConfigurationHS,
#else
    0, // No qualifier descriptor FS
    0, // No other-speed configuration FS
    0, // No device descriptor HS
    0, // No configuration HS
    0, // No qualifier descriptor HS
    0, // No other-speed configuration HS
#endif
    stringDescriptors,
    4 // Four string descriptors in array
};

//------------------------------------------------------------------------------
//      Internal functions
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
//      Exported functions
//------------------------------------------------------------------------------


//------------------------------------------------------------------------------
/// Return the Slot Status to the host
/// Answer to:
///   PC_to_RDR_IccPowerOff
///   PC_to_RDR_GetSlotStatus
///   PC_to_RDR_IccClock
///   PC_to_RDR_T0APDU
///   PC_to_RDR_Mechanical
///   PC_to_RDR_Abort and Class specific ABORT request
/// \param 
//------------------------------------------------------------------------------
static void RDRtoPCSlotStatus( void )
{
    trace_LOG(trace_DEBUG, "RDRtoPCSlotStatus\n\r");

    // Header fields settings
    ccidDriver.sCcidMessage.bMessageType = RDR_TO_PC_SLOTSTATUS;
    ccidDriver.sCcidMessage.wLength   = 0;
    ccidDriver.sCcidMessage.bStatus   = ccidDriver.SlotStatus;
    ccidDriver.sCcidMessage.bError    = 0;
    // 00h Clock running
    // 01h Clock stopped in state L
    // 02h Clock stopped in state H
    // 03h Clock stopped in an unknown state
    // All other values are Reserved for Future Use.
    ccidDriver.sCcidMessage.bSpecific = 0;
}

//------------------------------------------------------------------------------
/// Answer to:
///   PC_to_RDR_IccPowerOn
/// \param 
//------------------------------------------------------------------------------
static void RDRtoPCDatablock_ATR( void )
{
    unsigned char i;
    unsigned char Atr[ATR_SIZE_MAX];
    unsigned char length;

    //trace_LOG(trace_DEBUG, "RDRtoPCDatablock\n\r");

    ISO7816_Datablock_ATR( Atr, &length );

    if( length > 5 ) {
        ccidDriver.ProtocolDataStructure[1] = Atr[5]&0x0F;           // TD(1)
        ccidDriver.bProtocol = Atr[5]&0x0F;           // TD(1)
    }

    // S_ccid_protocol_t0
    // bmFindexDindex
    ccidDriver.ProtocolDataStructure[0] = Atr[2];     // TA(1)

    // bmTCCKST0
    // For T=0 ,B0 

?? 快捷鍵說明

復(fù)制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
欧美高清www午色夜在线视频| 精品影视av免费| 日韩国产在线观看一区| 久久国产精品99久久久久久老狼| 国产麻豆日韩欧美久久| 91污在线观看| 日韩一级片在线播放| 国产精品视频一二| 亚洲国产视频在线| 国产久卡久卡久卡久卡视频精品| 99久久99久久精品免费看蜜桃| 欧美精品色一区二区三区| 久久精品这里都是精品| 亚洲一区二区三区小说| 国产成人精品免费| 欧美视频在线观看一区二区| 久久久久青草大香线综合精品| 17c精品麻豆一区二区免费| 日韩精品一二三区| 99国产精品久久久久久久久久久| 欧美一区二区播放| 亚洲日本青草视频在线怡红院 | 成人性色生活片免费看爆迷你毛片| 99国内精品久久| 欧美mv和日韩mv国产网站| 亚洲嫩草精品久久| 国产精品99久久久久久似苏梦涵| 色8久久人人97超碰香蕉987| 久久亚洲影视婷婷| 亚洲va中文字幕| av一本久道久久综合久久鬼色| 欧美变态tickling挠脚心| 一区二区三区欧美日| 大陆成人av片| 精品国产乱码久久久久久久久| 一区二区三区不卡视频在线观看| 国产精品一区二区三区乱码| 在线综合亚洲欧美在线视频| 18欧美亚洲精品| 风流少妇一区二区| 2023国产精品自拍| 日韩高清一区在线| 欧美视频一区二区三区在线观看| 国产精品不卡一区二区三区| 国产麻豆视频精品| 日韩精品一区二区三区在线观看 | 在线亚洲人成电影网站色www| 国产欧美视频一区二区三区| 免费观看在线综合| 欧美日韩高清一区二区三区| 一区二区三区四区亚洲| 99精品在线免费| 国产精品久久久久桃色tv| 国产精品99久久久久久久vr | 99久久精品国产一区二区三区| 精品国产免费人成电影在线观看四季| 亚洲妇女屁股眼交7| 91国产免费观看| 亚洲黄色免费网站| 色综合色综合色综合色综合色综合| 中文字幕成人av| 国产精品一区二区在线观看不卡 | 国产高清一区日本| 精品免费国产二区三区| 奇米精品一区二区三区在线观看一| 欧美人与禽zozo性伦| 亚洲综合无码一区二区| 日本电影欧美片| 一区二区三区在线不卡| 在线观看中文字幕不卡| 亚洲综合丝袜美腿| 欧美私模裸体表演在线观看| 亚洲一区二区三区自拍| 欧美日韩久久一区二区| 丝袜诱惑亚洲看片| 日韩精品中文字幕在线一区| 久久99精品久久久久婷婷| 日韩一区二区电影在线| 国内外成人在线视频| 久久综合色鬼综合色| 国产精品1区二区.| 中文字幕欧美日韩一区| 91碰在线视频| 亚洲自拍偷拍网站| 337p亚洲精品色噜噜狠狠| 蜜芽一区二区三区| 久久综合九色综合97_久久久| 国产成人8x视频一区二区| 中文字幕va一区二区三区| 97久久精品人人爽人人爽蜜臀 | 欧美狂野另类xxxxoooo| 午夜日韩在线观看| 精品久久久久久最新网址| 国产成人免费视频一区| 中文字幕日韩av资源站| 在线观看日韩一区| 日韩精品91亚洲二区在线观看| 日韩午夜激情av| 国产精品羞羞答答xxdd| 亚洲免费av高清| 欧美一级专区免费大片| 国产精品18久久久久久久久| 国产精品欧美经典| 色94色欧美sute亚洲线路二| 日本三级韩国三级欧美三级| 亚洲精品一区二区三区在线观看 | 成人欧美一区二区三区| 欧美性生活大片视频| 老司机午夜精品| 国产欧美一区二区精品久导航| 一本到不卡免费一区二区| 爽爽淫人综合网网站| 国产三级精品视频| 欧美亚洲一区三区| 韩国一区二区在线观看| 亚洲黄色尤物视频| 精品成人a区在线观看| 91丨国产丨九色丨pron| 日韩中文字幕不卡| 国产精品久久久一本精品| 欧美日韩国产综合草草| 国产成人精品一区二区三区网站观看| 一区二区三区在线观看欧美| 精品国产免费久久| 色偷偷88欧美精品久久久| 91啪亚洲精品| 狠狠v欧美v日韩v亚洲ⅴ| 一区二区三区丝袜| 国产日韩精品一区二区浪潮av | 免费一区二区视频| 国产精品久久久久四虎| 日韩精品专区在线| 在线亚洲高清视频| 懂色av一区二区在线播放| 日韩精品亚洲专区| 亚洲图片激情小说| 精品国产网站在线观看| 欧美日韩国产中文| 99久久国产综合精品色伊| 久88久久88久久久| 亚洲一区二区三区美女| 国产精品免费久久| 日韩精品影音先锋| 欧美日韩国产另类一区| 99re免费视频精品全部| 国内精品在线播放| 日本在线播放一区二区三区| 樱桃视频在线观看一区| 国产日韩欧美综合一区| 精品三级av在线| 欧美日韩第一区日日骚| 一本一本久久a久久精品综合麻豆| 国产一区二区视频在线播放| 三级影片在线观看欧美日韩一区二区| 1区2区3区精品视频| 日本一区二区在线不卡| 久久毛片高清国产| 欧美成人r级一区二区三区| 欧美日韩高清一区| 欧美系列日韩一区| 色拍拍在线精品视频8848| www.日韩精品| 国产suv一区二区三区88区| 韩国一区二区视频| 激情综合网天天干| 男人操女人的视频在线观看欧美| 亚洲国产成人av网| 亚洲综合色婷婷| 亚洲精品综合在线| 亚洲视频中文字幕| 亚洲欧美一区二区三区国产精品| 国产欧美精品区一区二区三区| 久久美女高清视频| 久久男人中文字幕资源站| 精品国产乱码久久久久久影片| 欧美精品tushy高清| 欧美日韩精品一区视频| 欧美日韩一区不卡| 欧美日韩国产一级二级| 欧美日韩大陆在线| 337p亚洲精品色噜噜| 日韩丝袜情趣美女图片| 欧美大片在线观看一区二区| 日韩欧美在线影院| 欧美videossexotv100| 精品少妇一区二区三区免费观看| 欧美mv日韩mv国产| 久久久久久久久久久99999| 国产亚洲精品中文字幕| 国产欧美日韩精品a在线观看| 国产清纯在线一区二区www| 国产欧美综合色| 亚洲私人黄色宅男| 一级特黄大欧美久久久| 午夜伦欧美伦电影理论片| 日韩成人一级大片| 国产精品综合视频| 波多野结衣在线一区| 色综合婷婷久久| 在线观看亚洲a|