Skip to content

Commit

Permalink
[nrf fromlist] samples: basic: Add overlay for nRF54L15 for basic_pwm…
Browse files Browse the repository at this point in the history
… example

Adds overlay to use hardware PWM. There is no possilibity to work
with all period configuration.

Upstream PR: zephyrproject-rtos/zephyr#71812

Signed-off-by: Karol Lasończyk <[email protected]>
  • Loading branch information
kl-cruz committed Apr 23, 2024
1 parent 3733e70 commit cedf8e9
Showing 1 changed file with 33 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
&pinctrl {
pwm_default: pwm_default {
group1 {
psels = <NRF_PSEL(PWM_OUT0, 1, 8)>;
};
};
pwm_sleep: pwm_sleep {
group1 {
psels = <NRF_PSEL(PWM_OUT0, 1, 8)>;
low-power-enable;
};
};
};

&pwm20 {
status = "okay";
pinctrl-0 = <&pwm_default>;
pinctrl-1 = <&pwm_sleep>;
pinctrl-names = "default", "sleep";
};

/ {
pwmleds {
compatible = "pwm-leds";
pwm_led0: pwm_led_0 {
pwms = <&pwm20 0 PWM_MSEC(20) PWM_POLARITY_INVERTED>;
};
};

aliases {
pwm-led0 = &pwm_led0;
};
};

0 comments on commit cedf8e9

Please sign in to comment.