I am having problems programming with uisp. I am using Blink for testing.

I have a MIB510 and a board that we designed that is based on the mica2.

Once I have programmed the ATMEGA128 I cannot reprogram it. It goes through all the correct actions, but the program doesn't seem to change (tested by changing the blinking LED) With a bit of playing around I discovered that I can get it to program after I change the fuse high byte to 0x98 (from 0xd8 set by uisp). This turns on the 'enable JTAG' option (even though I don't have the JTAG plugged in) then it works. Another problem is that when I issue a 'rd-fuses' command it will quite often return all 0s (or give some other error message), also the wr_fuses_h command usually takes about 5 attempts until it does actually change the fuses (checked using rd_fuses). Once it has changed the fuse to 0x98 then rd_fuses will work reliably and I can upload my program. I have also tried other combinations for fuses (like 0x19) and it seems that whenever the 'enable JTAG' option is on it will work. Does anyone have any idea why this might be or what might be wrong here? I have been able to replicate this problem on 2 boards now (I have only built 2 so far).

Perhaps I should try changing the makefile so that uisp always enables JTAG, but this seems like a bit of a workaround problem, since normal mica2s seem to work OK.

Anothter note: It also seems that I can't program a fresh ATMEGA with uisp until I have plugged in a JTAG and changed the fuses to 0xfd (e) 0x19 (h) 0xfe (l). Is this normal? I was thinking that perhaps this is done by Crossbow before the motes leave the factory.

Thanks for your help.

Simon

--
Simon Willis    BE(CompSys)(Hons)-BSc           
PhD Candidate                           Tel: (07) 47814865
Electrical & Computer Engineering   Fax: (07) 47815177
James Cook University                   Mob: 0403653055
Townsville, QLD         4811            Email: [EMAIL PROTECTED]
                                        Web: http://eng.jcu.edu.au

_______________________________________________
Tinyos-help mailing list
[email protected]
https://mail.millennium.berkeley.edu/cgi-bin/mailman/listinfo/tinyos-help

Reply via email to