Please help me with the following problem:
My MCU is STM32F429ZIT6 (Actually it is STM32F429DISCO board)
I made small test project for USB HID and the example from USB library is working fine.
To do this I made small "shield" and connected wires from PA11 to USB_OTG_FS_DM and PA12 to USB_OTG_FS_DP, both om them are through 22 Ohm resistors.
Also, USB pin D+ is pulled up to 3.3V with 1.5 kOhm resistor.
So, my laptop see the HID device, I can send and receive strings, also I put received strings to LCD2x16 which I installed before I try to use USB.
So I sure 100% my HID is working right.
Then, I want to make VCP connection because I have to send a huge information to laptop.
I found an example in USB library.
I made new project with right adjustments for my MCU, as it was with USB HID project.
I use VPC_Descriptor.mpas from the example. The file is included to the project in Project Inspector.
USB_Device_CDClass_STM32 and USB_Device_STM32_M4 are selected in Library Manager. Only these, because LCD is already disconnected.
When I try to compile the project I get many faults, they are shown below:
My code is -0 360 Unresolved extern 'OTG_FS_GUSBCFG' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GRSTCTL' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GAHBCFG' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DCFG' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_PCGCCTL' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GCCFG' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GRXFSIZ' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_HNPTXFSIZ_DIEPTXF0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DOEPTSIZ0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GUSBCFG' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GRXSTSPR' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DCTL' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DCFG' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GRXFSIZ' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DOEPTSIZ0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DAINT' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DAINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DIEPMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DIEPEMPMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DCTL' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DAINT' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DAINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DOEPMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GRSTCTL' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DCTL' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DCFG' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DAINT' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DAINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DOEPMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DIEPMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DOEPTSIZ0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTSTS' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DAINTMSK' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_HNPTXFSIZ_DIEPTXF0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DIEPTXF1' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_HNPTXFSIZ_DIEPTXF0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_GRXFSIZ' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DIEPTXF1' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DOEPTSIZ0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DOEPTSIZ0' __Lib_USB_Device_STM_M4.c
0 360 Unresolved extern 'OTG_FS_DIEPEMPMSK' __Lib_USB_Device_STM_M4.c
0 453 Unsuccessful linking 'bigbo_lcd.mppar' Unsuccessful linking 'bigbo_lcd.mppar'
0 102 Finished (with errors): 11 Âåð 2016, 20:05:25 bigbo_lcd.mppar
Code: Select all
program bigbo_lcd;
var buffer : array[64] of byte;
procedure USBDev_CDCParamsChanged();
begin
end;
// USB interrupt service routine
procedure USB0Interrupt(); iv IVT_INT_OTG_FS;
begin // Call library interrupt handler routine
USBDev_IntHandler();
end;
// Callback function which will be called on received packet
procedure USBDev_CDCDataReceived(size : word);
begin
// Prepare receive buffer
USBDev_CDCSetReceiveBuffer(@buffer);
// Send back received packet
USBDev_CDCSendData( @buffer, size);
end;
begin
// Initialize CDC Class
USBDev_CDCInit();
// Initialize USB device module
USBDev_Init();
// Enable USB device interrupt
NVIC_IntEnable(IVT_INT_OTG_FS);
// Wait until device is configured (enumeration is successfully finished)
while(USBDev_GetDeviceState() <> _USB_DEV_STATE_CONFIGURED) do ;
// Set receive buffer where received data is stored
USBDev_CDCSetReceiveBuffer(@buffer);
// Infinite loop
while(1) do
;
end.
PS Version is mikroPascal PRO for ARM 4.9.0