Hello,
I would like to create a HID High Speed USB device using uVision 5.12.0.0 with latest version packages. After create a new project and do some adjustment, I still have the following error (during compilation):
C:\Keil_v5\ARM\PACK\Keil\MDK-Middleware\6.2.0\USB\Include\usbd_config_dev_0.c(23): error: #94-D: the size of an array must be greater than zero uint8_t usbd0_alt_setting [USBD0_IF_CNT];
The hardware is based on SMT32F427ZGTx using a external PHY.
The application is based on HID recommendations from www.keil.com/.../group__usbd__hid_functions.html
Other adjustment (after project creation):
- #define USBD_HID0_DEV 1 - #define USBD0_PORT 1 - #define RTE_USB_OTG_FS 0 - #define RTE_USB_OTG_HS 1 - #define RTE_USB_OTG_HS_PHY 1 - #define RTE_USB_OTG_HS_HOST 0
Thanks for any suggestion,
Julio
Why don't you try already available examples for for example MCBSTM32F400 and start from there.
Hi wild. Thanks for your reply. I used some examples and get better results. When I connected the USB cable to the computer, the system (Win7) shows Unknown device. Any suggestion? Thanks
Is your schematic of the USB part same as on Keil MCBSTM32F400 http://www.keil.com/mcbstm32f400/mcbstm32f400-schematics.pdf ? If not you need to adapt differences into code (in RTE_Device.h file).
Also you need to disable any code using peripherals that you do not have on your board such as graphic LCD and so on.
Hi Guys exactly this is my Big Problem i use Stm32f103Rb6