mirror of
https://github.com/sakumisu/CherryUSB.git
synced 2025-05-08 16:18:44 +08:00
refactor: move CHERRYUSB_VERSION and CHERRYUSB_VERSION_STR into usb_version.h
This commit is contained in:
parent
b171b28a75
commit
143a5ce3fd
@ -6,9 +6,6 @@
|
||||
#ifndef CHERRYUSB_CONFIG_H
|
||||
#define CHERRYUSB_CONFIG_H
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010301
|
||||
#define CHERRYUSB_VERSION_STR "v1.3.1"
|
||||
|
||||
/* ================ USB common Configuration ================ */
|
||||
|
||||
#define CONFIG_USB_PRINTF(...) printf(__VA_ARGS__)
|
||||
|
21
common/usb_version.h
Normal file
21
common/usb_version.h
Normal file
@ -0,0 +1,21 @@
|
||||
/*
|
||||
* Copyright (c) 2024, sakumisu
|
||||
*
|
||||
* SPDX-License-Identifier: Apache-2.0
|
||||
*/
|
||||
#ifndef USB_VERSION_H
|
||||
#define USB_VERSION_H
|
||||
|
||||
#ifdef CHERRYUSB_VERSION
|
||||
#warning "Please do not define CHERRYUSB_VERSION in usb_config.h"
|
||||
#undef CHERRYUSB_VERSION
|
||||
#endif
|
||||
#ifdef CHERRYUSB_VERSION_STR
|
||||
#warning "Please do not define CHERRYUSB_VERSION_STR in usb_config.h"
|
||||
#undef CHERRYUSB_VERSION_STR
|
||||
#endif
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010301
|
||||
#define CHERRYUSB_VERSION_STR "v1.3.1"
|
||||
|
||||
#endif
|
@ -23,6 +23,7 @@ extern "C" {
|
||||
#include "usb_log.h"
|
||||
#include "usb_dc.h"
|
||||
#include "usb_memcpy.h"
|
||||
#include "usb_version.h"
|
||||
|
||||
enum usbd_event_type {
|
||||
/* USB DCD IRQ */
|
||||
|
@ -21,6 +21,7 @@
|
||||
#include "usb_osal.h"
|
||||
#include "usbh_hub.h"
|
||||
#include "usb_memcpy.h"
|
||||
#include "usb_version.h"
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
|
@ -6,9 +6,6 @@
|
||||
|
||||
#pragma once
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010301
|
||||
#define CHERRYUSB_VERSION_STR "v1.3.1"
|
||||
|
||||
#include "sdkconfig.h"
|
||||
#include "esp_rom_sys.h"
|
||||
|
||||
|
@ -15,9 +15,6 @@
|
||||
#include "FreeRTOS.h"
|
||||
#include "task.h"
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010400
|
||||
#define CHERRYUSB_VERSION_STR "v1.4.0"
|
||||
|
||||
/* ================ USB common Configuration ================ */
|
||||
|
||||
#define CONFIG_USB_PRINTF(...) printf(__VA_ARGS__)
|
||||
|
@ -13,9 +13,6 @@
|
||||
|
||||
#include "rtconfig.h"
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010400
|
||||
#define CHERRYUSB_VERSION_STR "v1.4.0"
|
||||
|
||||
/* ================ USB common Configuration ================ */
|
||||
|
||||
#define CONFIG_USB_PRINTF(...) rt_kprintf(__VA_ARGS__)
|
||||
|
@ -13,9 +13,6 @@
|
||||
|
||||
#include "sdkconfig.h"
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010400
|
||||
#define CHERRYUSB_VERSION_STR "v1.4.0"
|
||||
|
||||
/* ================ USB common Configuration ================ */
|
||||
|
||||
#define CONFIG_USB_PRINTF(...) printf(__VA_ARGS__)
|
||||
|
@ -16,9 +16,6 @@
|
||||
#include "FreeRTOS.h"
|
||||
#include "task.h"
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010400
|
||||
#define CHERRYUSB_VERSION_STR "v1.4.0"
|
||||
|
||||
/* ================ USB common Configuration ================ */
|
||||
|
||||
#define CONFIG_USB_PRINTF(...) printf(__VA_ARGS__)
|
||||
|
@ -13,9 +13,6 @@
|
||||
|
||||
#include "rtthread.h"
|
||||
|
||||
#define CHERRYUSB_VERSION 0x010400
|
||||
#define CHERRYUSB_VERSION_STR "v1.4.0"
|
||||
|
||||
/* ================ USB common Configuration ================ */
|
||||
|
||||
#define CONFIG_USB_PRINTF(...) rt_kprintf(__VA_ARGS__)
|
||||
|
Loading…
x
Reference in New Issue
Block a user