-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Add support for nrf52833 #2789
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
Add support for nrf52833 #2789
Conversation
This flash chip is used in Simmel. Signed-off-by: Sean Cross <[email protected]>
Add a conditional around the call to neopixel_write(), allowing us to build for nrf without neopixel support. Signed-off-by: Sean Cross <[email protected]>
Only initialize i2c, spi, and uart if building with BUSIO. Signed-off-by: Sean Cross <[email protected]>
Ports can set CIRCUITPY_RGBMATRIX and CIRCUITPY_FRAMEBUFFERIO to 0 in their .mk file in order to prevent these from being built. This is necessary for resource-constrained devices. Signed-off-by: Sean Cross <[email protected]>
This adds preliminary support for the nRF52833, which is a variant of the nRF52840 with half the RAM, half the flash, and fewer peripherals. Signed-off-by: Sean Cross <[email protected]>
The BLE Config area needs to be subtracted from the size of the firmware. THis is because the firmware is counted by walking backwards from the end of memory, and the BLE config area is placed lower in memory than the firmware. Subtracting the BLE config size ensures the internal flash filesystem doesn't try to use the firmware as storage. Signed-off-by: Sean Cross <[email protected]>
Conditionally set variables such as the softdevice RAM size, bootloader size, and the spi m3 buffer size. This allows ports to adjust these values to suit their needs. Signed-off-by: Sean Cross <[email protected]>
Allow for setting various softradio memory settings as part of a board in order to support lower-memory configurations. If a parameter is unspecified then the previously-defined value is used. Signed-off-by: Sean Cross <[email protected]>
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! I have an '833 dev board so I'm excited to try it.
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 late, but I'll submit a PR to fix this tomorrow, assuming it looks good to others. (EDIT: I did it now to sleep better)
@dhalbert we may need to upgrade the SD to v7 for nrf52833. S140 v6 is written before 833 is released |
@xobs hmm, did you run into issues with SD v6.1.1? |
I haven't run into any issues yet, though all I've done is run the scanning demo from Adafruit. Is there a Bluetooth regression suite I could run? I have one PCA10100 (nrf52833) and two PCA10059 (nrf52840) boards in my possession. |
No test suite that I know of! |
I'll look into updating to 7.0.1. It compiles, at least. I'll do some testing and open a PR that adds 7.0.1 and bumps nrf52833 to use 7.0.1 instead of 6.1.1. I may have just gotten lucky given my limited testing abilities. |
We could ask in https://devzone.nordicsemi.com/, but they would probably say it's not supported. The question is whether they would be willing to say that it should work OK, or whether they know of some fatal flaw. |
Well, it built and scans and Appears To Work. So I made a PR: #2801 |
This patchset adds support for nRF52833, including various modifications required to reduce memory and flash usage:
I'm a little concerned about 7d810e3 which was necessary, because otherwise the BLE config region was included in the firmware region which caused the SoftRadio to overwrite parts of Circuit Python when it went to update the BLE config settings, which made Circuit Python very unhappy.