Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SPI API outdated #1

Open
Tom-AW opened this issue Mar 9, 2021 · 0 comments
Open

SPI API outdated #1

Tom-AW opened this issue Mar 9, 2021 · 0 comments
Assignees

Comments

@Tom-AW
Copy link

Tom-AW commented Mar 9, 2021

Hi, the arduino SPI API has changed and these lines in all 3 examples no longer work

 SPI.begin();
  SPI.setBitOrder(MSBFIRST);
  //CPOL = 0, CPHA = 1
  SPI.setDataMode(SPI_MODE1);
  // Selecting 1Mhz clock for SPI
  SPI.setClockDivider(SPI_CLOCK_DIV16);

They should be replaced with

  SPI.beginTransaction(SPISettings(1000000,MSBFIRST,SPI_MODE1));
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants