paparazzi-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Paparazzi-devel] =?ISO-8859-1?Q? USB bootloader?=


From: martin
Subject: Re: [Paparazzi-devel] =?ISO-8859-1?Q? USB bootloader?=
Date: Sat, 28 Jun 2008 08:48:11 +0200 (CEST)

Hi Scott,

> I was wondering if there is any way to force the bootloader device off
> the USB bus once the bootloading is complete.  What I mean by this is,
> in Windows, you see the bootloader device shown in the device manager
> when you plug it in, and when I say force it off the bus I mean that
> this installed device disappears.

If your hardware does include a switch to connect the pullup resistor
(P0.31, usb_connect) this should already happen in the bootloader. Make
sure you completely reset all USB registers in the LPC in your
application. Also you might trying to increase the wait time before you
reconnect in your application for Windows (bootloader.c):

            // disconnect from bus
            USBHwConnect(FALSE);

            // wait some ms so that called app might safely re-connect
usb
            for (count=0;count<300000;count++) count=count;

> The reason I want  to do this is because my application code starting
at
> 0x4000 also has USB functionality, and currently the only way to get
it
> running is to unplug the device, change the bootload/application
jumper
> and plug it back in.  I was hoping to make an application where I can
> jump back to the bootloader for program updates, and then after the
> update the bootloader jumps to application and the application's USB
> stack initializes properly.

If pullup disconnect works the simplest is to press reset (a couple of
100ms) for a restart of the bootloader. Or a jump to address zero with a
disconnect of the pullup and some wait time in your app.

Martin







reply via email to

[Prev in Thread] Current Thread [Next in Thread]