tuyndv / mytracks

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

SRM ANT + Bridge Sensor Not Working On Current Handsets #567

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Mercurial clone with changes to be reviewed:
http://code.google.com/r/umraniummytracks-sensorfixes/

Revisions to be pulled from that clone (or "all"):
All. More to come soon regarding connecting to Sensors on opening the sensor 
screen.

Purpose of code changes on the clone:

As discussed in My Tracks Google Groups 
http://groups.google.com/group/mytracks/browse_thread/thread/4e59cc49591311ea/87
1e98368dd3cca5#871e98368dd3cca5   MyTracks will not connect to the SRM Power 
Control 7 (PCS7). I think MyTracks was used with a phone specially hacked to do 
ANT + for the 2010 Tour De France but doesn't work with the Android ANT + 
phones now available. The code submitted has been tested with a Sony Ericsson 
XPeria ARC and Xperia X10 Mini Pro.

There are two changes.

The first changes the ANT+ PCS7 Sensor Manager (originally AntSRMSensorManager 
class) to using the ANT+ Heart-rate Monitor (AntDirectSensorManager class) as a 
template.

The second changes the sequence of events required for ANT+ initialisation 
between the initial attempt and subsequent reconnection attempts. Previously, 
the subsequent ANT+ reconnection attempts would always fail.

When reviewing my code changes, please focus on:

First change:
com.google.android.apps.mytracks.services.sensors.ant.AntSrmBridgeSensorManager

Second change:
com.google.android.apps.mytracks.services.sensors.ant.AntSensorManager

Note that this will also make the connection to the ANT+ heart rate sensor more 
reliable as it too would not have connected if it failed on the first attempt.

Original issue reported on code.google.com by umran...@gmail.com on 14 Sep 2011 at 7:33

GoogleCodeExporter commented 9 years ago
As I said in the mailing list thread this current change is a bit of a mess.  
Please clean it up to be one commit with just the files you want to change and 
update us when that is ready.

Original comment by sandordo...@google.com on 16 Sep 2011 at 4:09

GoogleCodeExporter commented 9 years ago
Hi,

The code for this fix is available at this clone:
http://code.google.com/r/umraniummytracks-srm-bridge-fix/

Please review.

Thanks.

Original comment by umranium...@gmail.com on 3 Nov 2011 at 12:58

GoogleCodeExporter commented 9 years ago

Original comment by jshih@google.com on 18 Nov 2011 at 10:18