[En-Nut-Discussion] Over-the-network upgrade of user code

Brett Abbott Brett.Abbott at digital-telemetry.com
Tue Aug 15 00:37:11 CEST 2006


Matthias,

We use the flash that comes with the Ethernut2 without issue so expect 
you can do as you propose with Ethernut3

The two risks as I see them are:
1. unreliable method of sending: If your method could be cut off half 
way through and be unrecoverable - avoid programming directly into flash 
- you need to be able to buffer your new program into serial flash 
rather than saving it directly into program memory flash in case it dies 
half way through and you cant go back and cant talk to home base anymore 
- if you can squeeze the full PPP into the bootloader this wouldnt be a 
problem but it really would be a squeeze!  Using the serial flash on the 
ethernut allows you to do this safely. 
2. unreliable data quality.  Some radio and comms channels are more 
reliable than others and it is possible that corruption can occur.  TCP 
has ok checksums as does PPP but they arent perfect.  You may wish to 
generate an additional checksum or quality checking protocol over your 
code once it is in the serial flash and compare that checksum to one 
generated at compile time.  This will reduce the chance of data 
communication glitches catching you out.

A lesser risk is corruption of flash or failure during programming.  You 
can mitigate this by keeping a before and after image in serial flash.  
If you have a fault during programming of the flash, you are likely to 
have bigger issues on your hand so keeping a before image is likely to 
be more of a management choice should you wish to "roll back" a change 
in a hurry.

Hope this helps
Brett

Matthias Wilde wrote:
> Hi all,
>
> regarding this network upgrade I have a further question:
>
> Before I read in this thread, that 
> it is recommended to use external flash, especially for unsafe 
> protocols like PPP. 
>
> In case of ethernut 3 would you recommend to use a 
> separate second flash or is it somehow possible to use something like 3 
> partitions in the existing flash? One Boot section, and something like 2 images, one last active running and the last for the new flashing update?
>
>
> Best regards 
>
> Matthias
>
>
>   

-- 
-----------------------------------------------------------------
Brett Abbott, Managing Director, Digital Telemetry Limited
Email: Brett.Abbott at digital-telemetry.com
PO Box 24 036 Manners Street, Wellington, New Zealand
Phone +64 (4) 5666-860  Mobile +64 (21) 656-144
------------------- Commercial in confidence --------------------





More information about the En-Nut-Discussion mailing list