-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Add new board Seeed_XIAO_nRF52840 #5753
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
Thanks for the PR! I've added a commit to fix the formatting so make sure and pull it locally before modifying anything else locally. |
{ MP_ROM_QSTR(MP_QSTR_BLUE_LED), MP_ROM_PTR(&pin_P0_06) }, | ||
{ MP_ROM_QSTR(MP_QSTR_GREEN_LED), MP_ROM_PTR(&pin_P0_30) }, | ||
|
||
{ MP_ROM_QSTR(MP_QSTR_6D_PWR), MP_ROM_PTR(&pin_P1_08) }, |
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.
These won't be accessible because they start with a digit, which causes invalid syntax: board.6D_PWR
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 suggest changing MP_QSTR_6D_PWR
to MP_QSTR_IMU_PWR
. After all, the 6-axis Inertial Measurement Unit is what 6D refers to.
{ MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_P0_05) }, | ||
{ MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_P0_04) }, | ||
|
||
{ MP_ROM_QSTR(MP_QSTR_LED), MP_ROM_PTR(&pin_P0_26) }, |
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.
These should probably be named LED_*
because they are channels of a single LED and to be consistent with the rp2040 xiao: https://github.com/adafruit/circuitpython/blob/main/ports/raspberrypi/boards/seeeduino_xiao_rp2040/pins.c#L39
{ MP_ROM_QSTR(MP_QSTR_BLUE_LED), MP_ROM_PTR(&pin_P0_06) }, | ||
{ MP_ROM_QSTR(MP_QSTR_GREEN_LED), MP_ROM_PTR(&pin_P0_30) }, | ||
|
||
{ MP_ROM_QSTR(MP_QSTR_6D_PWR), MP_ROM_PTR(&pin_P1_08) }, |
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 suggest changing MP_QSTR_6D_PWR
to MP_QSTR_IMU_PWR
. After all, the 6-axis Inertial Measurement Unit is what 6D refers to.
{ MP_ROM_QSTR(MP_QSTR_GREEN_LED), MP_ROM_PTR(&pin_P0_30) }, | ||
|
||
{ MP_ROM_QSTR(MP_QSTR_6D_PWR), MP_ROM_PTR(&pin_P1_08) }, | ||
{ MP_ROM_QSTR(MP_QSTR_6D_SCL), MP_ROM_PTR(&pin_P0_27) }, |
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.
Change MP_QSTR_6D_SCL
to MP_QSTR_IMU_SCL
|
||
{ MP_ROM_QSTR(MP_QSTR_6D_PWR), MP_ROM_PTR(&pin_P1_08) }, | ||
{ MP_ROM_QSTR(MP_QSTR_6D_SCL), MP_ROM_PTR(&pin_P0_27) }, | ||
{ MP_ROM_QSTR(MP_QSTR_6D_SDA), MP_ROM_PTR(&pin_P0_07) }, |
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.
Change MP_QSTR_6D_SDA
to MP_QSTR_IMU_SDA
{ MP_ROM_QSTR(MP_QSTR_6D_PWR), MP_ROM_PTR(&pin_P1_08) }, | ||
{ MP_ROM_QSTR(MP_QSTR_6D_SCL), MP_ROM_PTR(&pin_P0_27) }, | ||
{ MP_ROM_QSTR(MP_QSTR_6D_SDA), MP_ROM_PTR(&pin_P0_07) }, | ||
{ MP_ROM_QSTR(MP_QSTR_6D_INT1), MP_ROM_PTR(&pin_P0_11) }, |
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.
Change MP_QSTR_6D_INT1
to MP_QSTR_IMU_INT1
{ MP_ROM_QSTR(MP_QSTR_SCL), MP_ROM_PTR(&pin_P0_05) }, | ||
{ MP_ROM_QSTR(MP_QSTR_SDA), MP_ROM_PTR(&pin_P0_04) }, | ||
|
||
{ MP_ROM_QSTR(MP_QSTR_LED), MP_ROM_PTR(&pin_P0_26) }, |
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.
Reviewing the schematic, I do find this LED connection on the nRF52840 but I cannot find the actual LED on the schematic. We will have to see with actual hardware if there is a second LED.
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.
Hi @jpconstantineau
It is a GRB LED and control by P0.26(red), P0.03(green), P0.06(blue), and the second led just to work on charging mode.
{ MP_ROM_QSTR(MP_QSTR_MIC_PWR), MP_ROM_PTR(&pin_P1_10) }, | ||
{ MP_ROM_QSTR(MP_QSTR_PDM_CLK), MP_ROM_PTR(&pin_P1_00) }, | ||
{ MP_ROM_QSTR(MP_QSTR_PDM_DATA), MP_ROM_PTR(&pin_P0_16) }, | ||
|
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 cannot find the following:
P0_14 READ_BATT_ENABLE
P0_31 VBATT
P0_17 CHARGE_STATUS
These should be added as the functionality is there and users will want to monitor battery charging status as well as battery level.
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.
yes you right, I will add it
Hi, @prplz @jpconstantineau @tannewt Merry Christmas!! |
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 think every requested change has been addressed and we're just waiting for the CI to be green.
No description provided.