Browse Source
To support Lolin S2 Mini ESP32-S2 Variant board. More information about this board can be found at https://www.wemos.cc/en/latest/s2/s2_mini.htmlpull/7841/head
Stewart Bonnick
3 years ago
committed by
Damien George
5 changed files with 62 additions and 0 deletions
@ -0,0 +1,2 @@ |
|||
include("$(PORT_DIR)/boards/manifest.py") |
|||
freeze("./modules") |
@ -0,0 +1,31 @@ |
|||
# LOLIN S2 MINI MicroPython Helper Library |
|||
|
|||
from micropython import const |
|||
from machine import Pin |
|||
|
|||
# Pin Assignments |
|||
|
|||
# SPI |
|||
SPI_MOSI = const(11) |
|||
SPI_MISO = const(9) |
|||
SPI_CLK = const(7) |
|||
|
|||
# I2C |
|||
I2C_SDA = const(33) |
|||
I2C_SCL = const(35) |
|||
|
|||
# DAC |
|||
DAC1 = const(17) |
|||
DAC2 = const(18) |
|||
|
|||
# LED |
|||
LED = const(15) |
|||
|
|||
# BUTTON |
|||
BUTTON = const(0) |
|||
|
|||
# Helper methods for built in sensors |
|||
|
|||
led = Pin(LED, Pin.OUT, value=0) |
|||
|
|||
button = Pin(BUTTON, Pin.IN, Pin.PULL_UP) |
@ -0,0 +1,11 @@ |
|||
set(IDF_TARGET esp32s2) |
|||
|
|||
set(SDKCONFIG_DEFAULTS |
|||
boards/sdkconfig.base |
|||
boards/sdkconfig.spiram_sx |
|||
boards/sdkconfig.usb |
|||
) |
|||
|
|||
if(NOT MICROPY_FROZEN_MANIFEST) |
|||
set(MICROPY_FROZEN_MANIFEST ${MICROPY_BOARD_DIR}/manifest.py) |
|||
endif() |
@ -0,0 +1,12 @@ |
|||
#define MICROPY_HW_BOARD_NAME "LOLIN_S2_MINI" |
|||
#define MICROPY_HW_MCU_NAME "ESP32-S2FN4R2" |
|||
|
|||
#define MICROPY_PY_BLUETOOTH (0) |
|||
#define MICROPY_HW_ENABLE_SDCARD (0) |
|||
|
|||
#define MICROPY_HW_I2C0_SCL (35) |
|||
#define MICROPY_HW_I2C0_SDA (33) |
|||
|
|||
#define MICROPY_HW_SPI1_MOSI (11) |
|||
#define MICROPY_HW_SPI1_MISO (9) |
|||
#define MICROPY_HW_SPI1_SCK (7) |
@ -0,0 +1,6 @@ |
|||
CONFIG_FLASHMODE_QIO=y |
|||
CONFIG_ESPTOOLPY_FLASHFREQ_80M=y |
|||
CONFIG_USB_AND_UART=y |
|||
# LWIP |
|||
CONFIG_LWIP_LOCAL_HOSTNAME="LOLIN_S2_MINI" |
|||
# end of LWIP |
Loading…
Reference in new issue