Ticket Created
over 4 years ago

WERETECH-10039

ANT+ Battery Status

The latest in the saga for Battery Status. I used an ANT+ dongle on my Windows Laptop, and paired it with the Eclipse Simulator. I tried both an older Garmin Cadence Sensor, and a brand new one (the one that does both ANT and BT). Same outcome. In both cases, the CIQ data field immediately gets Device State info. After maybe 30-40 seconds, the ProductInfo.serial number comes thru. Just like in real life when paired to a real Garmin Edge computer. But in both cases, even after several minutes, the Battery Status remains null.

When I pair the new cadence sensor to my actual Garmin Edge computer, the Battery Status does come up as OK within 15 seconds or so and then maybe 30 seconds later the Serial # info comes through.

Any clue why the polling code isn't seeing the Battery Status?

Oh, also, the State Update Listener is triggering, but the BatteryStatusListener is not.

  • I'm seeing between 20 and 40 seconds in the sim, so pretty close.
  • [quote userid="43945" url="~/developer/connect-iq/f/discussion/245190/ant-battery-status/1162394"]So when can we expect another page 4 update? Every few minutes? Or only upon a state change?[/quote] Pattern from spec seems to be that every 17 seconds, it is sending other than main pages, or "background pages". There are 4 other pages listed, so if all of them are sent in sequence, it can be about a minute between battery state pages. They are sent always, not just when status changes. The actual order of additional pages, and also which optional pages are sent, is fully decided by sensor manufacturer. If they think some page contains important info, they might send it more often.
  • Hey Kurev, Assuming we need to deal with actual voltages from the ANT+ pages, do you happen to know how to translate a voltage to a Battery Status? I'm mostly interested in when a voltage drops below the OK level (into LOW status or worse). Thanks!! /resized-image/__size/320x240/__key/commentfiles/fb5d84b10a5745448a7a45dafc1faa43-bef7cf5b-cf7f-40ec-813a-c5651a6c4bee/pastedimage1605007334979v1.png
  • No, I didn't setup the sendPageRequest() stuff.  Kurev posted an updated onMessage function earlier, which I incorporated.  Page 4 (not 82) held the data from my old sensor.
  • Yep, getBatteryStatus() returns nothing - for me (and my old sensor), but it works on my PowerMeter, so maybe you're right about a bug. I agree with you on your last point and I'm starting to question the effort (processing) vs. return, and the irony of expending processor cycles and power retrieving a battery status...