Skip to content
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

applications: nrf_desktop: Add support for nRF54L PDK (code only) #14364

Conversation

MarekPieta
Copy link
Contributor

The PDK can act as either keyboard or mouse. The PR also brings in watchdog alignment.

Jira: NCSDK-26216

@github-actions github-actions bot added manifest changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. labels Mar 5, 2024
@MarekPieta
Copy link
Contributor Author

Aligning with @annwoj's suggestions, doc update will be added later with #14363

@MarekPieta MarekPieta added Platform: nRF54L PRs specific to nRF54L platform that can be merged during stabilization period. and removed changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. labels Mar 5, 2024
@NordicBuilder
Copy link
Contributor

The following west manifest projects have been modified in this Pull Request:

Name Old Revision New Revision Diff
zephyr nrfconnect/sdk-zephyr@3912101 nrfconnect/sdk-zephyr#1559 nrfconnect/sdk-zephyr#1559/files

Note: This message is automatically posted and updated by the Manifest GitHub Action.

@MarekPieta MarekPieta changed the title applications: nrf_desktop: Add support for nRF54L PDK applications: nrf_desktop: Add support for nRF54L PDK (code only) Mar 5, 2024
@NordicBuilder
Copy link
Contributor

NordicBuilder commented Mar 5, 2024

Test specification

CI/Jenkins/NRF

  • Integration Platforms

CI/Jenkins/integration

Test Module File based changes Manually selected West overwrite
desktop52_verification X

Detailed information of selected test modules

Note: This message is automatically posted and updated by the CI

@NordicBuilder
Copy link
Contributor

You can find the documentation preview for this PR at this link. It will be updated about 10 minutes after the documentation build succeeds.

Note: This comment is automatically posted by the Documentation Publishing GitHub Action.


CONFIG_LOG=y
CONFIG_LOG_BACKEND_UART=y
CONFIG_LOG_BACKEND_SHOW_COLOR=n
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

isn't it by default "n"?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nRF Desktop's logging configuration updates default of the CONFIG_LOG_BACKEND_SHOW_COLOR if CONFIG_LOG_BACKEND_RTT is enabled. I would set this Kconfig option here explicitly for consistency (and to avoid relying on default).

status = "disabled";
};

gpioled0 {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do I understand correctly that we cannot use default leds because we need to have one led per node?
Maybe do not disable but remove original leds node?

Also consider using default leds names: led0_g: led_0 -> led0: led_0

Copy link
Contributor Author

@MarekPieta MarekPieta Mar 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, that's the reason behind disabling the node. The node is currently disabled (not removed) for other configuration so I would disable it also here for consistency.
I would prefer to stick to the current naming scheme too (also for consistency with existing GPIO LED configurations - e.g. nrf52833dk_nrf52820).

@MarekPieta MarekPieta force-pushed the upstream_nrf54l_nrf_desktop_code_only branch from 6b62631 to d6f9cb5 Compare March 5, 2024 14:04
@github-actions github-actions bot added changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. and removed manifest labels Mar 5, 2024
Comment on lines +7 to +25
/* Redefine the partition map. */
&rram0 {
/delete-node/ partitions;

partitions {
compatible = "fixed-partitions";
#address-cells = <1>;
#size-cells = <1>;
app_partition: partition@0 {
label = "application";
reg = <0x0 0x177000>;
};

storage_partition: partition@177000 {
label = "storage";
reg = <0x177000 0x6000>;
};
};
};
Copy link
Contributor

@mkapala-nordic mkapala-nordic Mar 5, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be considered: Maybe we could wait for your PM fix (#14368) and replace this DTS partition definitions with pm_static (if necessary)? It would be consistent then with the other targets :D

Copy link
Contributor Author

@MarekPieta MarekPieta Mar 6, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be honest, I would merge it as is and then switch to Partition Manager together with MCUboot integration. I guess we will do it soon and that would prevent from freezing code on PR

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Alright, if no one will object then let's leave it for now as it is.

@MarekPieta MarekPieta force-pushed the upstream_nrf54l_nrf_desktop_code_only branch from d6f9cb5 to 8b3c77a Compare March 6, 2024 10:19
@MarekPieta MarekPieta removed DNM changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. manifest-zephyr labels Mar 6, 2024
@MarekPieta MarekPieta force-pushed the upstream_nrf54l_nrf_desktop_code_only branch from 8b3c77a to df8f3da Compare March 6, 2024 10:31
@github-actions github-actions bot added the changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. label Mar 6, 2024
@MarekPieta MarekPieta removed the changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. label Mar 6, 2024
@MarekPieta MarekPieta added this to the 2.6.0 milestone Mar 6, 2024
@MarekPieta MarekPieta requested a review from SeppoTakalo March 6, 2024 13:43
Copy link
Contributor

@kapi-no kapi-no left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good, just left some informational comments below

Comment on lines 17 to 19
# GPIOs assigned to Button 3 and Button 4 on the PDK v0.2.1 do not support interrupts.
# Because of this, the GPIOs are not supported by the CAF buttons module and cannot be used to
# generate motion.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We would need to have a way to distinguish between v0.2.x PDKs and v0.3.0. However, this is a topic for subsequent PR when the v0.3 support is ready

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That would require a new approach globally

static const struct gpio_pin row[] = {
{ .port = 1, .pin = DT_GPIO_PIN(DT_NODELABEL(button0), gpios) },
{ .port = 1, .pin = DT_GPIO_PIN(DT_NODELABEL(button1), gpios) },
/* GPIOs assigned to Button 3 and Button 4 on the PDK v0.2.1 do not support interrupts.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

same here

CONFIG_DESKTOP_MOTION_BUTTONS_ENABLE=y
CONFIG_DESKTOP_MOTION_BUTTONS_LEFT_KEY_ID=0
CONFIG_DESKTOP_MOTION_BUTTONS_RIGHT_KEY_ID=1
# GPIOs assigned to Button 3 and Button 4 on the PDK v0.2.1 do not support interrupts.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

and here :)

The PDK can act as either keyboard or mouse.

Jira: NCSDK-26216

Signed-off-by: Marek Pieta <[email protected]>
Signed-off-by: Pirun Lee <[email protected]>
@MarekPieta MarekPieta force-pushed the upstream_nrf54l_nrf_desktop_code_only branch from df8f3da to 63b1040 Compare March 6, 2024 14:14
@github-actions github-actions bot added the changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. label Mar 6, 2024
@MarekPieta MarekPieta removed the changelog-entry-required Update changelog before merge. Remove label if entry is not needed or already added. label Mar 6, 2024
@jfischer-no jfischer-no merged commit bf03ee8 into nrfconnect:main Mar 6, 2024
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Platform: nRF54L PRs specific to nRF54L platform that can be merged during stabilization period.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants