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

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

?? usbendpointdescriptor.h

?? configure HID devices like USB mouse with A91SAM7SE CPU. Inlcude initilization for necessary periphe
?? H
字號:
/* ----------------------------------------------------------------------------
 *         ATMEL Microcontroller Software Support 
 * ----------------------------------------------------------------------------
 * Copyright (c) 2008, Atmel Corporation
 *
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions are met:
 *
 * - Redistributions of source code must retain the above copyright notice,
 * this list of conditions and the disclaimer below.
 *
 * Atmel's name may not be used to endorse or promote products derived from
 * this software without specific prior written permission.
 *
 * DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR
 * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
 * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE
 * DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT,
 * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
 * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
 * LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
 * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
 * EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 * ----------------------------------------------------------------------------
 */

/**
 \unit

 !!!Purpose

    Definition of a class for handling USB endpoint descriptors.

 !!!Usage

    -# Declare USBEndpointDescriptor instance as a part of the
       configuration descriptors of a USB device.
    -# To get useful information (field values) from the defined USB device
       endpoint descriptor (to configure hardware for endpoints, etc), use
       - USBEndpointDescriptor_GetNumber
       - USBEndpointDescriptor_GetDirection
       - USBEndpointDescriptor_GetType
       - USBEndpointDescriptor_GetMaxPacketSize
*/

#ifndef USBENDPOINTDESCRIPTOR_H
#define USBENDPOINTDESCRIPTOR_H

//------------------------------------------------------------------------------
//         Definitions
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
/// \page "USB Endpoint definitions"
///
/// This page lists definitions and macro for endpoint descriptors.
///
/// - USB Endpoint directions
///    - USBEndpointDescriptor_OUT 
///    - USBEndpointDescriptor_IN
///
/// - USB Endpoint types
///    - USBEndpointDescriptor_CONTROL
///    - USBEndpointDescriptor_ISOCHRONOUS
///    - USBEndpointDescriptor_BULK
///    - USBEndpointDescriptor_INTERRUPT
///
/// - USB Endpoint maximun sizes
///    - USBEndpointDescriptor_MAXCTRLSIZE_FS
///    - USBEndpointDescriptor_MAXCTRLSIZE_HS
///    - USBEndpointDescriptor_MAXBULKSIZE_FS
///    - USBEndpointDescriptor_MAXBULKSIZE_HS
///    - USBEndpointDescriptor_MAXINTERRUPTSIZE_FS
///    - USBEndpointDescriptor_MAXINTERRUPTSIZE_HS
///    - USBEndpointDescriptor_MAXISOCHRONOUSSIZE_FS
///    - USBEndpointDescriptor_MAXISOCHRONOUSSIZE_HS
///
/// - USB Endpoint address define
///    - USBEndpointDescriptor_ADDRESS
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
/// \page "USB Endpoint directions"
///
/// This page lists definitions of USB endpoint directions.
///
/// !Directions
/// - USBEndpointDescriptor_OUT
/// - USBEndpointDescriptor_IN

/// Endpoint receives data from the host.
#define USBEndpointDescriptor_OUT           0
/// Endpoint sends data to the host.
#define USBEndpointDescriptor_IN            1
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
/// \page "USB Endpoint types"
///
/// This page lists definitions of USB endpoint types.
///
/// !Types
/// - USBEndpointDescriptor_CONTROL
/// - USBEndpointDescriptor_ISOCHRONOUS
/// - USBEndpointDescriptor_BULK
/// - USBEndpointDescriptor_INTERRUPT

/// Control endpoint type.
#define USBEndpointDescriptor_CONTROL       0
/// Isochronous endpoint type.
#define USBEndpointDescriptor_ISOCHRONOUS   1
/// Bulk endpoint type.
#define USBEndpointDescriptor_BULK          2
/// Interrupt endpoint type.
#define USBEndpointDescriptor_INTERRUPT     3
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
/// \page "USB Endpoint maximun sizes"
///
/// This page lists definitions of USB endpoint maximun sizes.
///
/// !Sizes
/// - USBEndpointDescriptor_MAXCTRLSIZE_FS
/// - USBEndpointDescriptor_MAXCTRLSIZE_HS
/// - USBEndpointDescriptor_MAXBULKSIZE_FS
/// - USBEndpointDescriptor_MAXBULKSIZE_HS
/// - USBEndpointDescriptor_MAXINTERRUPTSIZE_FS
/// - USBEndpointDescriptor_MAXINTERRUPTSIZE_HS
/// - USBEndpointDescriptor_MAXISOCHRONOUSSIZE_FS
/// - USBEndpointDescriptor_MAXISOCHRONOUSSIZE_HS

