-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Sparkfun micromod samd51 #4852
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sparkfun micromod samd51 #4852
Conversation
Conflicts: ports/atmel-samd/boards/sparkfun_samd51_micromod/pins.c
|
||
// I2C2 | ||
{ MP_ROM_QSTR(MP_QSTR_SDA2), MP_ROM_PTR(&pin_PA13) }, | ||
{ MP_ROM_QSTR(MP_QSTR_SCL1), MP_ROM_PTR(&pin_PA12) }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't know if it's the source of the build errors but you've got MP_QSTR_SCL1 again here, it's up at line 61 as well.
@@ -0,0 +1,33 @@ | |||
#define MICROPY_HW_BOARD_NAME "SparkFun Thing Plus - SAMD51" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The name of the board needs corrected.
{ MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_PA16) }, | ||
{ MP_ROM_QSTR(MP_QSTR_SCL1), MP_ROM_PTR(&pin_PA16) }, | ||
|
||
{ MP_ROM_QSTR(MP_QSTR_I2C_INT), MP_ROM_PTR(&pin_PB18) }, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The MicroMod board uses the 64-pin SAMD51J20A which doesn't expose a PB18 pin - it doesn't appear until the 100-pin variant.
Removing this line gets it to build for me locally. I don't have one to test with so you'll need to check it works.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks, it should have been PA18
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That builds for me locally now
make -j8 BOARD=sparkfun_samd51_micromod
Use make V=1, make V=2 or set BUILD_VERBOSE similarly in your environment to increase build verbosity.
{}
QSTR updated
463884 bytes used, 560116 bytes free in flash firmware space out of 1024000 bytes (1000.0kB).
35248 bytes used, 226896 bytes free in ram for stack and heap out of 262144 bytes (256.0kB).
Converting to uf2, output size: 928256, start address: 0x4000
Wrote 928256 bytes to build-sparkfun_samd51_micromod/firmware.uf2
Hopefully Github Actions will confirm when it decides to run.
I've not checked the mapping of the pins and I don't have one to test against but it looks good to me.
@lesamouraipourpre Looks like CI is happy now. I’ve confirmed the pins against the schematic, and I’ll be testing on hardware, too. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
great, thank you! This seems good to merge if the CI likes it too.
@stonehippo thanks again — can you follow up by adding the board in circuitpython.org? https://learn.adafruit.com/how-to-add-a-new-board-to-the-circuitpython-org-website?view=all https://github.com/adafruit/circuitpython-org/ |
@jepler will do! |
Added support for the Sparkfun MicroMod SAMD51 board. Board follows a pin layout similar to other MicroMod boards, like the MM RP2040 and MM nRF52840 boards already supported by CircuitPython. This board definition was derived from the Sparkfun SAMD51 Thing+ support, with pin mapping and external flash changes.
I have confirmed the vendor USB PID with Sparkfun.
I’d love a code review. :)