Welcome Guest,Register Now
Log In

ANT Forum

Welcome guest, please Login or Register

   

Missing every other message

Rank

Total Posts: 6

Joined 2014-12-23

PM

Hello. I'm seeing some odd behavior with some code I'm writing to receive broadcast messages from a bike power meter.

As per the Bike Power device profile, I set the ANT channel period to 8182. I'm writing all Tx and Rx messages to a log file, and the entry below for the Channel Period message confirms the channel period setting:
...
20150327.091200.657, CMD: A403 4300 F61F 0D, Set Channel Period
20150327.091200.667, RSP: A403 4000 4300 A4, Response No Error on channel 0 = 67
...
The 5th and 6th bytes of the CMD are the channel period, in clock ticks, in little endian format: 0x1FF6 => 8182.

The following entries from the log file show that messages are received every ~500 ms, instead of every ~250 ms:
...
20150327.091203.124, RSP: A40C 4E00 0000 FF5A F88D 1B01 204E 8DCF , Data page 0 not implemented = 0
20150327.091203.623, RSP: A40C 4E00 1368 4754 4754 FFFF 203A CD4A , Data page 19 not implemented = 0
20150327.091204.122, RSP: A40C 4E00 1269 695A DD84 E0A4 2026 0DB8 , Data page 18 not implemented = 0
20150327.091204.621, RSP: A40C 4E00 52FF FF78 0000 5593 2013 4D74 , Data page 82 not implemented = 0
20150327.091205.120, RSP: A40C 4E00 126B 6B5A 878F A0A8 20FF 8CFD , Data page 18 not implemented = 0
20150327.091205.620, RSP: A40C 4E00 106B FF5A 4991 1B01 20EB CCFD , Standard Power = 0
20150327.091206.118, RSP: A40C 4E00 136C 4754 4754 FFFF 20D7 0C62 , Data page 19 not implemented = 0
20150327.091206.618, RSP: A40C 4E00 126D 6D5A 319A 60AC 20C3 4C66 , Data page 18 not implemented = 0
20150327.091207.118, RSP: A40C 4E00 126E 6E5A 869F 40AE 20AE 8C5B , Data page 18 not implemented = 0
...
Both the system timestamp (first entry in each line) and the Rx time from extended messaging shows 500 ms between receptions. Example:

Line 2 system time - line 1 system time = 3623 ms - 3124 ms = 499 ms
Line 2 Rx time - line 1 Rx time = CD3A - 8D4E = 52538 ticks - 36174 ticks = 16364 ticks / 32.768 ticks/ms = 499 ms

Changing the channel period to 4091 solves the problem, but I don't understand the source of the problem. Clues:
1) There are no Rx Event Receive Fails in the log
2) I'm using Simulant, which shows messages being sent every 250 ms (not every 500 ms)

Any ideas?

Thanks,
-Jamie      
Rank

Total Posts: 9

Joined 2014-11-06

PM

I hope someone can give you insight. I am also having a similar issues with dropped packets in my system.      
Avatar
RankRankRankRank

Total Posts: 745

Joined 2012-09-14

PM

Which device are you using as a receiver? It sounds like you've set the channel to 2Hz instead of 4Hz, as ANT allows you to set "decimated receive times". Perhaps the API is interpreting 8082 as 16164 instead.