This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

How to implement selecting one ANT+ master device pair if multiple master deice exist.

Hi,

Our device is slave device with LCD displaying.We need to implement the function as below:

Within range of our slave device, if multiple master device like combined bike speed and cadence senor or speed and distance sensor are found.

They will be displaying on our device to the user asking which device to pair with.

How to implement it.

May I get the related document or apply note even demo code? Thanks.

Now our project is developed base on nRF52832 SDK11.0.0,SD ANT_s332_nrf52_0.9.1.alpha.hex and example demo path: Nordic BLE\nRF5_SDK_11.0.0_89a8197\examples\ant\ant_plus\ant_bsc\bsc_rx\combined

Parents Reply Children
  • Thanks you for your information. I is studying the relevant app note and demo code. Now, base on the demo code, We can search multiple master sensor device . So i have some question as below:

    a) how many master devices can be found for each channel ? if there is a max limit value? We use tool ANT ware II as master device simulators. it can simulate max 8 master device and slave device can search them all. but if 8 is the max limit value or more than 8 master device?

    b)how to pair the selected master device? The demo code is not included it . Before, We configure the channel ID parameter and call lib sd_ant_channel_open to open the channel. They will pair automaticaly.Now, it have openned the channel when searching device. we should call which lib to pair it when selecting the device number of the master device?

  • a) If you don't use the radio for anything else, process the events quickly, and set the search waveform to ANT_WAVEFORM_FAST you should be able to find much more than 8 masters, but I would recommend testing this.

    b) Can't you just do it the same way? I would just open a new channel with the Channel ID that identifies the channel. You can use the extended message format to get the device number, device type and transmission type, see Section 7.1.1 in the ANT Message Protocol for more information.

  • Hi Petter, Thank you for your comment. for item b, i have got it. But We meet a strange phenomenon. base on ant_background_scanning demo code with softdevice S212 ANT_s212_nrf52_0.9.1.alpha.hex. They are ok for searching master device and pair it. But We move the demo code with softdevice S332 ANT_s332_nrf52_0.9.1.alpha.hex They are fail for searching master device. We can't search any master device. the configure parmaeter are the same. is there the different between S212 and S332 for searching master device? Before, base on S332. auto pairing is ok. Our device need to use BLE and ANT+ protocol.So We develop it base on S332.

  • I don't think there should by any difference. You are checking that no functions are returning any errors? Could you check if you see the same behavior with SDK 12.1? It has support for S332 v2.0.0 (and S212 v2.0.0)

  • I am sure that no functions are returning any error. if there is error, We can review printing error info and halt it. if we have more time, we will move the code to the platform with SDK12.1. But now,We want to verify if it is ok for searching device base on SDK11.0.0 S332 ANT_s332_nrf52_0.9.1.alpha.hex. Thanks.

Related