This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

nRF51 DK SDKv10 with S110 iBeacon beacon example: How to increase TX power?

My requirement is simple: Want to increase the iBeacon transmit power to (i.e. -4, 0 or 4dbm). In the beacon example, I tried adding in the main loop after calling advertising_init():

    uint32_t err_code = sd_ble_gap_tx_power_set(TX_POWER_LEVEL);
		APP_ERROR_CHECK(err_code);

where TX_POWER_LEVEL is defined as 0.

However when I execute the code on nRF51 DK (PCA10028), I am not able to observe increase in transmit power. I still see it as default (-30/-40dbm).

I request you to provide an example, where I can increase the iBeacon transmit power. I would further like to also tweak the advertising interval to optimize power usage.

Thank you and best regards,

Nitin

Parents Reply
  • Hi Kenneth, I have tried measuring the as several locations, I just mentioned the closest measurement of atround-35dbm. At around 1 meter, I am consistently getting measured rssi in the range of -60dbm or less. 

    int main(void)
    {
        uint32_t err_code;
        // Initialize.
        APP_TIMER_INIT(APP_TIMER_PRESCALER, APP_TIMER_OP_QUEUE_SIZE, false);
        err_code = bsp_init(BSP_INIT_LED, APP_TIMER_TICKS(100, APP_TIMER_PRESCALER), NULL);
        APP_ERROR_CHECK(err_code);
        ble_stack_init();
        advertising_init();
    		
    		err_code = sd_ble_gap_tx_power_set(0); //Radio transmit power in dBm (accepted values are -40, -30, -20, -16, -12, -8, -4, 0, and 4 dBm).
        APP_ERROR_CHECK(err_code);
    		
        // Start execution.
        advertising_start();
    
        // Enter main loop.
        for (;; )
        {
    				err_code = sd_ble_gap_tx_power_set(0); //Radio transmit power in dBm (accepted values are -40, -30, -20, -16, -12, -8, -4, 0, and 4 dBm).
    				APP_ERROR_CHECK(err_code);
            power_manage();
        }
    }
    

    I have even tried calling sd_ble_gap_tx_power_set(0) inside the for loop, which has no effect either.

    -Nitin

Children
Related