I'm working with the nRF52840 PDK and I'm wondering how to change the PHY (preferably to CODED) in a Mesh. Has that been implemented yet? Or when can we expect this feature?
I'm working with the nRF52840 PDK and I'm wondering how to change the PHY (preferably to CODED) in a Mesh. Has that been implemented yet? Or when can we expect this feature?
The following modification worked for me:
In advertise.c, set_default_broadcast_configuration() change radio_mode to use RADIO_MODE_NRF_62K5BIT instead of RADIO_MODE_BLE_1MBIT.
In scanner.c, scanner_config_reset() change scanner_config_radio_mode_set() to use RADIO_MODE_NRF_62K5BIT instead of RADIO_MODE_BLE_1MBIT.
In radio_config.c, radio_config_config() add the following code at the end:
if (p_config->radio_mode==RADIO_MODE_NRF_62K5BIT )
{
NRF_RADIO->PCNF0 |=(
((RADIO_PCNF0_PLEN_LongRange << RADIO_PCNF0_PLEN_Pos) & RADIO_PCNF0_PLEN_Msk) |
((2 << RADIO_PCNF0_CILEN_Pos) & RADIO_PCNF0_CILEN_Msk) |
((3 << RADIO_PCNF0_TERMLEN_Pos) & RADIO_PCNF0_TERMLEN_Msk) );
}
4.In broadcast.c, time_required_to_send_us() add:
if (radio_mode == RADIO_MODE_NRF_62K5BIT)
{
packet_length_in_bytes += RADIO_PREAMBLE_LENGTH_LR_EXTRA_BYTES;
}
And define RADIO_PREAMBLE_LENGTH_LR_EXTRA_BYTES = 9.
Change 5th element in radio_mode_to_us_per_byte[] from 128 to 64.
Let us know if you don't achieve longer range with this patch.
I got back to the MESH today. I have tested inside on our production floor with good results. I still need to do outdoor range testing. Hopefully this afternoon.
I got back to the MESH today. I have tested inside on our production floor with good results. I still need to do outdoor range testing. Hopefully this afternoon.