nrf5/pwm: Updating config name of PWM to hardware PWM to prepare for introduction of soft variant.
This commit is contained in:
parent
311ae77dc0
commit
10cbc83cf0
|
@ -30,7 +30,7 @@
|
|||
#define MICROPY_HW_MCU_NAME "NRF52832"
|
||||
#define MICROPY_PY_SYS_PLATFORM "nrf52"
|
||||
|
||||
#define MICROPY_PY_MACHINE_PWM (1)
|
||||
#define MICROPY_PY_MACHINE_HW_PWM (1)
|
||||
#define MICROPY_PY_MACHINE_HW_SPI (1)
|
||||
#define MICROPY_PY_MACHINE_TIMER (1)
|
||||
#define MICROPY_PY_MACHINE_RTC (1)
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
#define MICROPY_HW_MCU_NAME "NRF52832"
|
||||
#define MICROPY_PY_SYS_PLATFORM "nrf52-DK"
|
||||
|
||||
#define MICROPY_PY_MACHINE_PWM (1)
|
||||
#define MICROPY_PY_MACHINE_HW_PWM (1)
|
||||
#define MICROPY_PY_MACHINE_HW_SPI (1)
|
||||
#define MICROPY_PY_MACHINE_TIMER (1)
|
||||
#define MICROPY_PY_MACHINE_RTC (1)
|
||||
|
|
|
@ -30,7 +30,7 @@
|
|||
#define MICROPY_HW_MCU_NAME "NRF52840"
|
||||
#define MICROPY_PY_SYS_PLATFORM "nrf52840-PDK"
|
||||
|
||||
#define MICROPY_PY_MACHINE_PWM (1)
|
||||
#define MICROPY_PY_MACHINE_HW_PWM (1)
|
||||
#define MICROPY_PY_MACHINE_HW_SPI (1)
|
||||
#define MICROPY_PY_MACHINE_I2C (1)
|
||||
#define MICROPY_PY_MACHINE_ADC (1)
|
||||
|
|
|
@ -48,7 +48,7 @@
|
|||
#include "spi.h"
|
||||
#include "i2c.h"
|
||||
#include "rtc.h"
|
||||
#if MICROPY_PY_MACHINE_PWM
|
||||
#if MICROPY_PY_MACHINE_HW_PWM
|
||||
#include "pwm.h"
|
||||
#endif
|
||||
#include "timer.h"
|
||||
|
@ -110,7 +110,7 @@ int main(int argc, char **argv) {
|
|||
i2c_init0();
|
||||
#endif
|
||||
|
||||
#if MICROPY_PY_MACHINE_PWM
|
||||
#if MICROPY_PY_MACHINE_HW_PWM
|
||||
pwm_init0();
|
||||
#endif
|
||||
|
||||
|
|
|
@ -41,7 +41,7 @@
|
|||
#include "uart.h"
|
||||
#include "spi.h"
|
||||
#include "i2c.h"
|
||||
#if MICROPY_PY_MACHINE_PWM
|
||||
#if MICROPY_PY_MACHINE_HW_PWM
|
||||
#include "pwm.h"
|
||||
#endif
|
||||
#if MICROPY_PY_MACHINE_ADC
|
||||
|
@ -213,7 +213,7 @@ STATIC const mp_map_elem_t machine_module_globals_table[] = {
|
|||
#if MICROPY_PY_MACHINE_RTC
|
||||
{ MP_OBJ_NEW_QSTR(MP_QSTR_RTC), (mp_obj_t)&machine_rtc_type },
|
||||
#endif
|
||||
#if MICROPY_PY_MACHINE_PWM
|
||||
#if MICROPY_PY_MACHINE_HW_PWM
|
||||
{ MP_OBJ_NEW_QSTR(MP_QSTR_PWM), (mp_obj_t)&machine_hard_pwm_type },
|
||||
#endif
|
||||
#if MICROPY_PY_MACHINE_TEMP
|
||||
|
|
|
@ -31,7 +31,7 @@
|
|||
#include "py/runtime.h"
|
||||
#include "py/mphal.h"
|
||||
|
||||
#if MICROPY_PY_MACHINE_PWM
|
||||
#if MICROPY_PY_MACHINE_HW_PWM
|
||||
|
||||
#include "pin.h"
|
||||
#include "genhdr/pins.h"
|
||||
|
@ -329,4 +329,4 @@ const mp_obj_type_t machine_hard_pwm_type = {
|
|||
.locals_dict = (mp_obj_t)&machine_pwm_locals_dict,
|
||||
};
|
||||
|
||||
#endif // MICROPY_PY_MACHINE_PWM
|
||||
#endif // MICROPY_PY_MACHINE_HW_PWM
|
||||
|
|
|
@ -127,8 +127,8 @@
|
|||
#define MICROPY_PY_MACHINE_HW_SPI (1)
|
||||
#endif
|
||||
|
||||
#ifndef MICROPY_PY_MACHINE_PWM
|
||||
#define MICROPY_PY_MACHINE_PWM (0)
|
||||
#ifndef MICROPY_PY_MACHINE_HW_PWM
|
||||
#define MICROPY_PY_MACHINE_HW_PWM (0)
|
||||
#endif
|
||||
|
||||
#ifndef MICROPY_PY_MACHINE_TIMER
|
||||
|
|
Loading…
Reference in New Issue