ipcxpresso54s018_dev_cdc_vcom_freertos

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

ipcxpresso54s018_dev_cdc_vcom_freertos

2,315 Views
john_c_kennedy
Contributor I

After importing this example for the LPC54S018-EVK board and after doing the necessary device configuration, when I build I get the following errors:

Building target: lpcxpresso54s018_dev_cdc_vcom_freertos.axf
Invoking: MCU Linker
arm-none-eabi-gcc -nostdlib -L"C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\LPC54S018\mcuxpresso" -Xlinker -Map="lpcxpresso54s018_dev_cdc_vcom_freertos.map" -Xlinker --gc-sections -Xlinker -print-memory-usage -Xlinker --sort-section=alignment -Xlinker --cref -mcpu=cortex-m4 -mfpu=fpv4-sp-d16 -mfloat-abi=hard -mthumb -T lpcxpresso54s018_dev_cdc_vcom_freertos_Debug.ld -o "lpcxpresso54s018_dev_cdc_vcom_freertos.axf" ./utilities/fsl_assert.o ./utilities/fsl_debug_console.o ./utilities/fsl_str.o ./usb/host/class/usb_host_cdc.o ./usb/host/class/usb_host_hub.o ./usb/host/class/usb_host_hub_app.o ./usb/host/usb_host_devices.o ./usb/host/usb_host_framework.o ./usb/host/usb_host_hci.o ./usb/host/usb_host_ohci.o ./usb/device/source/lpcip3511/usb_device_lpcip3511.o ./usb/device/source/usb_device_ch9.o ./usb/device/source/usb_device_dci.o ./usb/device/class/cdc/usb_device_cdc_acm.o ./usb/device/class/usb_device_class.o ./startup/startup_lpc54s018.o ./source/generated/usb_host_app.o ./source/semihost_hardfault.o ./source/usb_device_descriptor.o ./source/usb_host_interface_0_cic_vcom.o ./source/virtual_com.o ./freertos/freertos_kernel/portable/MemMang/heap_4.o ./freertos/freertos_kernel/portable/GCC/ARM_CM4F/port.o ./freertos/freertos_kernel/croutine.o ./freertos/freertos_kernel/event_groups.o ./freertos/freertos_kernel/list.o ./freertos/freertos_kernel/queue.o ./freertos/freertos_kernel/stream_buffer.o ./freertos/freertos_kernel/tasks.o ./freertos/freertos_kernel/timers.o ./drivers/fsl_clock.o ./drivers/fsl_common.o ./drivers/fsl_common_arm.o ./drivers/fsl_dma.o ./drivers/fsl_emc.o ./drivers/fsl_flexcomm.o ./drivers/fsl_gpio.o ./drivers/fsl_reset.o ./drivers/fsl_usart.o ./drivers/fsl_usart_cmsis.o ./drivers/fsl_usart_dma.o ./device/system_LPC54S018.o ./component/uart/fsl_adapter_usart.o ./component/serial_manager/fsl_component_serial_manager.o ./component/serial_manager/fsl_component_serial_port_uart.o ./component/osa/fsl_os_abstraction_free_rtos.o ./component/lists/fsl_component_generic_list.o ./board/board.o ./board/clock_config.o ./board/peripherals.o ./board/pin_mux.o ./LPC54S018/drivers/fsl_power.o -lpower_hardabi
c:/nxp/mcuxpressoide_11.5.0_7232/ide/plugins/com.nxp.mcuxpresso.tools.win32_11.5.0.202107051138/tools/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: ./source/virtual_com.o: in function `USB0_IRQHandler':
C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/virtual_com.c:123: multiple definition of `USB0_IRQHandler'; ./source/generated/usb_host_app.o:C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/generated/usb_host_app.c:75: first defined here
c:/nxp/mcuxpressoide_11.5.0_7232/ide/plugins/com.nxp.mcuxpresso.tools.win32_11.5.0.202107051138/tools/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: ./source/virtual_com.o: in function `USB_DeviceCdcVcomCallback':
C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/virtual_com.c:217: undefined reference to `USB_DeviceCdcAcmSend'
c:/nxp/mcuxpressoide_11.5.0_7232/ide/plugins/com.nxp.mcuxpresso.tools.win32_11.5.0.202107051138/tools/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/virtual_com.c:225: undefined reference to `USB_DeviceCdcAcmRecv'
c:/nxp/mcuxpressoide_11.5.0_7232/ide/plugins/com.nxp.mcuxpresso.tools.win32_11.5.0.202107051138/tools/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/virtual_com.c:256: undefined reference to `USB_DeviceCdcAcmRecv'
c:/nxp/mcuxpressoide_11.5.0_7232/ide/plugins/com.nxp.mcuxpresso.tools.win32_11.5.0.202107051138/tools/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/virtual_com.c:394: undefined reference to `USB_DeviceCdcAcmSend'
c:/nxp/mcuxpressoide_11.5.0_7232/ide/plugins/com.nxp.mcuxpresso.tools.win32_11.5.0.202107051138/tools/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: ./source/virtual_com.o: in function `USB_DeviceCallback':
C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/virtual_com.c:483: undefined reference to `USB_DeviceCdcAcmRecv'
c:/nxp/mcuxpressoide_11.5.0_7232/ide/plugins/com.nxp.mcuxpresso.tools.win32_11.5.0.202107051138/tools/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld.exe: ./source/virtual_com.o: in function `APPTask':
C:\Users\john_\Documents\MCUXpressoIDE_11.5.0_7232\workspace\lpcxpresso54s018_dev_cdc_vcom_freertos\Debug/../source/virtual_com.c:673: undefined reference to `USB_DeviceCdcAcmSend'

Any suggestions to fix this?

0 Kudos
Reply
3 Replies

2,306 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi

In order to resolve your issue, please let me know the steps of how to reproduce the problem?

Thanks,

Jun Zhang

0 Kudos
Reply

2,301 Views
john_c_kennedy
Contributor I

Hi, Thanks for your reply.  Here are the steps I followed:

I downloaded the SDK for the LPC54S018M-EVK board and imported the lpcexpresso54s018_dev_cdc_vcom_freertos project into the MCUXpresso IDE.

Then I ran the MCUXpresso IDE device configuration tool to configure the required peripherials, drivers, etc. by following the prompts and suggested fixes given by the configuration tool (I assume you are familiar with this tool).  

Then I built the project in MCUXpresso and got the errors I posted before.

Here is what I found about the errors:

The error in virtual_com.c line 123 occurs because the function USB0_IRQHandler is also defined in file usb_host_app.c on line 75?

The errors in virtual_com.c line 217, 483, 673: undefined reference to 'USB_DeviceCdcAcmSend', 'USB_DeviceCdcAcmRecv', and 'USB_DeviceCdcAcmSend'  occur because the symbol USB_DEVICE_CONFIG_CDC_ACM on line 18 in file usb_device_cdc_acm.c is not defined because it is set to (0U) in file usb_device_cdc_acm.h on line 55.

My guess is that these errors occur because the drivers are not configured correctly by the tools?

Any help you can give would be appreciated.

John

0 Kudos
Reply

2,281 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

HI

I need to know the detailed steps of how you do this

"Then I ran the MCUXpresso IDE device configuration tool to configure the required peripherials, drivers, etc. by following the prompts and suggested fixes given by the configuration tool (I assume you are familiar with this tool). "

Or I suggest you referring this article to use config tool generating your own USB application.

https://community.nxp.com/t5/LPC-Microcontrollers-Knowledge/Using-ConfigTool-to-create-USB-Project-F...

Jun Zhang

0 Kudos
Reply