Select the transmit output pin by writing the appropriate values to the RxyPPS register
and RXxPPS register. Both selections should enable the same pin.
Select the clock output pin by writing
the appropriate values to the RxyPPS register and TXxPPS register. Both selections
should enable the same pin.
Enable the synchronous master serial port by setting bits SYNC, SPEN and CSRC.
Disable Receive mode by clearing the SREN and CREN bits.
If 9-bit transmission is desired, set the TX9
bit.
If interrupts are desired, set the TXxIE bit of the PIEx
register and the GIE and PEIE bits of the INTCON register.
If 9-bit transmission is selected, the ninth bit should be
loaded in the TX9D bit.
Start transmission by loading data to the TXxREG
register.
The online versions of the documents are provided as a courtesy. Verify all content and data in the device’s PDF documentation found on the device product page.