We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
Hi,
I am a beginner in using µvision I have "LPC1788 Developer's Kit" and I want to write a program for my microcontroller in order to receive a message via the USB port and send it via the RS232 port. Does anyone can help me please.
USB-UART function is usually implemented with CDC (Communication Device Class) on USB MCUs.
Keil MDK-ARM has RL-USB library, which includes CDC example. C:\Keil\ARM\Boards\Keil\MCB1700\RL\USB\Device\CDC For LPC1788, you may need to touch to USBD_Init() (usbd_LPC17xx.c), to set up PORT_FUNC bits of OTGStCtrl register for the second USB port.
If you like to be just a user of a USB stack, without dipping in the USB details, this option is yours.
If you like to play with the source of USB device stack, here is another option.
MCB1700 Sample Code Bundle for LPC17xx Peripherals using Keil's MDK-ARM www.lpcware.com/.../mcb1700-sample-code-bundle-lpc17xx-peripherals-using-keils-mdk-arm
USBCDC on this example gives full source code of the stack.
Tsuneo
Implementing USB is not a beginner's project!
Strongly suggest that you start with simpler projects to gain familiarity with the chip, the tools, and all the support that's available - there are examples & tutorials on this site, on the NXP site, and many other 3rd-party sites.
www.nxp.com/.../LPC1788FET208
http://www.keil.com/books
http://www.keil.com/support/man/docs/gsac/
http://www.keil.com/support/man/docs/uv4/uv4_examples.htm
http://www.lvr.com/usb.htm
Thank you Tsuneo Chinzei, you've been very hulpful.
Thank you Andrew Neil, i will take a look .