Mass Storage bootloader for AT90USB162

178 views
Skip to first unread message

Gobi C

unread,
Jun 14, 2013, 11:09:23 AM6/14/13
to lufa-s...@googlegroups.com
Dear Dean,
   So far I have used LUFA for MKII-ISP Clone. Now I am more exited about the MSC Boot-loader for avr's and xmega's
I tried building the latest git for STK526 AT90USB162 device. Changes made only in the make file.

-MCU          = at90usb1287
+MCU          = at90usb162

-BOARD        = USBKEY
+BOARD        = STK526

-FLASH_SIZE_KB         = 128
-BOOT_SECTION_SIZE_KB  = 8
+FLASH_SIZE_KB         = 16
+BOOT_SECTION_SIZE_KB  = 4

No Application on the board only LUFA MSC bootloader. When I connect the USB Cable to PC the Removable disk keeps disconnecting and reconnecting.
and LED's LED0 and LED1 blinks alternately which shows the bootloader is running and not yet ready.

I hope you have tested on 1287 device
Can you point me to find the real issue. If you need more information I can share with you.
Once I am successful with this device I want to use it also for XMEGA device.
Thank you

Dean Camera

unread,
Jun 17, 2013, 2:07:11 AM6/17/13
to lufa-s...@googlegroups.com
Gobi,

Let's rule out toolchain issues first. Can you please try the precompiled bootloader here:

F_USB of 16MHz:

F_USB of 8MHz:

If those don't work, it's possible your device's bootloader section fuses aren't set to 2048 words (4KB) or your watchdog is force-enabled in the fuses.

Cheers!
- Dean





--
You received this message because you are subscribed to the Google Groups "LUFA Library Support List" group.
To unsubscribe from this group and stop receiving emails from it, send an email to lufa-support...@googlegroups.com.
To post to this group, send email to lufa-s...@googlegroups.com.
Visit this group at http://groups.google.com/group/lufa-support.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Henry Carl Ott

unread,
Jul 5, 2013, 9:39:04 AM7/5/13
to lufa-s...@googlegroups.com
Just jumping on board here. Got a new project idea, and an MSD bootloader would make life so much easier for the end user. 

  I'm trying to use the same hardware configuration as the OP, and I am seeing the same behavior.
 
 at90usb162  Very basic hardware that's been working for years with other LUFA code on it. 

     Drive enumerates / drops off. Repeats.  (winxp, on two different boxes)
      Tried with your precompiled .hex  Double checked the fuses,  the fuses look good to me.
       Same behavior.

      The code does seem to work on some similar hardware, but with an mega16u4.
         Just seems to an issue on the smaller parts.
 
      Any other suggestions on things to check?

   Thanks,

-carl

Dean Camera

unread,
Jul 6, 2013, 6:40:34 AM7/6/13
to lufa-s...@googlegroups.com
It's likely this is an issue due to the limited amount of RAM - the FAT
entries are stored in RAM both to save on FLASH, and to allow the host
and bootloader to dynamically alter them. I'm not sure I can strip off
too much more from it; if I can't, I might just have to mark the
AT90USB162 and AT90USB82 as unsupported.

Cheers!
- Dean

On Friday, 5 July 2013 3:39:04 PM, Henry Carl Ott wrote:
> Just jumping on board here. Got a new project idea, and an MSD
> bootloader would make life so much easier for the end user.
>
> I'm trying to use the same hardware configuration as the OP, and I
> am seeing the same behavior.
> at90usb162 Very basic hardware that's been working for years with
> other LUFA code on it.
>
> Drive enumerates / drops off. Repeats. (winxp, on two different
> boxes)
> Tried with your precompiled .hex Double checked the fuses, the
> fuses look good to me.
> Same behavior.
>
> The code does seem to work on some similar hardware, but with an
> mega16u4.
> Just seems to an issue on the smaller parts.
>
> Any other suggestions on things to check?
>
> Thanks,
>
> -carl
>
>
>
>
>
>
>
>
>
>
> On Monday, June 17, 2013 2:07:11 AM UTC-4, Dean Camera wrote:
>
> Gobi,
>
> Let's rule out toolchain issues first. Can you please try the
> precompiled bootloader here:
>
> *F_USB of 16MHz:*
> http://fourwalledcubicle.com/files/LUFA/Bootloaders/MassStorage/MassStorage-AVR8-at90usb162-BOARD_NONE-BOOT_4KB-16MHz.hex
> <http://fourwalledcubicle.com/files/LUFA/Bootloaders/MassStorage/MassStorage-AVR8-at90usb162-BOARD_NONE-BOOT_4KB-16MHz.hex>
>
> *F_USB of 8MHz:*
> http://fourwalledcubicle.com/files/LUFA/Bootloaders/MassStorage/MassStorage-AVR8-at90usb162-BOARD_NONE-BOOT_4KB-8MHz.hex
> <javascript:>.
> To post to this group, send email to
> lufa-s...@googlegroups.com <javascript:>.
> <http://groups.google.com/group/lufa-support>.
> For more options, visit
> https://groups.google.com/groups/opt_out
> <https://groups.google.com/groups/opt_out>.

Dean Camera

unread,
Jul 6, 2013, 6:43:13 AM7/6/13
to lufa-s...@googlegroups.com
Yes, it's a RAM issue, since the bootloader needs to buffer a full sector (512 bytes) before sending it to the host, and those devices only have 512 bytes of RAM total. I'm going to have to mark them as unsupported for now.

- Dean

H. Carl Ott

unread,
Jul 6, 2013, 7:36:11 AM7/6/13
to lufa-s...@googlegroups.com
That would certainly explain it.   
     Thanks for looking into it so quickly. 

 I can easily just go to an m32u2 for my particular app. 1k of ram.


-carl

 

carl
--------------------------------------------------------
Henry Carl Ott   N2RVQ    hcar...@gmail.com
Reply all
Reply to author
Forward
0 new messages