Topic 2 Lesson 4 of nRF Connect SDK Intermediate has an error

servo uses pwm0 device, channel 1 in DTS file.

But in its pinctrl file, GPIO P0.13 uses PWM_OUT0 which is channel 0. 

It should be changed to "psels = <NRF_PSEL(PWM_OUT1, 0, 13)>;". 

Also, it would be better to give a brief introduction about PWM module and its channels. 

For example, 52840 supports 4 PWM modules and each module can support up to 4 channels. 

  • Hello Rick,

    Thank you very much for the report. I will relay this information to the lesson's maintainers.

    Hieu

  • Hi Rick,

    I've finally picked up this case since we're updating the course in preparation for the next NCS release.

    You state that the servo is set up for &pwm0 in the dts, but in all of the overlays I can see (for the solution) it is set up to use &pwm1 and channel 0 there. It's not very important, but if you have time and still have an overview, could you point to which file you see that the servo device is set up with pwm0?

    It might also be the case that this has been updated by someone else in between you raising the case and I picked it up.

    Also, it would be better to give a brief introduction about PWM module and its channels. 

    I agree, a quick section explaining this is something that I will consider adding in text in the future.

    Kind regards,
    Andreas

Related