mirror of
https://github.com/esphome/esphome.git
synced 2024-11-26 08:55:22 +01:00
Fix RP2040 SPISettings (#3960)
This commit is contained in:
parent
0e30c49e3f
commit
bf4d3df906
1 changed files with 4 additions and 0 deletions
|
@ -225,7 +225,11 @@ class SPIComponent : public Component {
|
|||
} else if (CLOCK_POLARITY && CLOCK_PHASE) {
|
||||
data_mode = SPI_MODE3;
|
||||
}
|
||||
#ifdef USE_RP2040
|
||||
SPISettings settings(DATA_RATE, static_cast<BitOrder>(BIT_ORDER), data_mode);
|
||||
#else
|
||||
SPISettings settings(DATA_RATE, BIT_ORDER, data_mode);
|
||||
#endif
|
||||
this->hw_spi_->beginTransaction(settings);
|
||||
} else {
|
||||
#endif // USE_SPI_ARDUINO_BACKEND
|
||||
|
|
Loading…
Reference in a new issue