8000 Merge pull request #641 from dhalbert/2.x_esp8266_remove_obsolete_dri… · flummer/circuitpython@892d5cd · GitHub
[go: up one dir, main page]

Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit 892d5cd

Browse files
authored
Merge pull request adafruit#641 from dhalbert/2.x_esp8266_remove_obsolete_drivers
Remove obsolete peripheral drivers in esp module
2 parents 4199209 + 641a44e commit 892d5cd

File tree

9 files changed

+0
-239
lines changed

9 files changed

+0
-239
lines changed

esp8266/Makefile

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,6 @@ SRC_C = \
7878
espuart.c \
7979
esppwm.c \
8080
espneopixel.c \
81-
espapa102.c \
8281
intr.c \
8382
modpyb.c \
8483
modmachine.c \
@@ -190,10 +189,6 @@ LIB_SRC_C += \
190189
lib/oofatfs/option/unicode.c
191190
endif
192191

193-
DRIVERS_SRC_C = $(addprefix drivers/,\
194-
dht/dht.c \
195-
)
196-
197192
SRC_S = \
198193
gchelper.s \
199194

@@ -206,7 +201,6 @@ OBJ += $(addprefix $(BUILD)/, $(SRC_SHARED_MODULE_EXPANDED:.c=.o))
206201
OBJ += $(addprefix $(BUILD)/, $(STM_SRC_C:.c=.o))
207202
OBJ += $(addprefix $(BUILD)/, $(EXTMOD_SRC_C:.c=.o))
208203
OBJ += $(addprefix $(BUILD)/, $(LIB_SRC_C:.c=.o))
209-
OBJ += $(addprefix $(BUILD)/, $(DRIVERS_SRC_C:.c=.o))
210204
#OBJ += $(BUILD)/pins_$(BOARD).o
211205

212206
# List of sources for qstr extraction

esp8266/espapa102.c

Lines changed: 0 additions & 115 deletions
This file was deleted.

esp8266/espapa102.h

Lines changed: 0 additions & 31 deletions
This file was deleted.

esp8266/modesp.c

Lines changed: 0 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -30,12 +30,9 @@
3030
#include "py/runtime.h"
3131
#include "py/mperrno.h"
3232
#include "py/mphal.h"
33-
#include "drivers/dht/dht.h"
3433
#include "espuart.h"
3534
#include "user_interface.h"
3635
#include "mem.h"
37-
#include "espneopixel.h"
38-
#include "espapa102.h"
3936
#include "modmachine.h"
4037

4138
#define MODESP_INCLUDE_CONSTANTS (1)
@@ -193,31 +190,6 @@ STATIC mp_obj_t esp_check_fw(void) {
193190
}
194191
STATIC MP_DEFINE_CONST_FUN_OBJ_0(esp_check_fw_obj, esp_check_fw);
195192

196-
197-
STATIC mp_obj_t esp_neopixel_write_(mp_obj_t pin, mp_obj_t buf, mp_obj_t is800k) {
198-
mp_buffer_info_t bufinfo;
199-
mp_get_buffer_raise(buf, &bufinfo, MP_BUFFER_READ);
200-
if (!mp_obj_is_true(is800k)) {
201-
nlr_raise(mp_obj_new_exception_msg(&mp_type_ValueError, "Only 800khz neopixels are supported."));
202-
}
203-
esp_neopixel_write(mp_obj_get_pin_obj(pin)->phys_port,
204-
(uint8_t*)bufinfo.buf, bufinfo.len);
205-
return mp_const_none;
206-
}
207-
STATIC MP_DEFINE_CONST_FUN_OBJ_3(esp_neopixel_write_obj, esp_neopixel_write_);
208-
209-
#if MICROPY_ESP8266_APA102
210-
STATIC mp_obj_t esp_apa102_write_(mp_obj_t clockPin, mp_obj_t dataPin, mp_obj_t buf) {
211-
mp_buffer_info_t bufinfo;
212-
mp_get_buffer_raise(buf, &bufinfo, MP_BUFFER_READ);
213-
esp_apa102_write(mp_obj_get_pin_obj(clockPin)->phys_port,
214-
mp_obj_get_pin_obj(dataPin)->phys_port,
215-
(uint8_t*)bufinfo.buf, bufinfo.len);
216-
return mp_const_none;
217-
}
218-
STATIC MP_DEFINE_CONST_FUN_OBJ_3(esp_apa102_write_obj, esp_apa102_write_);
219-
#endif
220-
221193
STATIC mp_obj_t esp_freemem() {
222194
return MP_OBJ_NEW_SMALL_INT(system_get_free_heap_size());
223195
}
@@ -362,13 +334,6 @@ STATIC const mp_rom_map_elem_t esp_module_globals_table[] = {
362334
{ MP_ROM_QSTR(MP_QSTR_flash_erase), MP_ROM_PTR(&esp_flash_erase_obj) },
363335
{ MP_ROM_QSTR(MP_QSTR_flash_size), MP_ROM_PTR(&esp_flash_size_obj) },
364336
{ MP_ROM_QSTR(MP_QSTR_flash_user_start), MP_ROM_PTR(&esp_flash_user_start_obj) },
365-
#if MICROPY_ESP8266_NEOPIXEL
366-
{ MP_ROM_QSTR(MP_QSTR_neopixel_write), MP_ROM_PTR(&esp_neopixel_write_obj) },
367-
#endif
368-
#if MICROPY_ESP8266_APA102
369-
{ MP_ROM_QSTR(MP_QSTR_apa102_write), MP_ROM_PTR(&esp_apa102_write_obj) },
370-
#endif
371-
{ MP_ROM_QSTR(MP_QSTR_dht_readinto), MP_ROM_PTR(&dht_readinto_obj) },
372337
{ MP_ROM_QSTR(MP_QSTR_freemem), MP_ROM_PTR(&esp_freemem_obj) },
373338
{ MP_ROM_QSTR(MP_QSTR_meminfo), MP_ROM_PTR(&esp_meminfo_obj) },
374339
{ MP_ROM_QSTR(MP_QSTR_check_fw), MP_ROM_PTR(&esp_check_fw_obj) },

esp8266/modules/apa102.py

Lines changed: 0 additions & 17 deletions
This file was deleted.

esp8266/modules/dht.py

Lines changed: 0 additions & 32 deletions
This file was deleted.

esp8266/modules/ds18x20.py

Lines changed: 0 additions & 1 deletion
This file was deleted.

esp8266/modules/onewire.py

Lines changed: 0 additions & 1 deletion
This file was deleted.

esp8266/mpconfigport.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,6 @@
106106
#define MICROPY_FATFS_MAX_SS (4096)
107107
#define MICROPY_FATFS_LFN_CODE_PAGE (437) /* 1=SFN/ANSI 437=LFN/U.S.(OEM) */
108108
#define MICROPY_VFS_FAT (1)
109-
#define MICROPY_ESP8266_APA102 (1)
110109
#define MICROPY_ESP8266_NEOPIXEL (1)
111110

112111
extern void ets_event_poll(void);

0 commit comments

Comments
 (0)
0