Merge pull request #7331 from PontusO/main

Added LDO control pin, new flash variants and support functions for the LDO control pin.
This commit is contained in:
Dan Halbert 2022-12-11 11:56:40 -05:00 committed by GitHub
commit c0fbcec368
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 22 additions and 5 deletions

View File

@ -23,7 +23,3 @@
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
* THE SOFTWARE. * THE SOFTWARE.
*/ */
#include "supervisor/board.h"
// Use the MP_WEAK supervisor/shared/board.c versions of routines not defined here.

View File

@ -0,0 +1,16 @@
import board
import digitalio
_LDO_PIN = digitalio.DigitalInOut(board.LDO_CONTROL)
_LDO_PIN.direction = digitalio.Direction.OUTPUT
_LDO_PIN.value = True
def ldo_on():
global _LDO_PIN
_LDO_PIN.value = True
def ldo_off():
global _LDO_PIN
_LDO_PIN.value = False

View File

@ -6,4 +6,8 @@ USB_MANUFACTURER = "Invector Labs AB"
MCU_CHIP = nrf52840 MCU_CHIP = nrf52840
SPI_FLASH_FILESYSTEM = 1 SPI_FLASH_FILESYSTEM = 1
EXTERNAL_FLASH_DEVICES = "W25Q16JVxQ,W25Q32FV,W25Q64FV" EXTERNAL_FLASH_DEVICES = "W25Q16JVxQ,W25Q32FV,W25Q32JVxQ,W25Q64FV,W25Q64JVxQ"
FROZEN_MPY_DIRS += $(TOP)/ports/nrf/boards/challenger_840
FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_BLE
FROZEN_MPY_DIRS += $(TOP)/frozen/Adafruit_CircuitPython_NeoPixel

View File

@ -32,6 +32,7 @@ STATIC const mp_rom_map_elem_t board_module_globals_table[] = {
{ MP_ROM_QSTR(MP_QSTR_D13), MP_ROM_PTR(&pin_P0_06) }, { MP_ROM_QSTR(MP_QSTR_D13), MP_ROM_PTR(&pin_P0_06) },
{ MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_P1_08) }, { MP_ROM_QSTR(MP_QSTR_NEOPIXEL), MP_ROM_PTR(&pin_P1_08) },
{ MP_ROM_QSTR(MP_QSTR_LDO_CONTROL), MP_ROM_PTR(&pin_P1_09) },
{ MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_P0_12) }, { MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_P0_12) },
{ MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_P0_11) }, { MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_P0_11) },