forked from micropython/micropython
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ports/samd/boards: Add support for Adafruit Grand Central M4.
Include QSPI pin definitions suggested by @robert-hh, and link photograph of board referenced from micropython-media. Signed-off-by: Graeme Winter <[email protected]> Co-authored-by: robert-hh <[email protected]>
- Loading branch information
1 parent
282b0f4
commit 8cf4aee
Showing
5 changed files
with
153 additions
and
0 deletions.
There are no files selected for viewing
19 changes: 19 additions & 0 deletions
19
ports/samd/boards/ADAFRUIT_GRAND_CENTRAL_M4_EXPRESS/board.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
{ | ||
"deploy": [ | ||
"../deploy.md" | ||
], | ||
"docs": "", | ||
"features": [ | ||
"Micro USB", | ||
"RGB LED", | ||
"SPI Flash" | ||
], | ||
"mcu": "samd51", | ||
"product": "Grand Central M4 Express", | ||
"images": [ | ||
"grand_central_m4_express.jpg" | ||
], | ||
"thumbnail": "", | ||
"url": "https://www.adafruit.com/product/4064", | ||
"vendor": "Adafruit" | ||
} |
5 changes: 5 additions & 0 deletions
5
ports/samd/boards/ADAFRUIT_GRAND_CENTRAL_M4_EXPRESS/manifest.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
include("$(PORT_DIR)/boards/manifest.py") | ||
include("$(MPY_DIR)/extmod/uasyncio") | ||
require("onewire") | ||
require("ds18x20") | ||
require("neopixel") |
10 changes: 10 additions & 0 deletions
10
ports/samd/boards/ADAFRUIT_GRAND_CENTRAL_M4_EXPRESS/mpconfigboard.h
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
#define MICROPY_HW_BOARD_NAME "Grand Central M4 Express" | ||
#define MICROPY_HW_MCU_NAME "ATSAMD51P20A" | ||
|
||
#define MICROPY_HW_XOSC32K (1) | ||
|
||
// fatfs configuration used in ffconf.h | ||
#define MICROPY_FATFS_ENABLE_LFN (1) | ||
#define MICROPY_FATFS_RPATH (2) | ||
#define MICROPY_FATFS_MAX_SS (4096) | ||
#define MICROPY_FATFS_LFN_CODE_PAGE 437 /* 1=SFN/ANSI 437=LFN/U.S.(OEM) */ |
10 changes: 10 additions & 0 deletions
10
ports/samd/boards/ADAFRUIT_GRAND_CENTRAL_M4_EXPRESS/mpconfigboard.mk
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
MCU_SERIES = SAMD51 | ||
CMSIS_MCU = ATSAMD51P20A | ||
LD_FILES = boards/samd51x20a.ld sections.ld | ||
TEXT0 = 0x4000 | ||
|
||
# The ?='s allow overriding in mpconfigboard.mk. | ||
# MicroPython settings | ||
MICROPY_VFS_LFS1 ?= 1 | ||
|
||
FROZEN_MANIFEST = $(BOARD_DIR)/manifest.py |
109 changes: 109 additions & 0 deletions
109
ports/samd/boards/ADAFRUIT_GRAND_CENTRAL_M4_EXPRESS/pins.csv
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,109 @@ | ||
# Pins listed below in order of board pinout picture from Adafruit, with breaks | ||
# corresponding to the same spacing as on the board | ||
|
||
# Analogue input (16 pins) and output (first two of these) | ||
|
||
PIN_PA02,A0 | ||
PIN_PA05,A1 | ||
PIN_PB03,A2 | ||
PIN_PC00,A3 | ||
PIN_PC01,A4 | ||
PIN_PC02,A5 | ||
PIN_PC03,A6 | ||
PIN_PB04,A7 | ||
|
||
|
||
PIN_PB05,A8 | ||
PIN_PB06,A9 | ||
PIN_PB07,A10 | ||
PIN_PB08,A11 | ||
PIN_PB09,A12 | ||
PIN_PA04,A13 | ||
PIN_PA06,A14 | ||
PIN_PA07,A15 | ||
|
||
# Big digital block at bottom of board | ||
|
||
PIN_PD12,D22 | ||
PIN_PA15,D23 | ||
PIN_PC17,D24 | ||
PIN_PC16,D25 | ||
PIN_PA12,D26 | ||
PIN_PA13,D27 | ||
PIN_PA14,D28 | ||
PIN_PB19,D29 | ||
PIN_PA23,D30 | ||
PIN_PA22,D31 | ||
PIN_PA21,D32 | ||
PIN_PA20,D33 | ||
PIN_PA19,D34 | ||
PIN_PA18,D35 | ||
PIN_PA17,D36 | ||
PIN_PA16,D37 | ||
PIN_PB15,D38 | ||
PIN_PB14,D39 | ||
PIN_PC13,D40 | ||
PIN_PC12,D41 | ||
PIN_PC15,D42 | ||
PIN_PC14,D43 | ||
PIN_PC11,D44 | ||
PIN_PC10,D45 | ||
PIN_PC06,D46 | ||
PIN_PC07,D47 | ||
PIN_PC04,D48 | ||
PIN_PC05,D49 | ||
PIN_PD11,D50 | ||
PIN_PD08,D51 | ||
PIN_PD09,D52 | ||
PIN_PD10,D53 | ||
|
||
# Digital row down other side of board - N.B. diplicates | ||
|
||
PIN_PC30,LED_TX | ||
PIN_PC31,LED_RX | ||
PIN_PC24,NEOPIXEL | ||
|
||
PIN_PB21,SCL | ||
PIN_PB20,SDA | ||
PIN_PA03,AREF | ||
PIN_PB01,D13 | ||
PIN_PB00,D12 | ||
PIN_PB23,D11 | ||
PIN_PB22,D10 | ||
PIN_PB02,D9 | ||
PIN_PB18,D8 | ||
|
||
PIN_PD21,D7 | ||
PIN_PD20,D6 | ||
PIN_PC21,D5 | ||
PIN_PC20,D4 | ||
PIN_PC19,D3 | ||
PIN_PC18,D2 | ||
PIN_PB24,D1 | ||
PIN_PB25,D0 | ||
|
||
PIN_PB16,D14 | ||
PIN_PB17,D15 | ||
PIN_PC22,D16 | ||
PIN_PC23,D17 | ||
PIN_PB12,D18 | ||
PIN_PB13,D19 | ||
PIN_PB20,D20 | ||
PIN_PB21,D21 | ||
|
||
PIN_PB26,SD_MOSI | ||
PIN_PB27,SD_SCK | ||
PIN_PA28,SD_CS | ||
PIN_PA29,SD_MISO | ||
PIN_PA31,SD_CARD_DETECT | ||
|
||
|
||
# QSPI flash | ||
|
||
PIN_PB11,QSPI_CS | ||
PIN_PB10,QSPI_SCK | ||
PIN_PA08,QSPI_D0 | ||
PIN_PA09,QSPI_D1 | ||
PIN_PA10,QSPI_D2 | ||
PIN_PA11,QSPI_D3 | ||
|