Helpful ReplyUSB Thumbdrive Bootloader (BETA 1)

Page: < 123 Showing page 3 of 3
Author
FAbengal
New Member
  • Total Posts : 14
  • Reward points : 0
  • Joined: 2010/03/31 01:49:14
  • Location: 0
  • Status: offline
RE: USB Thumbdrive Bootloader (BETA 1) 2010/04/01 00:15:04 (permalink)
0
thank for your reply.

I'll ask microchip support and see what happen..

#41
dominique.junk
New Member
  • Total Posts : 10
  • Reward points : 0
  • Joined: 2009/03/13 09:53:58
  • Location: 0
  • Status: offline
RE: USB Thumbdrive Bootloader (BETA 1) 2010/05/12 02:34:38 (permalink)
0
hi all, my post with a lot of delay.
I confirm the bug in AddToBlock, and I confirm that the version brought by jtoebes works for me!
My thanks in jtoebes!
#42
firmwaregirl
New Member
  • Total Posts : 7
  • Reward points : 0
  • Joined: 2008/10/14 12:05:00
  • Location: 0
  • Status: offline
Re:USB Thumbdrive Bootloader (BETA 1) 2010/09/14 15:57:39 (permalink)
0
Yeah! Just see that there is a new release 8/4/2010
 
Thanks Microchip!
 
 
Hi,
I am trying to come up with a USB Host bootloader that can perform firmware upgrades using a thumbdrive.
This is a beta version posted 11/12/2008. Now it's 9/14/2010, has there been a final release?
 
Excuse my embarrassing newbiness, but when I build this beta (even with optimizations) it is 50k, much bigger than the 12k alloted to boot Flash. does this bootloader use part of application Flash?
 
Thanks!
post edited by firmwaregirl - 2010/09/14 16:08:40
#43
ricard
Starting Member
  • Total Posts : 31
  • Reward points : 0
  • Joined: 2010/08/14 07:47:25
  • Location: 0
  • Status: offline
Re:USB Thumbdrive Bootloader (BETA 1) 2010/09/21 01:53:47 (permalink)
0
Hello,

I tried this last release but I can't get it work...

Before, I tried succesfully to adapt the Explorer16 'USB Device HID Bootloader' demo to my Pic32 Starter Kit. It works perfect even if the image uses interrupts, TCP/IP, ECAN, WiFi, etc..

But when I try to run the Host Bootloader (ready for Pic32 Starter Kit) the image never starts. I'm testing a simple led blinking program.

I linked the aplication using 'elf32pic32mx MSD Boot' (this includes the file 'MSD_Boot.ld' for my processor)  previously copied to the aplication folder.

I linked the boot using 'elf32pic32mx.ld' (this includes 'procdefs.ld')

All compiles perfect. The image loads perfect:
***** Reset *****
Loading new application image
Transport initialized
Application image file has been found
Application image has been programmed
Launching application

But the image never launches...

Any suggestions?

Many thanks,

Ricard.
#44
Link
Starting Member
  • Total Posts : 81
  • Reward points : 0
  • Status: offline
Re:USB Thumbdrive Bootloader (BETA 1) 2010/09/21 04:02:30 (permalink)
0
 Try checking the map of the compiled application component to see if it squares up with what the bootloader linker script(s) are expecting.

 Have you set a breakpoint at the APPLICATION_START address? If so, what is there? If the code expected appears to be all present and correct I would suspect any (re)initialisation within the app component remembering that it isn't actually running from a cold start which can mask initialisation problems.

#45
ricard
Starting Member
  • Total Posts : 31
  • Reward points : 0
  • Joined: 2010/08/14 07:47:25
  • Location: 0
  • Status: offline
Re:USB Thumbdrive Bootloader (BETA 1) 2010/09/21 04:06:18 (permalink)
0
I found the problem:

The 'MSD_Boot.ld' file provided for 32MX795F512L points to:
 _RESET_ADDR = 0x9D00F000;

But the 'boot_config.h' points to:
#define APPLICATION_ADDRESS         0x9D00E000

I pointed APPLICATION_ADDRESS to  0x9D00F000 in  'boot_config.h'  and now it works perfect.

Many thanks!

Ricard.
post edited by ricard - 2010/09/21 04:22:54
#46
Stajda
New Member
  • Total Posts : 1
  • Reward points : 0
  • Joined: 2011/03/09 04:15:50
  • Location: 0
  • Status: offline
Re:USB Thumbdrive Bootloader (BETA 1) 2011/03/09 05:24:40 (permalink)
0
Hi,

I have USB Host Bootloader edited by John Toebes from first page (thanks). Everything works OK - bootloader apps and target apps too. But if I load application with TCP/IP stack, the app start correctly, but immediate freeze.
I use PIC32MX675F512L with latest USB and TCP/IP stack - without bootloader is everything OK, if I comment TCP application in my code with bootloader then it is OK too.

I read, that there is a problem with use USB stack and TCP/IP stack together: http://www.microchip.com/forums/tm.aspx?m=49543, but I don't know where.

Any idea to solve this problem?
#47
jetcode
Super Member
  • Total Posts : 886
  • Reward points : 0
  • Joined: 2004/06/19 09:45:59
  • Location: San Geronimo Valley
  • Status: offline
Re: RE: USB Thumbdrive Bootloader (BETA 1) 2011/04/28 10:58:32 (permalink)
0
John big thanks. I have written a SD bootloader but have not had an easy go of modifying the linker script. It would have been helpful to find the linker manual for the C32. Nevertheless your linker scripts are valuable in giving the community some insight into memory management on 32 bit devices.

