mirror of
https://github.com/esp8266/Arduino.git
synced 2025-10-25 18:38:07 +03:00
SPISlave.end() added (#4248)
* Change argument to Esp.deepSleep from uint32 to uint64 to match SDK, add deepSleepMax based on the cali_proc function per SDK * SPISlave.end() added * Nameoftherose patch for Issue #2435 (#4256) * WiFiTelnetToSerial Example - Minor Issues #2435 * WiFiTelnetToSerial Example - Minor Issues #2435 Patch to rectify issue #2435 * Check that pins needed by Wire are defined at compile-time (#4261)
This commit is contained in:
@@ -97,6 +97,23 @@ void hspi_slave_begin(uint8_t status_len, void * arg)
|
||||
ETS_SPI_INTR_ENABLE();
|
||||
}
|
||||
|
||||
void hspi_slave_end()
|
||||
{
|
||||
ETS_SPI_INTR_DISABLE();
|
||||
ETS_SPI_INTR_ATTACH(NULL, NULL);
|
||||
|
||||
pinMode(SS, INPUT);
|
||||
pinMode(SCK, INPUT);
|
||||
pinMode(MISO, INPUT);
|
||||
pinMode(MOSI, INPUT);
|
||||
|
||||
// defaults
|
||||
SPI1S = 0;
|
||||
SPI1U = SPIUSSE | SPIUCOMMAND;
|
||||
SPI1S1 = 0;
|
||||
SPI1P = B110;
|
||||
}
|
||||
|
||||
void hspi_slave_setStatus(uint32_t status)
|
||||
{
|
||||
SPI1WS = status;
|
||||
|
||||
Reference in New Issue
Block a user