diff --git a/ports/nrf/modules/machine/temp.c b/ports/nrf/modules/machine/temp.c index 007a7e5fd8..047514967f 100644 --- a/ports/nrf/modules/machine/temp.c +++ b/ports/nrf/modules/machine/temp.c @@ -30,6 +30,9 @@ #include "py/nlr.h" #include "py/runtime.h" #include "py/mphal.h" + +#if MICROPY_PY_MACHINE_TEMP + #include "temp.h" #include "nrf_temp.h" @@ -40,8 +43,6 @@ #define BLUETOOTH_STACK_ENABLED() (ble_drv_stack_enabled()) #endif // BLUETOOTH_SD -#if MICROPY_PY_MACHINE_TEMP - typedef struct _machine_temp_obj_t { mp_obj_base_t base; } machine_temp_obj_t;