James Humes wrote: > org 4 > clrf PCLATH > goto reset > Calibration_Vector > org 6 > org 10 > retlw 0 > > The hex file is generated based on this, and then the calibration > values are inserted into the hex file in either program memory > location 6, 7, 8, or 9. .... When I assemble the code using MPLAB > 7.20 I get a hexfile that appears to have optimized out those empty > spaces. That makes the hex file's format different enough that our > program (that has been in constant use for 7 years) doesn't find > the correct place to insert the value. James: The Intel Hex format doesn't require each line's address to be higher than the one before... If the hex file doesn't already contain data for the address you want to patch, just add a new line to the end of the file that contains the data for that address. Put it just before the "00000001FF" termination record. -Andrew === Andrew Warren - fastfwd@ix.netcom.com -- http://www.piclist.com PIC/SX FAQ & list archive View/change your membership options at http://mailman.mit.edu/mailman/listinfo/piclist