On Monday 18 Apr 2005 10:43 pm, E. Weddington wrote: > Colin O'Flynn wrote: > >Hey, > > > >This is from a thread on AVRFreaks, and previous ideas bounced > > around. My idea is to create a unified AVR programming file format, > > possibly extensionable to work with any platform (ie: not only > > AVR). > > > >My basic idea was as follows: > > > >Have one .tar (possibly .tar.gz or .zip) format file, which a > > different extension. This would be done to ensure we know what it > > is really supposed to be, perhaps .ump (Unified Microcontroller > > Programming file) - this .ump extension doesn't seem to be too > > heavily used unlike most other extensions > > (http://www.rmspl.com.au/umatrix.htm is the only thing I could find > > that uses it) > > > >This file would have in it several separate files: > > > >--*.hex file <-- The AVR image file > >--*.fuse file <-- new text file with AVR fuse settings in it > >--*.txt file <-- text file with version information on the rest of > > the files, other notes > >--*.md5 file <-- md5sum of everything, save for the .md5 file of > > course > > > >You will see that everything could be done with normal utilities > > available on Linux - md5sum, tar, etc. This way the file format is > > as easy to work with as possible and you aren't locked into > > specific tools. > > > >As well to make "programs" that do stuff like verify the file's > > md5sum and generate a proper md5sum after you have modified the > > file would be simple shell scripts (on Linux/Unix anyway) which > > makes it easy to work with. In fact a wrapper for avrdude could > > probably be made which would extract the files, check them, then > > call avrdude as needed. > > > >What do you think? > > I think that this is very doable. > > For reference, IIRC Java .jar files are nothing more than a .zip file > that contains other files and has been renamed. This is what you are > proposing too. The zip format and libraries are available on both > *nix and Windows (as well as Cygwin). However, the Uniz zip *utility* > does not come with WinAVR, but, strangely enough, it does have bzip2. > > The program md5sum is available on WinAVR, so that covers the .md5 > file. The .txt file is written by the user. The .hex file is, of > course, generated by AVR GCC. The only thing really new would be the > .fuse file. In the -U swtich, we need to have something like > Immediate Mode (m) but the contents in a file. Implementing that > would probably not be hard.
I'm an AVR newbie here, so I might be talking out of my hat, (or somewhere else.) Is there not the possibility of multiple .hex files? I know that's how I program Flash and eeprom from gas-generated objects. Might it be a good idea to put a list of hex files and their targets into the .txt, or their own file. The fashionable way to do that would be XML; the parser is a large overhead when a simple text format would surfice, but it would make room for expansion. Something like (in XML for self-documentation): <file name="flash.hex" address="0x8000" label="flash"> textual description </file> You could encode other information in there for the microcontroller part number, the release number, the author and the copyright details. -- Richard Urwin _______________________________________________ AVR-chat mailing list [EMAIL PROTECTED] http://lists.nongnu.org/mailman/listinfo/avr-chat
