Ah, looks like I had ihex and srec reversed...
I've managed to scrod up my mica dev system by
overloading Boomerang and then Moteworks for
other platforms so I couldn't try a compile
to see what happens...

Do you know of any doc on the actual TOS link and
download process? or is the atmega boot loader page
the best we can do?

Good point about the config switches.

thx
MS

Razvan Musaloiu-E. wrote:
> Hi!
> 
> On Sun, 12 Jul 2009, Michael Schippling wrote:
> 
>> I think the srec file is an intermediate between .exe and .ihex.
> 
> The ihex and srec are in fact equivalent. In the default configuration 
> for MIB510/MIB520 the uisp and the srec are used.
> 
>> Examine the make output carefully and you may find the command
>> line that does the conversion. It looks like a differently abled
>> download format.
>>
>> One thing that might be a problem is that I believe there is a
>> boot loader of some kind on the micas, so the download code may
>> not actually contain a reset vector. Without a major reverse
>> engineering effort I'm not sure how I would go about validating
>> this assertion however. Many hex files have addresses as the
>> first element in the line, so examining the file format might
>> be a place to start.
> 
> A good reference about how booting take place is the 'Boot Loader 
> Support' section from the ATmega128 datasheet (page 273):
>     http://www.atmel.com/dyn/resources/prod_documents/doc2467.pdf
> 
> One quick thing to check is that you set the fuses in the same way as 
> TinyOS. The fuse high byte is set to 0xd9 and the fuse extended byte is 
> set to 0xff. Here is exact uisp command used for MIB510/MIB520:
>     uisp -dprog=mib510 -dserial=/dev/ttyUSB0 --wr_fuse_h=0xd9 
> -dpart=ATmega128 --wr_fuse_e=ff --erase --upload 
> if=build/micaz/main.srec.out --verify
> 
> All the best!
> Razvan ME
> 
>> farooq_s wrote:
>>> I am trying to program the atmega128 using tinyos. I have made the 
>>> platform
>>> similar to the micaz shemetic. However, when i run 'make micaz' to 
>>> compile
>>> the blink application, two files main.ihex and main.srec are 
>>> generated. I
>>> tried downloading the main.ihex file using the avrdude and avrisp mkII
>>> programmer, the download is successfull but the blink doesnt function.
>>>
>>> Moreover i also want to know whats the function of main.srec file?
>>>
>>> Also, am i doing the correct procedure by downloading the main.ihex file
>>> using avrdude?
>>>
>>> Kindly help me in this regard.
>>>
>>> farooq
>>
_______________________________________________
Tinyos-help mailing list
[email protected]
https://www.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to