share fourwire and make nrf compile
This commit is contained in:
parent
2d136d58bf
commit
760bd8d8a4
@ -305,7 +305,6 @@ SRC_COMMON_HAL = \
|
||||
busio/UART.c \
|
||||
digitalio/__init__.c \
|
||||
digitalio/DigitalInOut.c \
|
||||
displayio/FourWire.c \
|
||||
displayio/ParallelBus.c \
|
||||
i2cslave/__init__.c \
|
||||
i2cslave/I2CSlave.c \
|
||||
@ -380,6 +379,7 @@ SRC_SHARED_MODULE = \
|
||||
displayio/Bitmap.c \
|
||||
displayio/ColorConverter.c \
|
||||
displayio/Display.c \
|
||||
displayio/FourWire.c \
|
||||
displayio/Group.c \
|
||||
displayio/OnDiskBitmap.c \
|
||||
displayio/Palette.c \
|
||||
|
@ -118,7 +118,6 @@ SRC_C += \
|
||||
fatfs_port.c \
|
||||
mphalport.c \
|
||||
tick.c \
|
||||
board_busses.c \
|
||||
boards/$(BOARD)/board.c \
|
||||
boards/$(BOARD)/pins.c \
|
||||
device/$(MCU_VARIANT)/startup_$(MCU_SUB_VARIANT).c \
|
||||
@ -156,6 +155,7 @@ SRC_COMMON_HAL += \
|
||||
busio/__init__.c\
|
||||
digitalio/DigitalInOut.c \
|
||||
digitalio/__init__.c \
|
||||
displayio/ParallelBus.c \
|
||||
microcontroller/Pin.c \
|
||||
microcontroller/Processor.c \
|
||||
microcontroller/__init__.c \
|
||||
@ -214,6 +214,16 @@ SRC_SHARED_MODULE = \
|
||||
bitbangio/OneWire.c \
|
||||
bitbangio/SPI.c \
|
||||
busio/OneWire.c \
|
||||
displayio/__init__.c \
|
||||
displayio/Bitmap.c \
|
||||
displayio/ColorConverter.c \
|
||||
displayio/Display.c \
|
||||
displayio/FourWire.c \
|
||||
displayio/Group.c \
|
||||
displayio/OnDiskBitmap.c \
|
||||
displayio/Palette.c \
|
||||
displayio/Shape.c \
|
||||
displayio/Sprite.c \
|
||||
storage/__init__.c
|
||||
|
||||
# uheap/__init__.c \
|
||||
|
@ -1,114 +0,0 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2018 Scott Shawcroft for Adafruit Industries
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "shared-bindings/busio/I2C.h"
|
||||
#include "shared-bindings/busio/SPI.h"
|
||||
#include "shared-bindings/busio/UART.h"
|
||||
|
||||
#include "shared-bindings/microcontroller/Pin.h"
|
||||
#include "supervisor/shared/translate.h"
|
||||
#include "nrf/pins.h"
|
||||
#include "py/mpconfig.h"
|
||||
#include "py/runtime.h"
|
||||
|
||||
#if !defined(DEFAULT_I2C_BUS_SDA) || !defined(DEFAULT_I2C_BUS_SCL)
|
||||
STATIC mp_obj_t board_i2c(void) {
|
||||
mp_raise_NotImplementedError(translate("No default I2C bus"));
|
||||
return NULL;
|
||||
}
|
||||
#else
|
||||
STATIC mp_obj_t i2c_singleton = NULL;
|
||||
|
||||
STATIC mp_obj_t board_i2c(void) {
|
||||
|
||||
if (i2c_singleton == NULL) {
|
||||
busio_i2c_obj_t *self = m_new_obj(busio_i2c_obj_t);
|
||||
self->base.type = &busio_i2c_type;
|
||||
|
||||
assert_pin_free(DEFAULT_I2C_BUS_SDA);
|
||||
assert_pin_free(DEFAULT_I2C_BUS_SCL);
|
||||
common_hal_busio_i2c_construct(self, DEFAULT_I2C_BUS_SCL, DEFAULT_I2C_BUS_SDA, 400000, 0);
|
||||
i2c_singleton = (mp_obj_t)self;
|
||||
}
|
||||
return i2c_singleton;
|
||||
|
||||
}
|
||||
#endif
|
||||
MP_DEFINE_CONST_FUN_OBJ_0(board_i2c_obj, board_i2c);
|
||||
|
||||
#if !defined(DEFAULT_SPI_BUS_SCK) || !defined(DEFAULT_SPI_BUS_MISO) || !defined(DEFAULT_SPI_BUS_MOSI)
|
||||
STATIC mp_obj_t board_spi(void) {
|
||||
mp_raise_NotImplementedError(translate("No default SPI bus"));
|
||||
return NULL;
|
||||
}
|
||||
#else
|
||||
STATIC mp_obj_t spi_singleton = NULL;
|
||||
|
||||
STATIC mp_obj_t board_spi(void) {
|
||||
|
||||
if (spi_singleton == NULL) {
|
||||
busio_spi_obj_t *self = m_new_obj(busio_spi_obj_t);
|
||||
self->base.type = &busio_spi_type;
|
||||
assert_pin_free(DEFAULT_SPI_BUS_SCK);
|
||||
assert_pin_free(DEFAULT_SPI_BUS_MOSI);
|
||||
assert_pin_free(DEFAULT_SPI_BUS_MISO);
|
||||
const mcu_pin_obj_t* clock = MP_OBJ_TO_PTR(DEFAULT_SPI_BUS_SCK);
|
||||
const mcu_pin_obj_t* mosi = MP_OBJ_TO_PTR(DEFAULT_SPI_BUS_MOSI);
|
||||
const mcu_pin_obj_t* miso = MP_OBJ_TO_PTR(DEFAULT_SPI_BUS_MISO);
|
||||
common_hal_busio_spi_construct(self, clock, mosi, miso);
|
||||
spi_singleton = (mp_obj_t)self;
|
||||
}
|
||||
return spi_singleton;
|
||||
}
|
||||
#endif
|
||||
MP_DEFINE_CONST_FUN_OBJ_0(board_spi_obj, board_spi);
|
||||
|
||||
#if !defined(DEFAULT_UART_BUS_RX) || !defined(DEFAULT_UART_BUS_TX)
|
||||
STATIC mp_obj_t board_uart(void) {
|
||||
mp_raise_NotImplementedError(translate("No default UART bus"));
|
||||
return NULL;
|
||||
}
|
||||
#else
|
||||
STATIC mp_obj_t uart_singleton = NULL;
|
||||
|
||||
STATIC mp_obj_t board_uart(void) {
|
||||
if (uart_singleton == NULL) {
|
||||
busio_uart_obj_t *self = m_new_obj(busio_uart_obj_t);
|
||||
self->base.type = &busio_uart_type;
|
||||
|
||||
assert_pin_free(DEFAULT_UART_BUS_RX);
|
||||
assert_pin_free(DEFAULT_UART_BUS_TX);
|
||||
|
||||
const mcu_pin_obj_t* rx = MP_OBJ_TO_PTR(DEFAULT_UART_BUS_RX);
|
||||
const mcu_pin_obj_t* tx = MP_OBJ_TO_PTR(DEFAULT_UART_BUS_TX);
|
||||
|
||||
common_hal_busio_uart_construct(self, tx, rx, 9600, 8, PARITY_NONE, 1, 1000, 64);
|
||||
uart_singleton = (mp_obj_t)self;
|
||||
}
|
||||
return uart_singleton;
|
||||
}
|
||||
#endif
|
||||
MP_DEFINE_CONST_FUN_OBJ_0(board_uart_obj, board_uart);
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_A0), MP_ROM_PTR(&pin_P0_04) },
|
||||
@ -44,7 +44,7 @@ STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_L), MP_ROM_PTR(&pin_P1_15) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_RED_LED), MP_ROM_PTR(&pin_P1_15) },
|
||||
{ MP_ROM_QSTR(MP_QSTR_D3), MP_ROM_PTR(&pin_P1_15) },
|
||||
|
||||
|
||||
{ MP_ROM_QSTR(MP_QSTR_BLUE_LED), MP_ROM_PTR(&pin_P1_10) },
|
||||
};
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_AIN0), MP_ROM_PTR(&pin_P0_02) },
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_AIN0), MP_ROM_PTR(&pin_P0_02) },
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_A0), MP_ROM_PTR(&pin_P0_03) },
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_A0), MP_ROM_PTR(&pin_P0_03) },
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_A0), MP_ROM_PTR(&pin_P0_03) },
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_P0_00), MP_ROM_PTR(&pin_P0_00) },
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_P0_02), MP_ROM_PTR(&pin_P0_02) },
|
||||
|
@ -1,6 +1,6 @@
|
||||
#include "shared-bindings/board/__init__.h"
|
||||
|
||||
#include "board_busses.h"
|
||||
#include "supervisor/shared/board_busses.h"
|
||||
|
||||
STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
|
||||
{ MP_ROM_QSTR(MP_QSTR_D0), MP_ROM_PTR(&pin_P1_15) }, // D1/TX
|
||||
|
137
ports/nrf/common-hal/displayio/ParallelBus.c
Normal file
137
ports/nrf/common-hal/displayio/ParallelBus.c
Normal file
@ -0,0 +1,137 @@
|
||||
/*
|
||||
* This file is part of the MicroPython project, http://micropython.org/
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2018 Scott Shawcroft for Adafruit Industries
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
* in the Software without restriction, including without limitation the rights
|
||||
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
* copies of the Software, and to permit persons to whom the Software is
|
||||
* furnished to do so, subject to the following conditions:
|
||||
*
|
||||
* The above copyright notice and this permission notice shall be included in
|
||||
* all copies or substantial portions of the Software.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#include "shared-bindings/displayio/ParallelBus.h"
|
||||
|
||||
#include <stdint.h>
|
||||
|
||||
#include "common-hal/microcontroller/Pin.h"
|
||||
#include "py/runtime.h"
|
||||
#include "shared-bindings/digitalio/DigitalInOut.h"
|
||||
|
||||
#include "tick.h"
|
||||
|
||||
void common_hal_displayio_parallelbus_construct(displayio_parallelbus_obj_t* self,
|
||||
const mcu_pin_obj_t* data0, const mcu_pin_obj_t* command, const mcu_pin_obj_t* chip_select,
|
||||
const mcu_pin_obj_t* write, const mcu_pin_obj_t* read, const mcu_pin_obj_t* reset) {
|
||||
|
||||
uint8_t data_pin = data0->number;
|
||||
if (data_pin % 8 != 0 || data_pin % 32 >= 24) {
|
||||
mp_raise_ValueError(translate("Data 0 pin must be byte aligned"));
|
||||
}
|
||||
for (uint8_t i = 0; i < 8; i++) {
|
||||
if (!pin_number_is_free(data_pin + i)) {
|
||||
mp_raise_ValueError_varg(translate("Bus pin %d is already in use"), i);
|
||||
}
|
||||
}
|
||||
NRF_GPIO_Type *g;
|
||||
uint8_t num_pins_in_port;
|
||||
if (data0->number < P0_PIN_NUM) {
|
||||
g = NRF_P0;
|
||||
num_pins_in_port = P0_PIN_NUM;
|
||||
} else {
|
||||
g = NRF_P1;
|
||||
num_pins_in_port = P1_PIN_NUM;
|
||||
}
|
||||
g->DIRSET = 0xff << (data_pin % num_pins_in_port);
|
||||
self->bus = ((uint8_t*) &g->OUT) + (data0->number % num_pins_in_port / 8);
|
||||
|
||||
self->command.base.type = &digitalio_digitalinout_type;
|
||||
common_hal_digitalio_digitalinout_construct(&self->command, command);
|
||||
common_hal_digitalio_digitalinout_switch_to_output(&self->command, true, DRIVE_MODE_PUSH_PULL);
|
||||
|
||||
self->chip_select.base.type = &digitalio_digitalinout_type;
|
||||
common_hal_digitalio_digitalinout_construct(&self->chip_select, chip_select);
|
||||
common_hal_digitalio_digitalinout_switch_to_output(&self->chip_select, true, DRIVE_MODE_PUSH_PULL);
|
||||
|
||||
self->reset.base.type = &digitalio_digitalinout_type;
|
||||
common_hal_digitalio_digitalinout_construct(&self->reset, reset);
|
||||
common_hal_digitalio_digitalinout_switch_to_output(&self->reset, true, DRIVE_MODE_PUSH_PULL);
|
||||
|
||||
self->write.base.type = &digitalio_digitalinout_type;
|
||||
common_hal_digitalio_digitalinout_construct(&self->write, write);
|
||||
common_hal_digitalio_digitalinout_switch_to_output(&self->write, true, DRIVE_MODE_PUSH_PULL);
|
||||
|
||||
self->read.base.type = &digitalio_digitalinout_type;
|
||||
common_hal_digitalio_digitalinout_construct(&self->read, read);
|
||||
common_hal_digitalio_digitalinout_switch_to_output(&self->read, true, DRIVE_MODE_PUSH_PULL);
|
||||
|
||||
self->data0_pin = data_pin;
|
||||
uint8_t num_pins_in_write_port;
|
||||
if (data0->number < P0_PIN_NUM) {
|
||||
self->write_group = NRF_P0;
|
||||
num_pins_in_write_port = P0_PIN_NUM;
|
||||
} else {
|
||||
self->write_group = NRF_P1;
|
||||
num_pins_in_write_port = P1_PIN_NUM;
|
||||
}
|
||||
self->write_mask = 1 << (write->number % num_pins_in_write_port);
|
||||
|
||||
never_reset_pin_number(command->number);
|
||||
never_reset_pin_number(chip_select->number);
|
||||
never_reset_pin_number(write->number);
|
||||
never_reset_pin_number(read->number);
|
||||
never_reset_pin_number(reset->number);
|
||||
for (uint8_t i = 0; i < 8; i++) {
|
||||
never_reset_pin_number(data_pin + i);
|
||||
}
|
||||
}
|
||||
|
||||
void common_hal_displayio_parallelbus_deinit(displayio_parallelbus_obj_t* self) {
|
||||
for (uint8_t i = 0; i < 8; i++) {
|
||||
reset_pin_number(self->data0_pin + i);
|
||||
}
|
||||
|
||||
reset_pin_number(self->command.pin->number);
|
||||
reset_pin_number(self->chip_select.pin->number);
|
||||
reset_pin_number(self->write.pin->number);
|
||||
reset_pin_number(self->read.pin->number);
|
||||
reset_pin_number(self->reset.pin->number);
|
||||
}
|
||||
|
||||
bool common_hal_displayio_parallelbus_begin_transaction(mp_obj_t obj) {
|
||||
displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj);
|
||||
common_hal_digitalio_digitalinout_set_value(&self->chip_select, false);
|
||||
return true;
|
||||
}
|
||||
|
||||
void common_hal_displayio_parallelbus_send(mp_obj_t obj, bool command, uint8_t *data, uint32_t data_length) {
|
||||
displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj);
|
||||
common_hal_digitalio_digitalinout_set_value(&self->command, !command);
|
||||
uint32_t* clear_write = (uint32_t*) &self->write_group->OUTCLR;
|
||||
uint32_t* set_write = (uint32_t*) &self->write_group->OUTSET;
|
||||
uint32_t mask = self->write_mask;
|
||||
for (uint32_t i = 0; i < data_length; i++) {
|
||||
*clear_write = mask;
|
||||
*self->bus = data[i];
|
||||
*set_write = mask;
|
||||
}
|
||||
}
|
||||
|
||||
void common_hal_displayio_parallelbus_end_transaction(mp_obj_t obj) {
|
||||
displayio_parallelbus_obj_t* self = MP_OBJ_TO_PTR(obj);
|
||||
common_hal_digitalio_digitalinout_set_value(&self->chip_select, true);
|
||||
}
|
@ -3,7 +3,7 @@
|
||||
*
|
||||
* The MIT License (MIT)
|
||||
*
|
||||
* Copyright (c) 2018 Scott Shawcroft for Adafruit Industries
|
||||
* Copyright (c) 2019 Scott Shawcroft for Adafruit Industries
|
||||
*
|
||||
* Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
* of this software and associated documentation files (the "Software"), to deal
|
||||
@ -24,16 +24,22 @@
|
||||
* THE SOFTWARE.
|
||||
*/
|
||||
|
||||
#ifndef MICROPY_INCLUDED_NRF_BOARD_BUSSES_H
|
||||
#define MICROPY_INCLUDED_NRF_BOARD_BUSSES_H
|
||||
#ifndef MICROPY_INCLUDED_NRF_COMMON_HAL_DISPLAYIO_PARALLELBUS_H
|
||||
#define MICROPY_INCLUDED_NRF_COMMON_HAL_DISPLAYIO_PARALLELBUS_H
|
||||
|
||||
void board_i2c(void);
|
||||
extern mp_obj_fun_builtin_fixed_t board_i2c_obj;
|
||||
#include "common-hal/digitalio/DigitalInOut.h"
|
||||
|
||||
void board_spi(void);
|
||||
extern mp_obj_fun_builtin_fixed_t board_spi_obj;
|
||||
typedef struct {
|
||||
mp_obj_base_t base;
|
||||
uint8_t* bus;
|
||||
digitalio_digitalinout_obj_t command;
|
||||
digitalio_digitalinout_obj_t chip_select;
|
||||
digitalio_digitalinout_obj_t reset;
|
||||
digitalio_digitalinout_obj_t write;
|
||||
digitalio_digitalinout_obj_t read;
|
||||
uint8_t data0_pin;
|
||||
NRF_GPIO_Type* write_group;
|
||||
uint32_t write_mask;
|
||||
} displayio_parallelbus_obj_t;
|
||||
|
||||
void board_uart(void);
|
||||
extern mp_obj_fun_builtin_fixed_t board_uart_obj;
|
||||
|
||||
#endif // MICROPY_INCLUDED_NRF_BOARD_BUSSES_H
|
||||
#endif // MICROPY_INCLUDED_NRF_COMMON_HAL_DISPLAYIO_PARALLELBUS_H
|
@ -44,6 +44,7 @@ void reset_all_pins(void);
|
||||
// need to store a full pointer.
|
||||
void reset_pin_number(uint8_t pin);
|
||||
void claim_pin(const mcu_pin_obj_t* pin);
|
||||
bool pin_number_is_free(uint8_t pin_number);
|
||||
void never_reset_pin_number(uint8_t pin_number);
|
||||
|
||||
// Lower 5 bits of a pin number are the pin number in a port.
|
||||
|
@ -235,5 +235,7 @@ void run_background_tasks(void);
|
||||
|
||||
//#define CIRCUITPY_BOOT_OUTPUT_FILE "/boot_out.txt"
|
||||
#define CIRCUITPY_DEFAULT_STACK_SIZE 4096
|
||||
#define CIRCUITPY_DISPLAYIO (1)
|
||||
#define CIRCUITPY_DISPLAY_LIMIT (3)
|
||||
|
||||
#endif
|
||||
|
@ -27,7 +27,7 @@
|
||||
#ifndef MICROPY_INCLUDED_SHARED_BINDINGS_DISPLAYBUSIO_FOURWIRE_H
|
||||
#define MICROPY_INCLUDED_SHARED_BINDINGS_DISPLAYBUSIO_FOURWIRE_H
|
||||
|
||||
#include "common-hal/displayio/FourWire.h"
|
||||
#include "shared-module/displayio/FourWire.h"
|
||||
#include "common-hal/microcontroller/Pin.h"
|
||||
|
||||
#include "shared-module/displayio/Group.h"
|
||||
|
@ -31,7 +31,6 @@
|
||||
#include "shared-bindings/microcontroller/Pin.h"
|
||||
#include "supervisor/shared/translate.h"
|
||||
#include "mpconfigboard.h"
|
||||
#include "samd/pins.h"
|
||||
#include "py/runtime.h"
|
||||
|
||||
#define BOARD_I2C (defined(DEFAULT_I2C_BUS_SDA) && defined(DEFAULT_I2C_BUS_SCL))
|
||||
|
Loading…
x
Reference in New Issue
Block a user