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

gazell maximum channel table size not honoured?

I'm trying to set up a gazell device with a channel table that is 16 channels long. This is for a pairing application where the host has a channel table that is 6 channels long and spans the entire 126 channel range. My host channel selection algorithm ensures that the first timeslot of any host will reside in timeslot 0-15, so an unpaired device sets its channel table to 16 entries, corresponding to channels 0-15.

Once the device and host are paired, the device switches to the same 6 channels that the host has and uses gazell sync to increase the communications data rate.

I have verified that in the 12.2.0 SDK, NRF_GZLL_CONST_MAX_CHANNEL_TABLE_SIZE is 16.

I'm setting up the device channel table (simple example) thusly:

uint8_t channel_table[NRF_GZLL_CONST_MAX_CHANNEL_TABLE_SIZE];

for (i = 0; i < sizeof(channel_table); i++) {
    channel_table[i] = i;
}

nrf_gzll_set_channel_table(channel_table, sizeof(channel_table));

This (and all calls below) are returning true (success).

I am using the NRF_GZLL_DEVICE_CHANNEL_SELECTION_POLICY_USE_SUCCESSFUL channel selection policy and have a the number of timeslots per channel set to 16 times the timeslots per channel setting (2). My timing setup code is the same for host and device:

ts_period = 600; /* 2Mbit */
ts_per_channel = 2;
ts_dwell = 1 for host and 16 for unpaired device

nrf_gzll_set_timeslot_period(ts_per_channel * ts_period); /* one for dev->host, one for host->dev ack */
nrf_gzll_set_timeslots_per_channel(ts_per_chan * ts_dwell);
nrf_gzll_set_timeslots_per_channel_when_device_out_of_sync(ts_per_chan * ts_dwell);

What I see is that if the host has one of its channels in the bottom 7 entries (channel 0 through 6), the device finds it and communicates just fine. If the host has one of its channels beyond that (channel 7-15), then the device never sees the host.

Is this a known issue? Am I misunderstanding something about the maximum channel table length?

  • Hi Andrew

    The critical aspect is that the total channel cycle time has to be the same in the device and the host. In other words if you multiply the number of channels with the timeslot time and the periods per channel factor it should be the same on both sides.

    In other words, if you want to have a different number of channels configured on each side you have to change the timeslot period accordingly. Also, if you have a different timeslot in each side one of them would have to be a multiple of the other.

    Best regards
    Torbjørn

  • Perhaps I haven't explained my problem sufficiently.

    I understand how to set the timeslot period and timeslots per channel so that the host and device.

    I have no problem with the host/device initialization when I use a channel table using 1-7 channels. If I try to use a channel table with 8 or more elements then I am unable to communicate. No errors are reported by nrf_gzll_set_channel_table(), it just does not work.

    In the SDK, NRF_GZLL_CONST_MAX_CHANNEL_TABLE_SIZE is set to 16. Does this not mean I should be able to use a channel table with 16 channels?

  • Sorry for the late reply, I have been out in travel lately.

    I just tested this myself, and I do see some irregularities when using channel tables larger than 8 channels. I will check this with the developer and see if there are some issues in the implementation.

    Best regards

  • Hi again

    A quick update: The developer has also been able to reproduce the issue. He needs some more time to look into it, but I should hear back from him in a day or two.

    Best regards

  • Hi

    According to the developer the issue is most likely that your retransmit counter is too low.
    The device will give up before getting to the channel that is shared with the host, and the next time you try again the same thing will happen.

    Could you try to increase the TX attempt counter to a larger number on the device, and see if it improves the performance?

    For instance, a TX attempt number of 250 should be sufficient.

    Best regards

Related