set SPI-master DataMode and BitOrder
Posted: Fri Jul 03, 2020 7:29 am
Hi, using the SPI master function for programming an Arduino / ATMEGA328P, we would like to setup the SPI mode and Bitorder.
In the SPI Master component found no settings for this, and copying the C-code from a arduino.INO file does not work because of missing SPI.library....
Like to set these 2 parameters:
SPI.setDataMode(SPI_MODE3);// When SCK is high, send/receive data, when idle, set pin to HIGH
SPI.setBitOrder(MSBFIRST);// Transmission from MSB
How can we do that?
Regards, Luuk Aalders
In the SPI Master component found no settings for this, and copying the C-code from a arduino.INO file does not work because of missing SPI.library....
Like to set these 2 parameters:
SPI.setDataMode(SPI_MODE3);// When SCK is high, send/receive data, when idle, set pin to HIGH
SPI.setBitOrder(MSBFIRST);// Transmission from MSB
How can we do that?
Regards, Luuk Aalders