Porting ncs example code to Fanstel BT840X that has an internal skyworks PA/LNA

I am looking to take example codes for the nrf52840dk and run them on a Fanstel BT840X EV board. I am looking at the central and peripheral coded low data rate firmware but want to achieve a much greater range by using the RF amp and LNA. Can anyone point me to some examples that might demonstrate of give some idea how to do this. I am using NRF connect SDK 2.2.99 with visual studio. I have got the Fanstel BT840X range test code working and I have been able to port the examples for the nrf52840dk to the Fanstel BT840X EV board but cannot get the extended range. Does the code need to control the switching of the PA/LNA as at the moment I have the PA fixed on and LNA off.

Parents Reply Children
  • HI Amanda,

    Yes I am aware of that link and the post is the most relevant to my question that I have found.

    I do get this message "CONFIG_MPSL_FEM was assigned the value y, but got the value n. Missing dependencies:
    MPSL_FEM_ANY_SUPPORT" when I add CONFIG_MPSL_FEM=y to my prj.config file.

    I dont have a great understanding of how the PA and LNA are switched. I assume that the BT driver knows when to configure this switch. I am controlling with GPIO the PA and LNA lines into the Skyworks device so I assume that I am not controlling well enough these lines as I have a very poor range. I have been measuring the power draw and I do get peak power consumption of around 200mA.

    Any more assistance gratefully recievied.

  • Hi,

    See https://github.com/nrfconnect/sdk-nrf/blob/v2.2.0/subsys/mpsl/fem/Kconfig#L10-L12

    config MPSL_FEM_ANY_SUPPORT
    	bool
    	default $(dt_nodelabel_enabled,nrf_radio_fem)

    MPSL_FEM_ANY_SUPPORT dependency MPSL_FEM_ANY_SUPPORT was not set for boards without FEMs. Please make sure to build a board with nrf_radio_fem in the overlay. 

    -Amanda H.

  • I have included nrf_radio_fem in my board dts file as below but still i get the error

    /dts-v1/;
    #include <nordic/nrf52840_qiaa.dtsi>
    
    
    
    / {
    	model = "BT840x";
    	compatible = "bt840x";
    
    	chosen {
    		zephyr,sram = &sram0;
    		zephyr,flash = &flash0;
    		zephyr,code-partition = &slot0_partition;
    	};
    };
    
    	
    nrf_radio_fem: skyFem {
    	compatible = "skyworks,sky66112-11", "generic-fem-two-ctrl-pins";
    	ctx-gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
    	crx-gpios = <&gpio0 19 GPIO_ACTIVE_HIGH>;
    	};
    
    &flash0 {
    	partitions {
    		compatible = "fixed-partitions";
    		#address-cells = <1>;
    		#size-cells = <1>;
    
    		boot_partition: partition@0 {
    			label = "mcuboot";
    			reg = <0x0 0xc000>;
    		};
    		slot0_partition: partition@c000 {
    			label = "image-0";
    			reg = <0xc000 0x72000>;
    		};
    		slot1_partition: partition@7e000 {
    			label = "image-1";
    			reg = <0x7e000 0x72000>;
    		};
    		scratch_partition: partition@f0000 {
    			label = "image-scratch";
    			reg = <0xf0000 0xa000>;
    		};
    		storage_partition: partition@fa000 {
    			label = "storage";
    			reg = <0xfa000 0x6000>;
    		};
    	};
    
    
    };
    
    
    
    
     

  • Hi, 

    Try to move L18-L22 to before L15. 

    -Amanda H.

  • Hi, I did that and noticed that line 4 in the code snippet

    / {
    	model = "BT840x_caddy";
    	
    	compatible = "bt840x_caddy";
    
    	chosen {
    		zephyr,sram = &sram0;
    		zephyr,flash = &flash0;
    		zephyr,code-partition = &slot0_partition;
    	};
    	nrf_radio_fem: skyFem {
    		compatible = "skyworks,sky66112-11", "generic-fem-two-ctrl-pins";
    		ctx-gpios = <&gpio0 17 GPIO_ACTIVE_HIGH>;
    		crx-gpios = <&gpio0 19 GPIO_ACTIVE_HIGH>;
    		};
    };
    has a squiggly line with message Unknown node type "bt840x_caddy"

Related