Call SPI.beginTransaction() after SPI.begin()

This commit is contained in:
Peter Van Hoyweghen 2015-07-28 22:26:58 +02:00
parent 89184a3668
commit 8d95899450
1 changed files with 1 additions and 1 deletions

View File

@ -176,7 +176,6 @@ static BitBangedSPI SPI;
void setup() {
SERIAL.begin(19200);
SPI.beginTransaction(SPISettings(SPI_CLOCK, MSBFIRST, SPI_MODE0));
pinMode(LED_PMODE, OUTPUT);
pulse(LED_PMODE, 2);
@ -360,6 +359,7 @@ void set_parameters() {
void start_pmode() {
SPI.begin();
SPI.beginTransaction(SPISettings(SPI_CLOCK, MSBFIRST, SPI_MODE0));
// SPI.begin() has configured SS as output,
// so SPI master mode is selected.
// We have defined RESET as pin 10,