This commit is contained in:
hathach
2018-08-16 03:50:11 +07:00
parent ab8d24f935
commit e585ffc26c
3 changed files with 33 additions and 23 deletions

View File

@ -387,6 +387,16 @@ void bootloader_app_start(uint32_t app_addr)
interrupts_disable();
#if 0 // may need set forward irq
sd_mbr_command_t command =
{
.command = SD_MBR_COMMAND_IRQ_FORWARD_ADDRESS_SET,
.params.irq_forward_address_set.address = MBR_SIZE,
};
sd_mbr_command(&command);
#endif
APP_ERROR_CHECK( sd_softdevice_vector_table_base_set(CODE_REGION_1_START) );
bootloader_util_app_start(CODE_REGION_1_START);

View File

@ -704,8 +704,7 @@ static void advertising_start(void)
APP_ERROR_CHECK( sd_ble_gap_adv_set_configure(&_adv_handle, &gap_adv, &m_adv_params) );
// maximum power for nrf52832, nrf52840 max power is +8
APP_ERROR_CHECK( sd_ble_gap_tx_power_set(BLE_GAP_TX_POWER_ROLE_ADV, _adv_handle, 4) );
// APP_ERROR_CHECK( sd_ble_gap_adv_start(_adv_handle, BLE_CONN_CFG_HIGH_BANDWIDTH) );
APP_ERROR_CHECK( sd_ble_gap_adv_start(_adv_handle, BLE_CONN_CFG_TAG_DEFAULT) );
APP_ERROR_CHECK( sd_ble_gap_adv_start(_adv_handle, BLE_CONN_CFG_HIGH_BANDWIDTH) );
m_is_advertising = true;
}