Welcome Guest,Register Now
Log In

ANT Forum

Welcome guest, please Login or Register

   

Extending DEMO_HR_RECEIVER Windows sample to work with multiple sensors

Rank

Total Posts: 3

Joined 0

PM

Hi,

I'm trying to extend DEMO_HR_RECEIVER Windows sample to work with multiple sensors.
But I manage to pair only one sensor.

According to the pairing example PDF, url = https://www.thisisant.com/resources/an02-device-pairing/
on page 9, I should call "Assign Channel" for every sensor, but in the demo CPP, this is a called as response to MESG_NETWORK_KEY_ID.
and, In the PDF, "Set Network Key" is called only once.
So I receive this only for the first sensor.

Should I change to a "linear" approach as mentioned here ? ( https://www.thisisant.com/forum/viewreply/5001/ ).
I only call "Set Network Key" once, should I called it for every sensor ?
Also in the CPP sample, there is one instance of DSISerialGeneric and one of DSIFramerANT.
It looks fine to me, and I only need to use different channel numbers, but please correct me if I'm wrong.
Or if my problem is somewhere else...
So far it works with different types of sensors (HRM, Bike), but only one at a time.

Thanks for any help,
Si.      
Avatar
RankRankRankRank

Total Posts: 745

Joined 2012-09-14

PM

Hi Si,

I would abstract thinking about this more in terms of channels. In order to pair with multiple sensors, you have two approaches available to you:

1. Open multiple slave channels
2. Open a single channel which scans continuously for multiple devices

If your only attempting to listen to roughly a dozen sensors or so, then opening multiple slave channels is fine.

Setting a network key only needs to be done once, and then multiple channels can address that same network key slot when the channel assignment is done.      
Rank

Total Posts: 3

Joined 0

PM

Harrison - 11 October 2018 04:50 PM
Hi Si,

I would abstract thinking about this more in terms of channels. In order to pair with multiple sensors, you have two approaches available to you:

1. Open multiple slave channels
2. Open a single channel which scans continuously for multiple devices

If your only attempting to listen to roughly a dozen sensors or so, then opening multiple slave channels is fine.

Setting a network key only needs to be done once, and then multiple channels can address that same network key slot when the channel assignment is done.


Hi,
Ok, thanks for your help !
Si