diff options
author | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2016-09-04 20:33:11 +0300 |
---|---|---|
committer | Paul Sokolovsky <pfalcon@users.sourceforge.net> | 2016-09-04 20:33:11 +0300 |
commit | dba40afa706a1ac4b102dceba217844dc1540ce7 (patch) | |
tree | 5f423c2d7a4a1c3245a8d0654d26f61babd5238e /esp8266/modmachine.c | |
parent | 7ddd1a58f6ec90a35e2ca815f62358acfb801c52 (diff) | |
download | micropython-dba40afa706a1ac4b102dceba217844dc1540ce7.tar.gz micropython-dba40afa706a1ac4b102dceba217844dc1540ce7.zip |
esp8266/modmachine: Simplify SPI class implementation multiplexing.
modpybhspi now does the needed multiplexing, calling out to modpybspi
(bitbanging SPI) for suitable peripheral ID's. modmachinespi (previous
multiplexer class) thus not needed and removed.
modpybhspi also updated to following standard SPI peripheral naming:
SPI0 is used for FlashROM and thus not supported so far. SPI1 is available
for users, and thus needs to be instantiated as:
spi = machine.SPI(1, ...)
Diffstat (limited to 'esp8266/modmachine.c')
-rw-r--r-- | esp8266/modmachine.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/esp8266/modmachine.c b/esp8266/modmachine.c index a6d5fc3dbb..df1ae0fcf6 100644 --- a/esp8266/modmachine.c +++ b/esp8266/modmachine.c @@ -254,7 +254,7 @@ STATIC const mp_rom_map_elem_t machine_module_globals_table[] = { { MP_ROM_QSTR(MP_QSTR_ADC), MP_ROM_PTR(&pyb_adc_type) }, { MP_ROM_QSTR(MP_QSTR_UART), MP_ROM_PTR(&pyb_uart_type) }, { MP_ROM_QSTR(MP_QSTR_I2C), MP_ROM_PTR(&machine_i2c_type) }, - { MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&machine_spi_type) }, + { MP_ROM_QSTR(MP_QSTR_SPI), MP_ROM_PTR(&pyb_hspi_type) }, // wake abilities { MP_ROM_QSTR(MP_QSTR_DEEPSLEEP), MP_ROM_INT(MACHINE_WAKE_DEEPSLEEP) }, |