diff options
| author | Damien George <damien@micropython.org> | 2021-09-02 12:37:00 +1000 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2021-09-02 13:11:23 +1000 |
| commit | 122d901ef1b624c26771532cb4725eaa8f85e0f4 (patch) | |
| tree | 7754e525b9cbf33c21e02029c69602ecd0833a65 /py | |
| parent | 7c54b6428058a236b8a48c93c255948ece7e718b (diff) | |
extmod/machine_i2c: Make SoftI2C configurable via macro option.
The zephyr port doesn't support SoftI2C so it's not enabled, and the legacy
I2C constructor check can be removed.
Signed-off-by: Damien George <damien@micropython.org>
Diffstat (limited to 'py')
| -rw-r--r-- | py/mpconfig.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/py/mpconfig.h b/py/mpconfig.h index 71440da39..cc302c3cb 100644 --- a/py/mpconfig.h +++ b/py/mpconfig.h @@ -1485,6 +1485,11 @@ typedef double mp_float_t; #define MICROPY_PY_MACHINE_I2C (0) #endif +// Whether to provide the "machine.SoftI2C" class +#ifndef MICROPY_PY_MACHINE_SOFTI2C +#define MICROPY_PY_MACHINE_SOFTI2C (0) +#endif + #ifndef MICROPY_PY_MACHINE_SPI #define MICROPY_PY_MACHINE_SPI (0) #endif |
