> Another aproach would be to put the bootloader at the top of the code and > just jump straight to it from the reset vector, write your bootloader so > that this address cannot be modified, as well as making sure your bootloader > can't be modified. Then you have complete freedom with interrupt routines, > I would think is a better approach in terms of flexibility. That's what I do on PICs. Another wrinkle is you have to think about what happens if an upload is interrupted in the middle or gets a data error. A single flag only distiguishes between never uploaded and uploaded at least once. My uploader computes the checksum of the uploaded code and passes that to the bootloader at the end, which the bootloader saves. On startup, control is always given to the bootloader, which only runs the application firmware if its checksum matches the stored value. If not, the bootloader retains control and waits for a new upload. ***************************************************************** Embed Inc, embedded system specialists in Littleton Massachusetts (978) 742-9014, http://www.embedinc.com -- http://www.piclist.com#nomail Going offline? Don't AutoReply us! email listserv@mitvma.mit.edu with SET PICList DIGEST in the body