diff options
| author | Damien George <damien@micropython.org> | 2023-11-24 11:46:54 +1100 |
|---|---|---|
| committer | Damien George <damien@micropython.org> | 2023-11-30 16:11:11 +1100 |
| commit | 7b2f13fb69d95980c8e517d1944bc1e9d7ed5489 (patch) | |
| tree | 8e9004498622320c6a88b6aa6bba35bfa9c2e653 | |
| parent | e120c00c9590b5691a8a4560382ad70ffb7a1c5d (diff) | |
renesas-ra: Consolidate MICROPY_PY_MACHINE_I2C option.
MICROPY_HW_ENABLE_HW_I2C and MICROPY_PY_MACHINE_I2C are equivalent, so
just use the latter.
Signed-off-by: Damien George <damien@micropython.org>
| -rw-r--r-- | ports/renesas-ra/machine_i2c.c | 4 | ||||
| -rw-r--r-- | ports/renesas-ra/mpconfigboard_common.h | 4 | ||||
| -rw-r--r-- | ports/renesas-ra/mpconfigport.h | 1 |
3 files changed, 4 insertions, 5 deletions
diff --git a/ports/renesas-ra/machine_i2c.c b/ports/renesas-ra/machine_i2c.c index 0e2d62f8a..dc14be959 100644 --- a/ports/renesas-ra/machine_i2c.c +++ b/ports/renesas-ra/machine_i2c.c @@ -35,7 +35,7 @@ #include "ra_i2c.h" -#if MICROPY_HW_ENABLE_HW_I2C +#if MICROPY_PY_MACHINE_I2C #define DEFAULT_I2C_FREQ (400000) #define DEFAULT_I2C_TIMEOUT (1000) @@ -165,4 +165,4 @@ MP_DEFINE_CONST_OBJ_TYPE( protocol, &machine_i2c_p ); -#endif // MICROPY_HW_ENABLE_HW_I2C +#endif // MICROPY_PY_MACHINE_I2C diff --git a/ports/renesas-ra/mpconfigboard_common.h b/ports/renesas-ra/mpconfigboard_common.h index f8990f489..479c9f61d 100644 --- a/ports/renesas-ra/mpconfigboard_common.h +++ b/ports/renesas-ra/mpconfigboard_common.h @@ -256,9 +256,9 @@ // Enable hardware I2C if there are any peripherals defined #if defined(MICROPY_HW_I2C0_SCL) || defined(MICROPY_HW_I2C1_SCL) \ || defined(MICROPY_HW_I2C2_SCL) -#define MICROPY_HW_ENABLE_HW_I2C (1) +#define MICROPY_PY_MACHINE_I2C (1) #else -#define MICROPY_HW_ENABLE_HW_I2C (0) +#define MICROPY_PY_MACHINE_I2C (0) #endif #if defined(MICROPY_HW_PWM_0A) || defined(MICROPY_HW_PWM_0B) \ diff --git a/ports/renesas-ra/mpconfigport.h b/ports/renesas-ra/mpconfigport.h index 222d5b919..94e07b339 100644 --- a/ports/renesas-ra/mpconfigport.h +++ b/ports/renesas-ra/mpconfigport.h @@ -138,7 +138,6 @@ #endif #define MICROPY_PY_MACHINE_PULSE (1) #define MICROPY_PY_MACHINE_PIN_MAKE_NEW mp_pin_make_new -#define MICROPY_PY_MACHINE_I2C (1) #define MICROPY_PY_MACHINE_SOFTI2C (1) #define MICROPY_PY_MACHINE_SPI (1) #define MICROPY_PY_MACHINE_SPI_MSB (SPI_FIRSTBIT_MSB) |
