-
Notifications
You must be signed in to change notification settings - Fork 997
Add support for Particle Argon, Boron and Xenon boards #904
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
Conversation
conejoninja
left a comment
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.
It's another repo, but it would be great if the info about the boards is added to the tinygo.org website : https://github.com/tinygo-org/tinygo-site/tree/master/content/microcontrollers
60c9fa2 to
612081a
Compare
conejoninja
left a comment
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.
Boron and Xenon are missing the type "Pin" in some constants. Regular digital/analog pins are missing (A1, D8, D3, D2,...) in the three boards. Everything else looks good to me, I do not have the boards but I saw the tweet so I guess it works.
|
✅ Added the GPIO pins Once #884 gets merged in, I can also set the correct Particle USB VID/PID |
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! thanks for your contribution. One last thing, add them to the list of supported targets https://github.com/tinygo-org/tinygo/tree/dev#supported-boardstargets and I think we can merge this.
|
We should add them to the tinygo website too https://github.com/tinygo-org/tinygo-site/tree/master/content/microcontrollers |
aykevl
left a comment
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.
There is one thing missing: smoke tests for these devices. Take a look here: https://github.com/tinygo-org/tinygo/blob/master/Makefile#L255-L256. These tests make sure the boards will continue to build with future changes to the machine package and in fact catch a lot of bugs in CI.
I have added a number of nitpicks below. They are optional to me, feel free to fix them or not.
aykevl
left a comment
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.
Looks good to me.
One thing I realize just now is that you might want to use a custom linker script for this chip to preserve the bootloader and SoftDevice. See targets/nrf52840-s140v7.ld for an example.
|
Good for me too, should we merge now and add the linker script later? |
|
I'd like to know what @suda thinks before merging. |
|
Oooh the script would be great but I agree with Daniel, we can decouple it into a separate PR. |
|
Thanks for this PR! Great job 👍 now merging |
|
@conejoninja for the next PR: to keep a clean history can you squash such commits? They're mostly going back and forth fixing things while the core change is really just one thing. Ideally it would have been one commit per board but I think that would be hard to change at a later time. A clean history is convenient for things like making a changelog and bisecting bugs. |
|
no problem! I always have doubts between rebase and squash, but I just left a note to myself to squash from now on. :) |
|
There is no hard and fast rule, but in general I try to keep one commit per actual change:
Not everyone knows the git-fu to do such things so it's not a big problem, but it helps to keep the history clean when possible. |
Tested on all three devices:
This PR also adds the ability to change the UART ports when calling
Configureon nRF platform (used to test UART on different pins).Flashed using Particle Debugger which works with
cmsis-dapprofile in OpenOCD.