/// Maximum size for a full-speed control endpoint.
#define USBEndpointDescriptor_MAXCTRLSIZE_FS                64
/// Maximum size for a high-speed control endpoint.
#define USBEndpointDescriptor_MAXCTRLSIZE_HS                64
/// Maximum size for a full-speed bulk endpoint.
#define USBEndpointDescriptor_MAXBULKSIZE_FS                64
/// Maximum size for a high-speed bulk endpoint.
#define USBEndpointDescriptor_MAXBULKSIZE_HS                512
/// Maximum size for a full-speed interrupt endpoint.
#define USBEndpointDescriptor_MAXINTERRUPTSIZE_FS           64
/// Maximum size for a high-speed interrupt endpoint.
#define USBEndpointDescriptor_MAXINTERRUPTSIZE_HS           1024
/// Maximum size for a full-speed isochronous endpoint.
#define USBEndpointDescriptor_MAXISOCHRONOUSSIZE_FS         1023
/// Maximum size for a high-speed isochronous endpoint.
#define USBEndpointDescriptor_MAXISOCHRONOUSSIZE_HS         1024
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
/// \page "USB Endpoint address define"
///
/// This page lists macro for USB endpoint address definition.
///
/// !Macro
/// - USBEndpointDescriptor_ADDRESS

/// Calculates the address of an endpoint given its number and direction
/// \param direction USB endpoint direction definition
/// \param number USB endpoint number
/// \return The value used to set the endpoint descriptor based on input number
///         and direction
#define USBEndpointDescriptor_ADDRESS(direction, number) \
    (((direction & 0x01) << 7) | (number & 0xF))
//------------------------------------------------------------------------------

//------------------------------------------------------------------------------
//         Types
//------------------------------------------------------------------------------

#ifdef __ICCARM__          // IAR
#pragma pack(1)            // IAR
#define __attribute__(...) // IAR
#endif                     // IAR

//------------------------------------------------------------------------------
/// USB standard endpoint descriptor structure.
//------------------------------------------------------------------------------
typedef struct {

   /// Size of the descriptor in bytes.
   unsigned char bLength;
   /// Descriptor type (<USBGenericDescriptor_ENDPOINT>).
   unsigned char bDescriptorType;
   /// Address and direction of the endpoint.
   unsigned char bEndpointAddress;
   /// Endpoint type and additional characteristics (for isochronous endpoints).
   unsigned char bmAttributes;
   /// Maximum packet size (in bytes) of the endpoint.
   unsigned short wMaxPacketSize;
   /// Polling rate of the endpoint.
   unsigned char bInterval;

} __attribute__ ((packed)) USBEndpointDescriptor; // GCC

#ifdef __ICCARM__          // IAR
#pragma pack()             // IAR
#endif                     // IAR

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

extern unsigned char USBEndpointDescriptor_GetNumber(
    const USBEndpointDescriptor *endpoint);

extern unsigned char USBEndpointDescriptor_GetDirection(
    const USBEndpointDescriptor *endpoint);

extern unsigned char USBEndpointDescriptor_GetType(
    const USBEndpointDescriptor *endpoint);

extern unsigned short USBEndpointDescriptor_GetMaxPacketSize(
    const USBEndpointDescriptor *endpoint);

