From: Enrico on 9 Jul 2010 08:03 Hi, I'm designing a board with an ARM controller and I need to store a unique ID (32 bit integer) in the application. Are there any ways to do it? They told me that some flashers are able to modify the .s19/.elf executable file just before programming the flash. Is that true? Ciao, Enrico
From: Steve Schefter on 9 Jul 2010 08:15 Hi Enrico. > I'm designing a board with an ARM controller and I need to store a > unique ID (32 bit integer) in the application. > > Are there any ways to do it? > > They told me that some flashers are able to modify the .s19/.elf > executable file just before programming the flash. > Is that true? Certainly modifying the .elf is doable. However, you'll end up with a system that can not have the program upgraded, except with a customized binary. If you haven't already done so, I'd suggest taking a close look at the ARM chip you are using first. Some have a small section of flash built in, intended for just such a purpose. Steve
From: Enrico on 9 Jul 2010 08:36 Hi Steve, > Certainly modifying the .elf is doable. However, you'll end up with a > system that can not have the program upgraded, except with a > customized binary. Thanks for pointing that out. > If you haven't already done so, I'd suggest taking a close look at the > ARM chip you are using first. Some have a small section of flash > built in, intended for just such a purpose. > > Steve Yes, I got plenty of flash, but I don't know how to use it for such a purpose. The boards are programmed by a non technical person, that is, he only has to press a button. Ciao, Enrico
From: Steve Schefter on 9 Jul 2010 08:53 Hi Enrico. > Yes, I got plenty of flash, but I don't know how to use it for such a > purpose. How do you get the .elf in place? If you want to use the same flash for the unique ID as for the program binary, I'd suggest dividing up the flash into partitions. The program can read the partition with the ID, whether that is in a file on a filesystem or just a raw flash block. I do that sort of thing using the boot loader. What boot loader are you using? Since you mention a .elf, I assume you have a boot loader. > The boards are programmed by a non technical person, that is, he only > has to press a button. That sounds like a job for a send/expect script interacting with the boot loader. Regards, Steve
From: Rich Webb on 9 Jul 2010 08:49 On Fri, 9 Jul 2010 05:03:30 -0700 (PDT), Enrico <zigbee(a)libero.it> wrote: >Hi, > > I'm designing a board with an ARM controller and I need to store a >unique ID (32 bit integer) in the application. > > Are there any ways to do it? > >They told me that some flashers are able to modify the .s19/.elf >executable file just before programming the flash. >Is that true? I've done something similar to this to embed a CRC into the flash. Essentially it involves (1) convert the hex to bin, (2) CRC the bin, (3) stick the resulting value in the appropriate spot in the bin, and then (4) convert the bin to hex. Subsequently, the normal flash loader burns the flash and the resulting code can now run a CRC on "itself" and get a proper result. The debug file that matches source code line to flash address is none the wiser, so JTAG debugging can continue unaffected. With the steps above added to the Makefile, it all just happens automatically with each build. The details of will vary with the toolchain and target but the general outline should be do-able. -- Rich Webb Norfolk, VA
|
Next
|
Last
Pages: 1 2 3 Prev: New Era Hats ( www.nike-black.com ) Next: Documentation shortcomings |