1、nRF51822 广播包的设置(SDK12.3.0):
/**@brief Set the radio's transmit power.
*
* @param[in] tx_power Radio transmit power in dBm (accepted values are -40, -30, -20, -16, -12, -8, -4, 0, and 4 dBm).
*
* @note The -30dBm setting is only available on nRF51 series ICs.
* @note The -40dBm setting is only available on nRF52 series ICs.
*
* @retval ::NRF_SUCCESS Successfully changed the transmit power.
* @retval ::NRF_ERROR_INVALID_PARAM Invalid parameter(s) supplied.
*/
SVCALL(SD_BLE_GAP_TX_POWER_SET, uint32_t, sd_ble_gap_tx_power_set(int8_t tx_power));
1.1、在需要设置的地方加上sd_ble_gap_tx_power_set(int8_t tx_power); tx_power形参的值分别:-30, -20, -16, -12, -8, -4, 0, and 4 dBm,值越大信号越强。
2、nRF52832 广播包的设置(SDK15.0.0):
/**@brief Set the radio's transmit power.
*
* @param[in] role The role to s