Virtual Com with IAR

Started by ebreuilly April 10, 2006
I download the virtualcom.zip file from keil and I try to compile it
with IAR with LPC2148 IAR board. There are many difference between Keil
and IAR source (ex __irq doesn't exist in IAR) so I can't compile this
correctly.

Do anyone have already compile this example with IAR ?

Thank you for your help,
Lo CHEVALIER



An Engineer's Guide to the LPC2100 Series

ebreuilly wrote:
> I download the virtualcom.zip file from keil and I try to compile it
> with IAR with LPC2148 IAR board. There are many difference between Keil
> and IAR source (ex __irq doesn't exist in IAR) so I can't compile this
> correctly.
>
> Do anyone have already compile this example with IAR ?
>
> Thank you for your help,
> Lo CHEVALIER
>
Well to get you started, add this chunk of code to the USB_Init function
in the "usbhw.c" file after the initializing of the PCONP setting. This
will turn on the USB connect transistor on the LPC-2148-E board, that
isn't present with the keil board. This will allow you to build the
software with Keil's evaluation version and get you started on
development. For the moment there is no direct port to IAR.

" /* Addes IAR LPC2148-E compatibility */

#define P0_23 (1<<14) /* Enable Vbus */
#define P0_31 (2<<30) /* Enable USB Connect */

PINSEL1 = (P0_23 | P0_31); /* Enable Vbus and USB Connect */
"

Regards,

*/Robert Nelson/*//
Applications Engineer
r...@digikey.com
--- In l..., Robert Nelson
wrote:
>
> ebreuilly wrote:
> > I download the virtualcom.zip file from keil and I try to compile
it
> > with IAR with LPC2148 IAR board. There are many difference
between Keil
> > and IAR source (ex __irq doesn't exist in IAR) so I can't compile
this
> > correctly.
> >
> > Do anyone have already compile this example with IAR ?
> >
> > Thank you for your help,
> > Lo CHEVALIER
> >
> Well to get you started, add this chunk of code to the USB_Init
function
> in the "usbhw.c" file after the initializing of the PCONP setting.
This
> will turn on the USB connect transistor on the LPC-2148-E board,
that
> isn't present with the keil board. This will allow you to build
the
> software with Keil's evaluation version and get you started on
> development. For the moment there is no direct port to IAR.
>
> " /* Addes IAR LPC2148-E compatibility */
>
> #define P0_23 (1<<14) /* Enable Vbus */
> #define P0_31 (2<<30) /* Enable USB Connect */
>
> PINSEL1 = (P0_23 | P0_31); /* Enable Vbus and USB Connect */
> "
>
> Regards,
>
> */Robert Nelson/*//
> Applications Engineer
> robert.nelson@...
>
Thanks for your answer, now the USB seems works. The yellow Led
become ON and the HID class is create in peripheric PC, but not com3
& com4. So I can't test this exemple with an hyperterminal.
If you have any idea for help me ?

Thank you in advance,
Lo CHEVALIER



ebreuilly wrote:
>
> >
> Thanks for your answer, now the USB seems works. The yellow Led
> become ON and the HID class is create in peripheric PC, but not com3
> & com4. So I can't test this exemple with an hyperterminal.
> If you have any idea for help me ?
>
> Thank you in advance,
> Lo CHEVALIER
On my system, as soon as the USB cable was plugged in i loaded the
virtual comm drivers from the build directory, then two com's (com7 and
com8) are created, but the system needs to be rebooted after first
install. After that i had no issues loading hyper terminal on com8
(usb) and communicating to another hyper terminal on com1 using the On
board RS232_1 connector. ASCII data would transfer just as easily.

Robert Nelson
Applications Engineer
Digi-Key
r...@digikey.com