Welcome Guest,Register Now
Log In

ANT Forum

Welcome guest, please Login or Register

You are here: Forum Home → ANT+ Forums → ANT+ Heart Rate Monitor → Thread

   

Timeout problem in receiving data

Rank

Total Posts: 12

Joined 2022-10-27

PM

Hi,
I have a problem about Search Timeout while trying to receive data using C++ console application (demo.cpp).

I am following this link (https://www.thisisant.com/developer/ant/starting-your-project/#73_tab)

First, I downloaded the Windows library package and build the solution in Visual Studio. Then I opened the demo.cpp file in DEMO_LIB project and changed the parameters of channel as follows:
#define USER_DEVICENUM (120)
#define USER_DEVICETYPE (0)
#define USER_TRANSTYPE (0)

I set these three channel parameters as above, because I am using heart rate watch as the master (to send data to my PC) and there is a USB device, connected to my PC as the slave (to receive data).
when I run the demo.cpp after setting the above parameters, I get the following output and I can't get the data from the Heart Rate watch (Master).

Channel Type? (Master 0Slave 1)
1
Resetting module
...
RESET CompletereasonRESET_CMD
Setting network key
...
Network key set.
Assigning channel...
Channel assigned
Setting Channel ID
...
Channel ID set
Setting Radio Frequency
...
Radio Frequency set
Opening channel
...
Chanel opened
Enabling extended messages
...
Extended messages enabled 


after waiting a bit I will get the following output:
Search Timeout
Channel Closed
Unassigning channel
...
Channel unassigned
Press enter to 
exit 


I don't know why the USB device (slave) can't find the channel?
I appreciate if you can guide me how to solve and receive data,
it's a bit hard for me because I don't have background in network and wireless communication, but I have read the basic protocol documentation two times, still can't find a solution.

     

Image Attachments

a.JPG

Click thumbnail to see full-size image

RankRankRankRank

Total Posts: 370

Joined 2012-06-27

PM

Think you meant to specify device type matching profile doc and device num 0 for wildcard instead of what you have.      

Signature

Ian Haigh

Rank

Total Posts: 3

Joined 2025-10-30

PM

Yes, device type of HRM is 120, but I experience the same problem setting tom 0, 120, 0
despite having NETWORK KEY, EXT MSG adn FREQUENCY 2457, etc.
set all parameters correct.

Last thought was that maybe TACX ANT+ received not able to read HRM POLAR H9 sensor, but that sounds strange.

Anyway, I get the same timeout.

HELP APPRECIATED !!!