VSF Documented
device.h
Go to the documentation of this file.
1/*****************************************************************************
2 * Copyright(C)2009-2022 by VSF Team *
3 * *
4 * Licensed under the Apache License, Version 2.0 (the "License"); *
5 * you may not use this file except in compliance with the License. *
6 * You may obtain a copy of the License at *
7 * *
8 * http://www.apache.org/licenses/LICENSE-2.0 *
9 * *
10 * Unless required by applicable law or agreed to in writing, software *
11 * distributed under the License is distributed on an "AS IS" BASIS, *
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. *
13 * See the License for the specific language governing permissions and *
14 * limitations under the License. *
15 * *
16 ****************************************************************************/
17
18#ifndef __HAL_DEVICE_CMEM7_H__
19#define __HAL_DEVICE_CMEM7_H__
20
21/*============================ INCLUDES ======================================*/
22#include "hal/vsf_hal_cfg.h"
23
24/*============================ MACROS ========================================*/
25#define USB_OTG_COUNT 1
26#define USB_OTG0_IRQHandler USB_IRQHandler
27// required by dwcotg, define the max ep number of dwcotg
28#define USB_DWCOTG_MAX_EP_NUM 4
29
30#define USB_OTG0_CONFIG \
31 .ep_num = 8, \
32 .irq = USB_INT_IRQn, \
33 .reg = USB_BASE, \
34 .use_as__vsf_dwcotg_hw_info_t.buffer_word_size = 0x800 >> 2, \
35 .use_as__vsf_dwcotg_hw_info_t.speed = USB_SPEED_HIGH, \
36 .use_as__vsf_dwcotg_hw_info_t.dma_en = false, \
37 .use_as__vsf_dwcotg_hw_info_t.ulpi_en = false, \
38 .use_as__vsf_dwcotg_hw_info_t.utmi_en = true, \
39 .use_as__vsf_dwcotg_hw_info_t.vbus_en = false,
40
41
42/*============================ MACROFIED FUNCTIONS ===========================*/
43/*============================ TYPES =========================================*/
44/*============================ GLOBAL VARIABLES ==============================*/
45/*============================ LOCAL VARIABLES ===============================*/
46/*============================ PROTOTYPES ====================================*/
47
48
49#endif
50/* EOF */