Perhaps someone can tell me why the line "while(EE_busy & 0x01);" is not compiled? volatile UINT8 EE_busy; EE_busy = 0x01; do EE_busy = hs_NvmRDSR(); while(EE_busy & 0x01); Thanks Rich
It is notoriously difficult for a source-level debugger to be 100% correct in identifying the C source line for a given instruction after the optimizer is done rearranging code, as well as eliminating it. Optimization is not quite as simple as completely eliminating individual lines in the C source. After optimization, a particular single instruction might "belong" to many lines of source, or even directly to none. The usual two options for dealing with this problem are to build the code without optimization, or to switch to assembly-level debugging in the problem spots. Does the code work correctly? Can you post the generated assembly code for this snippet?