MPSL FEM Support Build Issues on NCS1.7.0

Hello,

I am having some build issues when attempting to add support for a Skyworks FEM to our application built with NCS 1.7.0 for a NRF52820 target. Our board file is based on the nrf52833dk_nrf52820 board file provided in the SDK. 

I have added the following to our proj.conf:

CONFIG_MPSL=y
CONFIG_MPSL_FEM=y
CONFIG_MPSL_FEM_SIMPLE_GPIO=y
I have added the following to our root devicetree node:

     nrf_radio_fem: pa_lna {
 
         compatible = "skyworks,sky66112-11", "generic-fem-two-ctrl-pins";
 
         ctx-gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
 
         crx-gpios = <&gpio0 30 GPIO_ACTIVE_HIGH>;
 
     };
Upon building I get an error in mpsl_fem.c that says: 'mpsl_fem_simple_gpio_interface_config_t' {aka 'struct <anonymous>'} has no member named 'ppi_channels'; did you mean 'dppi_channels'?
Tracing it down it seems that for some reason  #if defined(NRF52_SERIES) is false inside of mpsl_fem_config_simple_gpio.h

Am I doing something wrong with my build configuration or project configuration? Or is there some inherent problem with this SDK version and trying to turn on this feature. 
I have modified mpsl_fem_config_simple_gpio.h so that it doesn't check the NRF52_SERIES define. This builds and it seems that the fem is operating as expected. Of course we would like to find a solution to the issue so that we do not need to modify this file. 
Thank you
Parents
  • Hey Torbjørn,

    Thank you for the info. The strange thing to me is that it seems that the NRF52_SERIES define is true inside of main.c, however in mpsl_fem_config_simple_gpio.h it is false. 

    Looking forward to hearing what the software developers have to say about it.

    Thanks,

    Tyler

  • Hi Tyler

    According to the developer my earlier response was not correct. 

    As long as CONFIG_SOC_NRF52820 is set then the NRF52820_XXAA define should be set here, and if NRF52820_XXAA  is defined then the NRF52_SERIES define should be set here

    When you say that your board is based on the nrf52833dk_nrf52820 board do you mean that you have created your own board implementation? 

    If so, have you ever got this to work with the standard board (using an overlay for the sensor)?

    Would you be able to provide the modified board files?

    Best regards
    Torbjørn

  • Hi Torbjørn

    We did not create our own implementation. We just modified the existing nrf52833dk_nrf52820 board file. I have attached the file here. Again, from what I can tell, NRF52_SERIES is defined inside of main.c, but for some reason it is not defined inside of mpsl_fem_config_simple_gpio.h. Maybe there is some type of linker issue or a file that I have not included that should be. I also can see that CONFIG_SOC_NRF52820 is y and that NRF52820_XXAA is defined in main.c.

    Thanks,

    Tyler

    nrf52833dk_nrf52820.zip

  • Hi 

    Thanks for sharing the board files. 

    I tried to reproduce the issue on my end, but here it seems to build fine, also when accessing the ppi_channels field. 

    Could you try to build my project and see if it works OK?

    283704_peripheral_lbs.zip

    It is just a version the peripheral_lbs sample with your configuration added, and the DTS configuration added as an overlay. The sample has to be built using the nrf52833dk_nrf52820 board. 

    Best regards
    Torbjørn

  • Hi Torbjørn,

    Thank you for the response and the example project. That one built successfully for us and we looked further into the differences between that and our project.

    We have found the issue. When CONFIG_ARM_MPU is set to n it causes the problem with the NRF52_SERIES define. I am not entirely sure why that is or if that is expected behavior. We had copied CONFIG_ARM_MPU=n from a proj_minimal.conf in order to save application size on the 52820. With that removed it is building fine now. 

    Thank you for your help. We can close this case.

  • Hi Tyler

    Good to hear that you found the issue Slight smile

    It is odd that disabling CONFIG_ARM_MPU would affect the NRF52_SERIES define. If the developer has some input on this I will let you know. 

    Best regards
    Torbjørn

  • Hi Tyler

    The developer didn't know of any dependencies between CONFIG_ARM_MPU and the NRF52_SERIES define. 

    If you give us the full build log we can take a look, otherwise I will consider the case resolved Slight smile

    Best regards
    Torbjørn

Reply Children
Related