#endif //#ifndef USBENDPOINTDESCRIPTOR_H

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲欧美在线观看| 精品久久久久av影院| 成人av在线播放网站| 国产麻豆视频一区二区| 狠狠v欧美v日韩v亚洲ⅴ| 免费人成精品欧美精品| 精品一区二区三区久久久| 久久成人精品无人区| 激情综合色综合久久| 精品夜夜嗨av一区二区三区| 国产一区二区三区免费播放 | 99精品欧美一区二区三区综合在线| 99久久久国产精品免费蜜臀| 粉嫩一区二区三区性色av| 国产精品一二三区在线| 成人小视频免费观看| 91蜜桃传媒精品久久久一区二区| 色综合久久综合网97色综合 | 激情丁香综合五月| 国产精品一品视频| 91免费在线看| 欧美一区二区三区在线观看| 欧美一区二区三区精品| 国产日韩精品一区二区三区 | 国产欧美一区在线| 最近中文字幕一区二区三区| 亚洲国产视频在线| 韩日av一区二区| 日本伦理一区二区| 欧美大肚乱孕交hd孕妇| 中文字幕日韩一区二区| 日韩不卡一二三区| 波多野结衣视频一区| 欧美精品一二三| 国产精品系列在线| 日韩 欧美一区二区三区| 成人免费视频免费观看| 欧美精品国产精品| 中文字幕亚洲精品在线观看| 久久疯狂做爰流白浆xx| 一本大道久久精品懂色aⅴ | 国产日产欧美一区| 天天操天天干天天综合网| 成人午夜碰碰视频| 日韩欧美中文字幕公布| 亚洲欧美日韩国产中文在线| 激情图片小说一区| 91麻豆精品国产综合久久久久久| 中文字幕欧美一| 国产一区在线不卡| 欧美日韩一二三| 亚洲天堂av老司机| 国产精品一二三四| 欧美成人a∨高清免费观看| 亚洲一区二区美女| 欧美一区二区啪啪| 中文字幕一区三区| 国产毛片精品视频| 久久夜色精品一区| 亚洲成在线观看| 在线看不卡av| 亚洲精品一二三区| 成人av在线观| 成人欧美一区二区三区黑人麻豆 | 欧美成人免费网站| 免费视频一区二区| 欧美一级理论性理论a| 亚洲成国产人片在线观看| 色综合久久中文综合久久97| 国产精品水嫩水嫩| 成人午夜激情影院| 国产精品理伦片| 91香蕉国产在线观看软件| 国产精品美女久久久久久久久久久 | 日韩精品一区国产麻豆| 国产露脸91国语对白| 欧美成人video| 国产麻豆视频一区| 国产午夜精品福利| 高清视频一区二区| 国产精品乱码久久久久久| 成人小视频在线观看| 亚洲欧美综合另类在线卡通| av中文字幕不卡| 亚洲欧美国产77777| 色欲综合视频天天天| 亚洲色图制服诱惑| 91福利国产成人精品照片| 一区二区三区成人| 91麻豆精品91久久久久久清纯| 青娱乐精品在线视频| 精品成人在线观看| 99精品桃花视频在线观看| 亚洲高清在线精品| 欧美sm美女调教| 懂色av一区二区三区免费看| 亚洲色图欧美激情| 91精品国产综合久久精品性色 | 欧美电影免费观看高清完整版在| 激情小说欧美图片| 亚洲人成网站在线| 正在播放一区二区| youjizz国产精品| 亚洲一级在线观看| 久久久久久99久久久精品网站| 99视频有精品| 老司机午夜精品| 亚洲三级视频在线观看| 91精品国产91久久久久久一区二区 | 久久精品国产网站| 国产精品亲子乱子伦xxxx裸| 欧美日韩国产精选| 国产成人啪免费观看软件| 亚洲成人自拍偷拍| 国产欧美一区二区三区网站| 欧美视频自拍偷拍| 国产成人午夜视频| 美女脱光内衣内裤视频久久影院| 国产精品私房写真福利视频| 欧美一区二区三区婷婷月色| 91社区在线播放| 美国十次了思思久久精品导航| 亚洲欧洲制服丝袜| 国产欧美va欧美不卡在线| 欧美女孩性生活视频| 99久久夜色精品国产网站| 精品夜夜嗨av一区二区三区| 无码av中文一区二区三区桃花岛| 国产精品九色蝌蚪自拍| 26uuu精品一区二区三区四区在线 26uuu精品一区二区在线观看 | 国产精品伦一区二区三级视频| 91精品国产综合久久久久| 色婷婷亚洲一区二区三区| 国产成a人亚洲精品| 狠狠v欧美v日韩v亚洲ⅴ| 奇米亚洲午夜久久精品| 夜夜揉揉日日人人青青一国产精品| 久久精品人人做人人综合| 日韩欧美国产麻豆| 欧美裸体bbwbbwbbw| 欧洲另类一二三四区| 日韩欧美一区在线| 欧美三级乱人伦电影| 在线观看91精品国产入口| 91浏览器入口在线观看| 99精品视频在线观看| 成人18视频在线播放| 粉嫩aⅴ一区二区三区四区| 国产美女视频一区| 成人综合婷婷国产精品久久| 国产超碰在线一区| 大白屁股一区二区视频| 成人黄色一级视频| 99riav久久精品riav| 色婷婷精品久久二区二区蜜臀av| 99久久er热在这里只有精品15| 91污片在线观看| 在线视频国内自拍亚洲视频| 欧美性生活一区| 91精品在线一区二区| 日韩欧美一区在线| 国产午夜精品一区二区 | 欧美午夜精品久久久久久超碰| 欧美怡红院视频| 日韩一区二区三区电影| 精品美女在线播放| 国产精品毛片无遮挡高清| 亚洲黄色免费网站| 亚洲18女电影在线观看| 男男成人高潮片免费网站| 国产酒店精品激情| 91色九色蝌蚪| 欧美精选一区二区| 久久久久久久性| 亚洲免费色视频| 久久99久久精品| 91麻豆精品一区二区三区| 欧美日韩在线电影| 久久久精品一品道一区| 亚洲女与黑人做爰| 九九九久久久精品| av高清不卡在线| 欧美一级黄色片| 亚洲婷婷国产精品电影人久久| 香蕉加勒比综合久久| 国内精品久久久久影院一蜜桃| 成人小视频在线| 日韩三级.com| 亚洲自拍偷拍综合| 国产剧情av麻豆香蕉精品| 欧美在线你懂得| 国产欧美精品在线观看| 亚洲chinese男男1069| 成人av在线网站| 亚洲精品一区二区三区影院| 一区二区高清免费观看影视大全| 精品一区二区三区香蕉蜜桃| 欧美色老头old∨ideo| 中文字幕亚洲一区二区va在线| 乱中年女人伦av一区二区|