Kleber Silva / IOTON-API

Dependents:   ton_demo ton_template

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers usbd_conf.h Source File

usbd_conf.h

00001 /**
00002   ******************************************************************************
00003   * @file    umart_lite_plus_teste/include/usbd_conf.h
00004   * @author  MCD Application Team
00005   * @version V1.2.0
00006   * @date    26-December-2014
00007   * @brief   General low level driver configuration
00008   ******************************************************************************
00009   * @attention
00010   *
00011   * <h2><center>&copy; COPYRIGHT(c) 2014 STMicroelectronics</center></h2>
00012   *
00013   * Licensed under MCD-ST Liberty SW License Agreement V2, (the "License");
00014   * You may not use this file except in compliance with the License.
00015   * You may obtain a copy of the License at:
00016   *
00017   *        http://www.st.com/software_license_agreement_liberty_v2
00018   *
00019   * Unless required by applicable law or agreed to in writing, software
00020   * distributed under the License is distributed on an "AS IS" BASIS,
00021   * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
00022   * See the License for the specific language governing permissions and
00023   * limitations under the License.
00024   *
00025   ******************************************************************************
00026   */
00027 
00028 /* Define to prevent recursive inclusion -------------------------------------*/
00029 #ifndef __USBD_CONF_H
00030 #define __USBD_CONF_H
00031 
00032 /* Includes ------------------------------------------------------------------*/
00033 #include "stm32f4xx_hal.h"
00034 #include <stdio.h>
00035 #include <stdlib.h>
00036 #include <string.h>
00037 
00038 /* Exported types ------------------------------------------------------------*/
00039 /* Exported constants --------------------------------------------------------*/
00040 /* Common Config */
00041 #define USBD_MAX_NUM_INTERFACES               1
00042 #define USBD_MAX_NUM_CONFIGURATION            1
00043 #define USBD_MAX_STR_DESC_SIZ                 0x100
00044 #define USBD_SUPPORT_USER_STRING              0
00045 #define USBD_SELF_POWERED                     1
00046 #define USBD_DEBUG_LEVEL                      0
00047 
00048 /* Exported macro ------------------------------------------------------------*/
00049 /* Memory management macros */
00050 #define USBD_malloc               malloc
00051 #define USBD_free                 free
00052 #define USBD_memset               memset
00053 #define USBD_memcpy               memcpy
00054 
00055 /* DEBUG macros */
00056 #if (USBD_DEBUG_LEVEL > 0)
00057 #define  USBD_UsrLog(...)   printf(__VA_ARGS__);\
00058                             printf("\n");
00059 #else
00060 #define USBD_UsrLog(...)
00061 #endif
00062 
00063 #if (USBD_DEBUG_LEVEL > 1)
00064 
00065 #define  USBD_ErrLog(...)   printf("ERROR: ") ;\
00066                             printf(__VA_ARGS__);\
00067                             printf("\n");
00068 #else
00069 #define USBD_ErrLog(...)
00070 #endif
00071 
00072 #if (USBD_DEBUG_LEVEL > 2)
00073 #define  USBD_DbgLog(...)   printf("DEBUG : ") ;\
00074                             printf(__VA_ARGS__);\
00075                             printf("\n");
00076 #else
00077 #define USBD_DbgLog(...)
00078 #endif
00079 
00080 /* Exported functions ------------------------------------------------------- */
00081 
00082 #endif /* __USBD_CONF_H */
00083 
00084 /************************ (C) COPYRIGHT STMicroelectronics *****END OF FILE****/