Skip to content

Commit a495eb4

Browse files
robert-hhdpgeorge
authored andcommitted
esp8266/modmachine: Move dht_readinto() to the machine module.
1 parent 2426ddb commit a495eb4

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

ports/esp8266/modesp.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,6 @@
3131
#include "py/persistentcode.h"
3232
#include "py/mperrno.h"
3333
#include "py/mphal.h"
34-
#include "drivers/dht/dht.h"
3534
#include "uart.h"
3635
#include "user_interface.h"
3736
#include "mem.h"
@@ -355,7 +354,6 @@ STATIC const mp_rom_map_elem_t esp_module_globals_table[] = {
355354
#if MICROPY_ESP8266_APA102
356355
{ MP_ROM_QSTR(MP_QSTR_apa102_write), MP_ROM_PTR(&esp_apa102_write_obj) },
357356
#endif
358-
{ MP_ROM_QSTR(MP_QSTR_dht_readinto), MP_ROM_PTR(&dht_readinto_obj) },
359357
{ MP_ROM_QSTR(MP_QSTR_freemem), MP_ROM_PTR(&esp_freemem_obj) },
360358
{ MP_ROM_QSTR(MP_QSTR_meminfo), MP_ROM_PTR(&esp_meminfo_obj) },
361359
{ MP_ROM_QSTR(MP_QSTR_check_fw), MP_ROM_PTR(&esp_check_fw_obj) },

ports/esp8266/modmachine.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
#include "py/obj.h"
3232
#include "py/runtime.h"
3333
#include "shared/runtime/pyexec.h"
34+
#include "drivers/dht/dht.h"
3435

3536
// This needs to be set before we include the RTOS headers
3637
#define USE_US_TIMER 1
@@ -418,6 +419,7 @@ STATIC const mp_rom_map_elem_t machine_module_globals_table[] = {
418419
#endif
419420

420421
{ MP_ROM_QSTR(MP_QSTR_time_pulse_us), MP_ROM_PTR(&machine_time_pulse_us_obj) },
422+
{ MP_ROM_QSTR(MP_QSTR_dht_readinto), MP_ROM_PTR(&dht_readinto_obj) },
421423

422424
{ MP_ROM_QSTR(MP_QSTR_RTC), MP_ROM_PTR(&pyb_rtc_type) },
423425
{ MP_ROM_QSTR(MP_QSTR_Timer), MP_ROM_PTR(&esp_timer_type) },

0 commit comments

Comments
 (0)