[avr-gcc-list] Auto write calibration bytes
Hi, I'm using AVRdude. While programming, I'm trying to retreive, and then write into the 1st 4 eeprom locations,, the calibration bytes. The device gets programmed. Also the the calibration bytes are read to the specifie file, but fails while writing to eeprom. The command line, subsequent avrdude reply is reproduced below. The programmer is set to usbasp (default). How best to acheive this ? Thanks. - avrdude -p m32 -u -V -U logger-6pt.hex -U libration:r:calib.hex:i -Ueeprom:w:calib.hex:i -U lfuse:w:0x22:m -U hfuse:w:0xd9:m -U lock:w:0x3c:m found 2 busses avrdude: AVR device initialized and ready to accept instructions Reading | ## | 100% 0.02s avrdude: Device signature = 0x1e9502 avrdude: NOTE: FLASH memory has been specified, an erase cycle will be performed To disable this feature, specify the -D option. avrdude: current erase-rewrite cycle count is -50462977 (if being tracked) avrdude: erasing chip avrdude: reading input file logger-6pt.hex avrdude: input file logger-6pt.hex auto detected as Intel Hex avrdude: writing flash (16452 bytes): Writing | ## | 100% 132.27s avrdude: 16452 bytes of flash written avrdude: reading calibration memory: Reading | ## | 100% 0.02s avrdude: writing output file calib.hex avrdude: reading input file calib.hex avrdude: WARNING: no end of file record found for Intel Hex file calib.hex avrdude: writing eeprom (0 bytes): ---The error I get. Writing | ## | 100% 0.00s avrdude: 0 bytes of eeprom written avrdude: reading input file 0x22 avrdude: writing lfuse (1 bytes): Writing | ## | 100% 0.02s avrdude: 1 bytes of lfuse written avrdude: reading input file 0xd9 avrdude: writing hfuse (1 bytes): Writing | ## | 100% 0.00s avrdude: 1 bytes of hfuse written avrdude: reading input file 0x3c avrdude: writing lock (1 bytes): Writing | ## | 100% 0.02s avrdude: 1 bytes of lock written avrdude done. Thank you. Thanks regards, --Royce. ___ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list
Re: [avr-gcc-list] Re: [avr-libc-dev] Constant address to programmemory in C
On Nov 23, 2007 10:21 AM, Weddington, Eric [EMAIL PROTECTED] wrote: ... This rather smells like a compiler bug to me, than something where library support would be a real help. If the compiler offers the feature to jump to an arbitrary address using goto, then it's responsible to translate that code into whatever is necessary to accomplish the goal. The tools always and only count in byte addresses. I agree. Unfortunately, there's a bunch of code out there now that assumes goto *x needs to be fixed up with a goto *(x/2). There is already a GCC bug filed for the above problem. Great! Do you know the bug number? I searched GCC's bugzilla for `Host contains the string avr' and found `Zarro Boogs'. The search form seems a little busted, or perhaps just unusable. Cheers, Shaun ___ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list
RE: [avr-gcc-list] Re: [avr-libc-dev] Constant address to programmemory in C
-Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] org] On Behalf Of Shaun Jackman Sent: Thursday, November 22, 2007 1:57 PM To: Joerg Wunsch; avr-gcc-list@nongnu.org Subject: [avr-gcc-list] Re: [avr-libc-dev] Constant address to programmemory in C On Nov 22, 2007 1:44 PM, Joerg Wunsch [EMAIL PROTECTED] wrote: As Shaun Jackman wrote: The assembler has a pm(a) operator for this very reason. It would be useful for avr-libc to have a similar macro. This rather smells like a compiler bug to me, than something where library support would be a real help. If the compiler offers the feature to jump to an arbitrary address using goto, then it's responsible to translate that code into whatever is necessary to accomplish the goal. The tools always and only count in byte addresses. I agree. Unfortunately, there's a bunch of code out there now that assumes goto *x needs to be fixed up with a goto *(x/2). There is already a GCC bug filed for the above problem. Eric Weddington ___ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list
Re: [avr-gcc-list] Intel hex record types
Scott Morken schreef: What do we do for AVR architecture? I would also be interested in any other possible record types output by AVRGCC if anyone knows. Take a look at s-rec or s-record, it comes with the WinAVR releases. It can almost convert anything to anything. HTH Wouter ___ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list
[avr-gcc-list] Intel hex record types
Hi, I am working on an Intel hex file converter and I am wondering about record types for avr-gcc ihex output. In an ihex file I generated (for a bootloader) this line exists at second to bottom: :0403700089 The record type here is 03, and I can't figure out what it means. According to wikipedia http://en.wikipedia.org/wiki/Intel_HEX :* [record type] 03*, /Start Segment Address Record/. For 80x86 processors, it specifies the initial content of the CS:IP registers. The address field is , the byte count is 04, the first two bytes are the CS http://en.wikipedia.org/wiki/Code_segment value, the latter two are the IP http://en.wikipedia.org/wiki/Instruction_pointer value. What do we do for AVR architecture? I would also be interested in any other possible record types output by AVRGCC if anyone knows. Scott Morken ___ AVR-GCC-list mailing list AVR-GCC-list@nongnu.org http://lists.nongnu.org/mailman/listinfo/avr-gcc-list