#48
jsbrodhead
New Member
  • Total Posts : 20
  • Reward points : 0
  • Joined: 2011/10/03 19:55:32
  • Location: 0
  • Status: offline
RE: USB Thumbdrive Bootloader (BETA 1) 2013/07/13 02:39:48 (permalink)
0
Current link:  http://john.toebes.com/pr...first/46-samantha.html
Page down (about 3 pages) to "Other Downloads"
 
THX John
 
Smile
#49
RISC
Super Member
  • Total Posts : 4635
  • Reward points : 0
  • Status: offline
RE: USB Thumbdrive Bootloader (BETA 1) 2013/10/05 02:39:35 (permalink) ☄ Helpfulby m4l490n 2014/07/01 10:15:29
5 (1)
Hi,
 
Please note that USB thumbdrive bootloader is officially supported and included in Microchip libraries : http://www.microchip.com/MLA
After installation, look into this folder : c:\microchip_solutions_v2013-06-15\USB\Host - Bootloaders\
 
regards
post edited by RISC - 2013/10/05 02:43:30
#50
caressor
New Member
  • Total Posts : 15
  • Reward points : 0
  • Joined: 2016/06/06 04:24:48
  • Location: 0
  • Status: offline
Re: USB Thumbdrive Bootloader (BETA 1) 2016/09/26 08:23:42 (permalink)
0
Dear members,
 
I tried the example and after adaptions it finally runs with my PIC32MX230F256B.
 
BUT it only works with the original "image.hex"-applications that are included in the example-project.
 
When I try to load my own applications (a small one with 13KB and a big one with 283KB size of hex-file size) it always runs into an runtime exeption in function "BLMedia_LoadFile" at the line "Loader_GetFlashBlock(...".
 
In other posts there were notes and advices about adaptions of the defines in "boot_config.h" for APPLICATION_ADDRESS, PROGRAM_FLASH_BASE, PROGRAM_FLASH_LENGTH and FLASH_BLOCK_SIZE in combination with the ".map"-file and even remarks to a linker file ".ld".
 
I've tried a few helpless changes in the defines, but it didn't work and I honestly didn't really understand from where I can get the correct settings to load my own application with the bootloader.
 
Do I need/create a ".ld"-file?
What settings do I have to make in "boot_config.h"? And from where can I get them?
Do I have to build my application in a special way to load it with the bootloader?
 
I will upload all the information you need, if s.o. wants to help me please.
 
Best regards
#51
NKurzman
A Guy on the Net
  • Total Posts : 15093
  • Reward points : 0
  • Joined: 2008/01/16 19:33:48
  • Location: 0
  • Status: online
Re: USB Thumbdrive Bootloader (BETA 1) 2016/09/26 08:30:22 (permalink)
3 (1)
The appication must be built with a proper linker script to match the boot loader.
#52
caressor
New Member
  • Total Posts : 15
  • Reward points : 0
  • Joined: 2016/06/06 04:24:48
  • Location: 0
  • Status: offline
Re: USB Thumbdrive Bootloader (BETA 1) 2016/09/28 05:29:24 (permalink)
0
Thank you!
 
Now I build my application with a procdefs.ld but it crashes again after a few load-cycles.
I'm not sure the settings in my procdefs.ld and in the boot_config.h are really correct, here they are:
 
procdefs.ld:
/*************************************************************************
 * For interrupt vector handling
 *************************************************************************/
PROVIDE(_vector_spacing = 0x00000001);
_ebase_address  = 0x9D021000;

/*************************************************************************
 * Memory Address Equates
 *************************************************************************/
_RESET_ADDR              = 0x9D020000;
_BEV_EXCPT_ADDR          = 0x9D020380;
_DBG_EXCPT_ADDR          = 0x9D020480;
_DBG_CODE_ADDR           = 0xBFC02000;
_GEN_EXCPT_ADDR          = _ebase_address + 0x180;

/*************************************************************************
 * Memory Regions
 *
 * Memory regions without attributes cannot be used for orphaned sections.
 * Only sections specifically assigned to these regions can be allocated
 * into these regions.
 *************************************************************************/
MEMORY
{
  kseg0_program_mem    (rx)  : ORIGIN = 0x9D022000, LENGTH = 0x1E000
  kseg0_boot_mem             : ORIGIN = 0x9D020490, LENGTH = 0xB70
  exception_mem              : ORIGIN = 0x9D021000, LENGTH = 0x1000
  kseg1_boot_mem             : ORIGIN = 0x9D020000, LENGTH = 0x490
  kseg1_data_mem       (w!x) : ORIGIN = 0xA0000000, LENGTH = 0x8000
  sfrs                       : ORIGIN = 0xBF800000, LENGTH = 0x100000
}
 
- boot_config.h
// Address of main application's Startup code
#define APPLICATION_ADDRESS         0x9D020000

#define PROGRAM_FLASH_BASE          0x1D000000  // Physical address
#define PROGRAM_FLASH_LENGTH        0x00040000  // Length in bytes
#define FLASH_BLOCK_SIZE            (1024 * 4)  // Size in bytes
#endif


Anybody who can tell me please what is wrong?
Or please tell me how to know the correct settings?
#53
Page: < 123 Showing page 3 of 3
Jump to:
© 2017 APG vNext Commercial Version 4.5