From acadc0a7dc268edc37d33651f1a9788cf45cbb19 Mon Sep 17 00:00:00 2001 From: robert-hh Date: Thu, 27 Oct 2022 16:54:44 +0200 Subject: [PATCH] rp2/modmachine: Move dht_readinto() to the machine module. --- ports/rp2/modmachine.c | 2 ++ ports/rp2/modrp2.c | 2 -- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ports/rp2/modmachine.c b/ports/rp2/modmachine.c index 8058189a92..fc3f706a18 100644 --- a/ports/rp2/modmachine.c +++ b/ports/rp2/modmachine.c @@ -26,6 +26,7 @@ #include "py/runtime.h" #include "py/mphal.h" +#include "drivers/dht/dht.h" #include "shared/runtime/pyexec.h" #include "extmod/machine_bitstream.h" #include "extmod/machine_i2c.h" @@ -233,6 +234,7 @@ STATIC const mp_rom_map_elem_t machine_module_globals_table[] = { { MP_ROM_QSTR(MP_QSTR_bitstream), MP_ROM_PTR(&machine_bitstream_obj) }, #endif { MP_ROM_QSTR(MP_QSTR_time_pulse_us), MP_ROM_PTR(&machine_time_pulse_us_obj) }, + { MP_ROM_QSTR(MP_QSTR_dht_readinto), MP_ROM_PTR(&dht_readinto_obj) }, { MP_ROM_QSTR(MP_QSTR_mem8), MP_ROM_PTR(&machine_mem8_obj) }, { MP_ROM_QSTR(MP_QSTR_mem16), MP_ROM_PTR(&machine_mem16_obj) }, diff --git a/ports/rp2/modrp2.c b/ports/rp2/modrp2.c index 19c7ad6083..2601a7f443 100644 --- a/ports/rp2/modrp2.c +++ b/ports/rp2/modrp2.c @@ -56,8 +56,6 @@ STATIC const mp_rom_map_elem_t rp2_module_globals_table[] = { { MP_ROM_QSTR(MP_QSTR_PIO), MP_ROM_PTR(&rp2_pio_type) }, { MP_ROM_QSTR(MP_QSTR_StateMachine), MP_ROM_PTR(&rp2_state_machine_type) }, - { MP_ROM_QSTR(MP_QSTR_dht_readinto), MP_ROM_PTR(&dht_readinto_obj) }, - #if MICROPY_PY_NETWORK_CYW43 { MP_ROM_QSTR(MP_QSTR_country), MP_ROM_PTR(&rp2_country_obj) }, #endif