lpc54608 usb1 cdc

cancel
Showing results for 
Search instead for 
Did you mean: 

lpc54608 usb1 cdc

354 Views
eileen_radzwion
Contributor II

hi,

i am trying to configure usb1 for hs usb cdc mode on a prototyped board using the lpc54608. 

starting from dev_cdc_vcom_lite_bm,  I have set serial_port_type_usbcdc =  1, and usb_device_config_lpcip3511hs =1, while setting

#define USB_DEVICE_CONFIG_LPCIP3511FS (0u)

#define SERIAL_PORT_TYPE_UART (0U)

these are defined in serial_manager.h and usb_device_config.h

the first problem to arise is that, upon setting the port type to usbcdc rather than uart, I am unable to build.  second, if I prevent error from happening, I am still unable to connect.  so, I am wondering, what steps am I missing to configure usb1 for cdc.

thank you!

how I prevent (//commented out code is what came with sdk; my my modification is below)

/*******************************************************************************
 * Definitions
 ******************************************************************************/
#ifdef DEBUG_CONSOLE_TRANSFER_NON_BLOCKING
#define SERIAL_MANAGER_NON_BLOCKING_MODE \
    (1U) /* Enable or disable serial manager non-blocking mode (1 - enable, 0 - disable) */
#else
#ifndef SERIAL_MANAGER_NON_BLOCKING_MODE
#define SERIAL_MANAGER_NON_BLOCKING_MODE \
    (0U) /* Enable or disable serial manager non-blocking mode (1 - enable, 0 - disable) */
#endif
#endif

#ifndef SERIAL_PORT_TYPE_UART
#define SERIAL_PORT_TYPE_UART (1U) /* Enable or disable uart port (1 - enable, 0 - disable) */
#endif

#ifndef SERIAL_PORT_TYPE_USBCDC
#define SERIAL_PORT_TYPE_USBCDC (0U) /* Enable or disable USB CDC port (1 - enable, 0 - disable) */
#endif

#ifndef SERIAL_PORT_TYPE_SWO
#define SERIAL_PORT_TYPE_SWO (0U) /* Enable or disable SWO port (1 - enable, 0 - disable) */
#endif

#if (defined(SERIAL_MANAGER_NON_BLOCKING_MODE) && (SERIAL_MANAGER_NON_BLOCKING_MODE > 0U))
#define SERIAL_MANAGER_WRITE_HANDLE_SIZE (44U)
#define SERIAL_MANAGER_READ_HANDLE_SIZE (44U)
#else
#define SERIAL_MANAGER_WRITE_HANDLE_SIZE (4U)
#define SERIAL_MANAGER_READ_HANDLE_SIZE (4U)
#endif

#if (defined(SERIAL_PORT_TYPE_UART) && (SERIAL_PORT_TYPE_UART > 0U))
#include "serial_port_uart.h"
#endif

#if (defined(SERIAL_PORT_TYPE_USBCDC) && (SERIAL_PORT_TYPE_USBCDC > 0U))

//#if !(defined(SERIAL_MANAGER_NON_BLOCKING_MODE) && (SERIAL_MANAGER_NON_BLOCKING_MODE > 0U))
#if !(SERIAL_MANAGER_NON_BLOCKING_MODE > 0U)            //edited
#error The serial manager blocking mode cannot be supported for USB CDC.
#endif

#include "serial_port_usb.h"
#endif

Labels (1)
0 Kudos
7 Replies

100 Views
eileen_radzwion
Contributor II

I have just downloaded the latest SDK to see if that helped, so that is 2.6.  I am using IAR embedded workbench.

thanks!

0 Kudos

100 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi Eileen Radzwion,

Just tested SDK2.6.0 dev_cdc_vcom_lite_bm demo with IAR. 

The default demo use FS USB0 as composite VCOM. In order to change to HS USB1, I modify USB config setting as below:

pastedImage_1.png

rebuild the project and download. USB1 can be recognized as two VCOMs.

See my attached testing video.


Have a great day,
Jun Zhang

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos

100 Views
eileen_radzwion
Contributor II

Hi Jennie,

if you refer to my original post - i describe doing just that, but i am unable to connect still. i have now tried multiple different projects in the sdk download, and nothing improves the situation.

thank you

0 Kudos

100 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

In your previous email, you said you were not able to build. If you can make the project pass build. please follow the video to pass build first.

If build successfully, make sure you choose the correct debugger driver. For example, I use CMSIS DAP interface, I set driver as CMSIS DAP.

pastedImage_1.png


Have a great day,
Jun Zhang

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos

100 Views
eileen_radzwion
Contributor II

hello zhang,

thank you for your help.  i am able to build and have the demo running.  i would like to combine now the "hello world" example with the virtual com example, since hello world has the printf working with the debug console.  unfortunately, i'm not see a straighforward way to do this.  i have found 2 different threads ( https://community.nxp.com/thread/458760 and How to use CDC VCOM example with printf?  ) but they are not quite the same since they are referring different line of microcontrollers, and as the latest version is 2.6.  

0 Kudos

100 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

Hi Eileen.

Good to know your previous issue has been solved.

I am on leave this week.

I believe this combination issue is a new question, so I suggest you create a new thread for it.

Thus our other support could be able to see it. Thanks for your understanding.

Have a great day,
Jun Zhang

 

-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!

 

- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-------------------------------------------------------------------------------

0 Kudos

100 Views
ZhangJennie
NXP TechSupport
NXP TechSupport

HI,

I need reproduce first, which IDE do you work with and what is your SDK version?

Regards

Jun Zhang

0 Kudos