SPI.begin

Name
SPI.begin

Description
Initiate an SPI communication instance. Not totally equivalent to SPI.init

Uses the global parameters:
 * this_mode--default value is SPI_MODE0 0x00. Modify it using SPI.setDataMode(u8 mode)
 * this_clock--default value is SPI_MASTER_FOSC_64 0x02. Modify it using SPI.setMode(u8 mode) or SPI.setClockDivider(u8 clock)
 * this_role--default value is SPI_CLOCK_DIV64 0x02. Modify it using SPI.setMode(u8 mode) or SPI.setClockDivider(u8 clock) N.B. this_clock and this role have the same value in Master Mode
 * this_bitorder--default value is SPI_MSBFIRST 1. Modify it using SPI.setBitOrder(u8 bitorder)
 * this_phase--default value is SPI_SMPEND 1<<7 . You can only alter it by changing the global value

Since some devices have multiple SPI modules, the SPI module must be specified even if the the device has only one module (e.g., 18F25K50 or 18F45K50).

Since Beta X

Syntax
SPI.begin(u8 module)

Example
void setup {     SPI.begin(SPI1) }