Assuming it has writeable program memory (and I expect an 887 has) then you do it the same way as any other write to program memory. However, why are you wanting to use I2C to do it? - it seems a bit obscure?.
Flash program memory may only be written to if the
destination address is in a segment of memory that is
not write-protected, as defined in bits WRT<1:0> of the
Configuration Word Register 2.
The datasheet of PIC16f887 states as above.
But how to access Configuration Word Register 2??????
Flash program memory may only be written to if the
destination address is in a segment of memory that is
not write-protected, as defined in bits WRT<1:0> of the
Configuration Word Register 2.
The datasheet of PIC16f887 states as above.
But how to access Configuration Word Register 2??????