CompanyGateways / mytracks

Automatically exported from code.google.com/p/mytracks
1 stars 0 forks source link

ANT+ sensor won't connect #500

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Enable ANT+ sensors
2. Start record a track
3. Go to sensor state and look for ANT+ sensors hear rate. Nothing but 
"Connecting" will show on the screen. 

Using a garmin heart rate chest strap together with SE X10 Mini Pro; The ant+ 
sensor does only connect occationally. 

Using MyTracks 1.1.6.

Original issue reported on code.google.com by markus.b...@gmail.com on 21 Jun 2011 at 6:28

GoogleCodeExporter commented 8 years ago
Confirms
First run of MyTracks and the ANT+ sensor is detected. 
Second run/recording it will never connect. 

If MyTracks is reset to defaults and ANT+ support enabled again,  ANT+ will 
work again for one recording.

Tested a minute ago in MyTracks 1.1.9 on a SE Xperia Neo.
Include a log where I started MyTracks, added Ant+, start stop a recording.
Start, stop a second recording. 

Original comment by tomas.ro...@gmail.com on 30 Aug 2011 at 7:34

GoogleCodeExporter commented 8 years ago
I have the same issue. I rather always reset ANT+ device before start 
recording. I'm using Holux ANT+ HRM.

Original comment by peca.kin...@gmail.com on 1 Sep 2011 at 5:38

GoogleCodeExporter commented 8 years ago
for me it does not work even after reset to defaults. using Garmin HRM, which 
works with other apps

Original comment by Tomas.Ky...@gmail.com on 27 Oct 2011 at 12:57

GoogleCodeExporter commented 8 years ago
just add. to comment 2: running on SE Xperia Active

Original comment by Tomas.Ky...@gmail.com on 27 Oct 2011 at 12:59

GoogleCodeExporter commented 8 years ago
usind Garmin HRM on SE Xperia Active

(and Garmin Speed/Cadence sensor)

Original comment by herrmann...@googlemail.com on 13 Nov 2011 at 12:14

GoogleCodeExporter commented 8 years ago
Same thing happens with the SRM PC7 bridge, but it only happens when the device 
Id > 127 and not when the device id <= 127. Which suggests it's an issue of 
interpretting signed/unsigned bytes.

I believe if you change the method decodeShort in the class 
com.google.android.apps.mytracks.services.sensors.ant.AntMessage, from:

  protected static short decodeShort(byte b0, byte b1) {
    short value = b0;
    value |= ((short) b1) << 8;
    return value;
  }

to:

  protected static short decodeShort(byte b0, byte b1) {
    int value = (b0 & 0xFF);
    value |= (b1 & 0xFF) << 8;
    return (short)value;
  }

it should solve the problem.

Original comment by umranium...@gmail.com on 14 Nov 2011 at 1:14

GoogleCodeExporter commented 8 years ago
Here is the suggested change:
http://code.google.com/r/umraniummytracks-signed-deviceid-fix-1/

Original comment by umranium...@gmail.com on 14 Nov 2011 at 1:30

GoogleCodeExporter commented 8 years ago
Jimmy this LGTM. Do you mind pushing to head?

Original comment by sandordo...@google.com on 14 Nov 2011 at 4:59

GoogleCodeExporter commented 8 years ago
Perhaps a secondary issue, but with current version of MyTracks the software 
crashes every time I try to use the ant+ pulse monitor. 
When I stop a recording where I have tried to record my puls, with Ant+ active, 
it crashes and also whenever I try to open Sensor state during a recording or 
exiting the same when not recording.

have sent in a number of crash reports from the device, do not know if they 
reach you. 

Post it here since it is probably related but feel free to push it to a new bug 
report.
My pulse band has ID 42741 btw, form Garmin (Fr 305) used with SE Xperia Neo 
with Android 2.3.4 (4.0.2.A.0.42)
Mytracks version 1.1.10 

Original comment by tomas.ro...@gmail.com on 15 Nov 2011 at 4:01

GoogleCodeExporter commented 8 years ago
My previous post probably solved/related to bug ID 554
http://code.google.com/p/mytracks/issues/detail?id=554

Original comment by tomas.ro...@gmail.com on 15 Nov 2011 at 4:04

GoogleCodeExporter commented 8 years ago
These are logs for tests done with the SRM PC7 device, with id=127 and id=128, 
and with the old code and the new proposed code. Tests show that the new code 
solves the problem of not being able to connect after the initial pairing.

Original comment by umranium...@gmail.com on 16 Nov 2011 at 2:43

GoogleCodeExporter commented 8 years ago
I merged the change to main. It is in the release candidate for v1.1.11
http://code.google.com/p/mytracks/downloads/list

* For non-developers, please don't use the release candidate. Instead, use the 
Android Market version so that you can receive future updates.

Original comment by jshih@google.com on 16 Nov 2011 at 2:49

GoogleCodeExporter commented 8 years ago

Original comment by jshih@google.com on 22 Nov 2011 at 2:03