- Main Page
- Related Pages
- Modules
- Data Structures
- Files

- File List
- Globals

# usb_standard_request.h

Go to the documentation of this file.

    00001 /*This file is prepared for Doxygen automatic documentation generation.*/
    00021
    00022 /* Copyright (c) 2009 Atmel Corporation. All rights reserved.
    00023  *
    00024  * Redistribution and use in source and binary forms, with or without
    00025  * modification, are permitted provided that the following conditions are met:
    00026  *
    00027  * 1. Redistributions of source code must retain the above copyright notice,
    00028  * this list of conditions and the following disclaimer.
    00029  *
    00030  * 2. Redistributions in binary form must reproduce the above copyright notice,
    00031  * this list of conditions and the following disclaimer in the documentation
    00032  * and/or other materials provided with the distribution.
    00033  *
    00034  * 3. The name of Atmel may not be used to endorse or promote products derived
    00035  * from this software without specific prior written permission.
    00036  *
    00037  * 4. This software may only be redistributed and used in connection with an Atmel
    00038  * AVR product.
    00039  *
    00040  * THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR IMPLIED
    00041  * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
    00042  * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE EXPRESSLY AND
    00043  * SPECIFICALLY DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT,
    00044  * INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
    00045  * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
    00046  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
    00047  * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
    00048  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
    00049  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
    00050  */
    00051
    00052 #ifndef _USB_STANDARD_REQUEST_H_
    00053 #define _USB_STANDARD_REQUEST_H_
    00054
    00055 //_____ I N C L U D E S ____________________________________________________
    00056
    00057 #include "modules/usb/usb_task.h"
    00058 #include "usb_descriptors.h"
    00059
    00060 //_____ M A C R O S ________________________________________________________
    00061
    00062 //_____ S T A N D A R D    D E F I N I T I O N S ___________________________
    00063
    00066
    00067
    00068
    00069         // Device State
    00070 #define ATTACHED                          0
    00071 #define POWERED                           1
    00072 #define DEFAULT                           2
    00073 #define ADDRESSED                         3
    00074 #define CONFIGURED                        4
    00075 #define SUSPENDED                         5
    00076
    00077 #define USB_REMOTE_WAKEUP       1
    00078
    00079 //_____ D E C L A R A T I O N ______________________________________________
    00080
    00083 #define Is_device_enumerated()            ((usb_configuration_nb!=0)   ? TRUE : FALSE)
    00084 #define Is_device_not_enumerated()        ((usb_configuration_nb!=0)   ? FALSE : TRUE)
    00085
    00086
    00087
    00088
    00108 void    usb_process_request( void);
    00109
    00119 void     usb_generate_remote_wakeup(void);
    00120
    00121 extern  U8   usb_configuration_nb;
    00122 extern  U8   remote_wakeup_feature;
    00123
    00124
    00125 #if (USE_DEVICE_SN_UNIQUE==ENABLE)
    00126 extern  U8   f_get_serial_string;
    00127 #endif
    00128
    00130
    00131 #endif  // _USB_STANDARD_REQUEST_H_
    00132