Re: PIC24FJ256GA106 flash write
0xFF means that it is erased.
Sounds like nothing was written.
What makes you think that un-initialized data will
"I expected to read 0 (zero) but the memory was filled with 0xff"
Something you've done wrong.
Why not read the datasheet?
Anyhow, it's line 256.