BE aware of new bug found for these chips using the slave hardware spi port 1 (MSSP1) on these chips ,
i reported issues some months back to microchip , looks like there was more to it


snipit from latest errata

Name:  spi bug.JPG
Views: 215
Size:  29.5 KB