nRF52810: Confused about PWM usage in LED_PWM example (newbie question)

I've just started learning Zephyr using DevAcademy and samples.

Actually I'm using a custom nRF52810 board.

I'm trying to figure out how to port LED_PWM example on my custom board. On my board I'll have 3 LEDs under PWM and 2 PWM for another device.

Actually I've set my board as this:

.dts

pwmleds {
        compatible = "pwm-leds";
        pwmled0: pwm_led_0 {
            pwms = <&pwm0 0 PWM_MSEC(20) PWM_POLARITY_INVERTED>;
            label = "LED1 - SX - Green";
        };
    };

&pwm0 {
    status = "okay";
    pinctrl-0 = <&pwm0_default>;
    pinctrl-1 = <&pwm0_sleep>;
    pinctrl-names = "default", "sleep";
};

-pinctrl.dtsi

pwm0_default: pwm0_default {
        group0 {
            psels = <NRF_PSEL(PWM_OUT0, 0, 14)>; // LED1G
            nordic,invert;
        };
    };

    pwm0_sleep: pwm0_sleep {
        group0 {
            psels = <NRF_PSEL(PWM_OUT0, 0, 14)>; // LED1G
            low-power-enable;
        };
    };
To assign multiple PWMs outputs should I do like this?
<NRF_PSEL(PWM_OUT0, 0, 14)> // LED 1
<NRF_PSEL(PWM_OUT1, 0, 15)> // LED 2
<NRF_PSEL(PWM_OUT2, 0, 16)> // LED 3
<NRF_PSEL(PWM_OUT3, 0, 17)> // Device 1
<NRF_PSEL(PWM_OUT4, 0, 18)> // Device 2
I'm unsure if this are simulated pwms or peripherals, becouse from datasheet I've 1 PWM with 4 channels .
Also, I see that I've timers and sw_pwm, in all overlays are used pwm, but in one is used timers2 with a subnode pwm (disco_l475). So can I use a timer module as pwm?
Also I need to set something in defconfig?
Thanks.
Related