Giter Club home page Giter Club logo

atrainingtracker's Introduction

aTrainingTracker

An android app for tracking your sports activities (supporting ANT+ and BTLE).

ANT+ logo ANT+ HR logo ANT+ run speed logo ANT+ bike speed logo ANT+ bike cadence logo ANT+ bike speed & cadence logo ANT+ bike power logo ANT+ temperature logo
Featuring certified wireless ANT+™ connectivity.
Visit www.thisisant.com/directory for compatible products.

This Android app is for the really serious athletes.

For those, who want to track all the details of every training session but do not want to waste their time.
This app is for all the athletes, who want a powerful yet simple to use app to track their training.

Once configured and paired with all your remote sensors, you only have to press start when you start your training session and stop when you are done. Except for the name of the workout, everything else should go without further interaction. The app automagically determines the sport and the equipment (shoe or bike) you used during a training session based on the remote sensors that where used during this session. Moreover, the app can upload the files to your Dropbox. So when you have finished your shower, the data is already on your computer, waiting to be analyzed with your favorite software like WKO+, or Golden Cheetah.

Main Features:

  • Open source.
  • Support of many ANT+ sensors (heart rate, run speed and cadence, bike speed, bike cadence, bike speed and cadence, bike power, temperature/environment).
  • Support of many Bluetooth LE sensors (heart rate, run speed and cadence, cycling speed, cycling cadence, cycling speed and cadence).
  • Pair an unlimited number of remote (ANT+ or Bluetooth) sensors, e.g., a speed or cadence sensor on each of your bikes.
  • Simply swipe through the different configurable views
  • Export to TCX, GPX, CSV, and Golden Cheetah.
  • Upload to Dropbox.
  • Upload to various online communities: Strava, TrainingPeaks, Runkeeper.
  • Use your Pebble to display values.
  • When the app starts, it searches for all paired sensors and takes the data from the "best" available one.
  • The sport type (run, bike) is derived from the available remote sensors. When no remote sensors were available, the sport type is guessed from the average speed.
  • The equipment is synchronized with Strava. The equipment used in a training session is then derived from the available remote sensors.
  • Simple setting of the calibration factor. You only have to input the measured and true distance.

More than a decade ago, I had a dream.

Back then, I studied mechatronics, jogged from time to time, and did my first tries in writing code for mobile phones, so called Midlets. When jogging, I wore a heart rate strap and wrist watch to display the heart rate values. My wrist watch could not store the heart rate data but there were very very expensive ones available that could do this. Moreover, the first version of speed sensors for running (very clumpy ones) were appearing. Once, I thought about the amazing possibilities that open up, when a mobile phone could get all the data and store it. Most obviously, a mobile phone has an almost infinite amount of storage (even back then) and it is simple to get the data from the phone to the computer (honestly, back then this was not as simple as today). Even better, the mobile phone has a huge display and can do complex computations. Only the possibility to display the data on a wrist watch seemed to be out of reach.

Over the years, I increased my running volume, added swimming and cycling and became a passionate triathlete.

Now, this dream becomes true.

In 2011, I realized that there are smartphones available that support the ANT+ protocol, the de facto standard for transmitting fitness data (heart rate, speed, cadence, power, ...). Thus, I became excited and bought such a smartphone but non of the available apps were powerful enough and simple to use to satisfy me. So I started coding ...

Over the years, I invested much more time in developing this app than training. Now, that my time becomes more and more limited I published the app here on GitHub under an open source licence.

Support

You are more than welcome to support the development of this app by

  • Adding feature requests or bug reports here on github. Simply add an issue on https://github.com/rainerblind/aTrainingTracker/issues.
  • If you are one of the blessed persons who learned to code in Java (or Kotlin) you can help to fix the bugs and realize the feature requests by contributing to the code.
  • Translate the app to other languages. Therefore, you just have to translate the phrases within a file. No coding required. This should be a piece of cake for your mother tongue.

atrainingtracker's People

Contributors

gerhardol avatar rainerblind avatar transifex-integration[bot] avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

atrainingtracker's Issues

Strava privacity not works

Hi and thanks for this awesome app. When i tried to sync strava activities with privacity chech on, it upload public to strava. I delete the account and linked again, and nothing do. I change the privacity in strava to only me and now it works, but i think is not the solution. Any idea?

Oooops i see that it didn't work anymore, sorry for open the issue. What a pity.

"Upload to dropbox" fails to enable with firefox opening tabs in the background

When Firefox is configured to open tabs in the background, the "Export Data to Dropbox" checkbox gets checked immediately, but even after switching to Firefox and authorizing the app it doesn't persist, i.e. after switching to the main settings menu and returning into the upload menu, it's disabled again.

Configuring Firefox to immediately launch when an app requests to open a tab fixes this, but it isn't obvious.

Coospo BK8A speed+cadence sensor

I tried to connect a Coospo BK8A but aTrainingTracker doesn't find it, neither via BLE nor ANT+. The BLE Scanner app finds it and displays the Cycling Speed and Cadence service and the nRF Toolbox app can connect and display realistic sensor data:

Screenshot_20200904-164208
Screenshot_20200904-164833
Screenshot_20200904-164719

The advertised measurement UUID matches the one in app/src/main/java/com/atrainingtracker/banalservice/devices/bluetooth_le/BluetoothConstants.java, so I'm stuck.

Adding option to live stream of sensor data to Matlab or Python trough a MQTT Brocker

To my knowledge, there is no live stream application of ANT or BLE sensor data to Matlab or Python available to this date. Integration of the following code could solve this problem

https://www.thisisant.com/forum/viewthread/7360/

it is a script for the Rasperri Pi, which also should work on Linux. I don t know wether it is possible to integrate this script into a training tracker, or part of the script. But I miss such a stream and It would be great to have it integrated into a training tracker.

Problems with .csv files and database software

.cvs files not always have the same number of fields with a training tracker. When I use two Polar OH1 sensors alternatively, a training tracker adds in the last column the sensor number of the polar OH1. For reading in a data base software, I always have to edit the .csv file and remove the last column to avoid problems with the database software.

Per-Lap Average Values

It would be nice to be able to display values like Average Power for the current lap.

This would simplify interval training.

This feature would also be useful for values like cadence, speed, and heartrate, for people looking to target those for a specified duration too.

Problems pairing two sensors of the same type

Again a repeat, but necessary for clarification. A training tracker cannnot pair two sensors of the same type. I had the problem with two Polar OH1 sensors and two Polar H7 sensors. With Garmin watches for instance it is no problem to use sensors of the same type. I could solve the problem of using two Polar OH1 sensors, one recording sensor data, the other charging, by pairing one over BLE and the second one over ANT+. I had to remove the previous paring, reboot the smartphone and pair to the second Polar OH1 to solve the problem.

Sensor value not reset when changing field.

There is a bug in the cycling power default where:

1 - Edit Speed field.
2 - Change Sensor from best to something else (e.g. my Bluetooth speed sensor).
3 - Change Speed field to something else (e.g. time total).

This new data field attempts to read from the previously set sensor, but this sensor of course gives no meaningful data. Additionally, from this new field I can no longer change the sensor. To fix this I must change the data field back to Speed, reset the Sensor to best, then change the field to time total.

Resume function does not work properly

Sorry for repeating myself, but I want to clarify where I had issues with a training tracker. The resume function does not work properly. After a restart of a training tracker, a training tracker offers the option to resume the previous file. Unfortunately, a training tracker offers me several times to resume the previous file, and seems to resume sometimes an older file instead of the latest. Reinstallation of a training tracker did not solve the problem, as well as a hard reset of the smartphone.

Tweaking aTrainingTracker for Assault Airbike

Hello Rainer,

I forked your project and tweaked BTLEBikeSpeedDevice to be used as power sensor and cadance sensor for Assault Airbike. It was easy, but works only partly: the power is shown on the screen but the cadence is not.

Would you be interested to add airbike support to your app? Could I help?
Could you tell me why frequency indicator still shows "--" on the screen?

Screenshot_20200501-153321

Regards,
Dimitry

Check this commit to see what I changed so far:

dpolivaev@477b35d

Occasionally adds a large distance during recording when screen turned off

Hello,
Firstly, Thankyou for such a versatile app that nearly always "just works."

The last two rides I have recorded, I have had a bit of an issue with recordings adding a large number (in the order of 100km) to the distance at a point during the ride. This seems to coincide with when I would have stopped and checked my phone, then turned the phone screen off. I don't recall having issues with screen turnoff interrupting the app before.

I am running the app on a Samsung S10e running Android 10 and One UI 2.0, talking Ant+ to a Garmin speed sensor and a Garmin cadence sensor. Optimise battery usage setting is set to "Not optimised" and it appears to be running in the background successfully. When riding I generally have the phone with screen off in my pocket.

If it helps, the notification in the notification bar after the jump in distance would also say that the active time is currently over a day, when it would only have been going an hour or two at most. The distance in the distance box in the dashboard shows the incorrect distance and the distance in the workouts tab shows the correct distance.

I have attached cut down versions of the TCX files exported by a Training Tracker with the points around near where the issue is. Two points from one of them are also here below:

Do you have any idea why this is happening or any sugestions to resolve it? Thanks in advance.

CutDownTCXFiles.zip

<Trackpoint>
  <Time>2020-06-14T06:23:08Z</Time>
  <Position>
    <LatitudeDegrees>-36.21572042987399</LatitudeDegrees>
    <LongitudeDegrees>144.88646121667452</LongitudeDegrees>
  </Position>
  <AltitudeMeters>59.134090423583984</AltitudeMeters>
  <DistanceMeters>13574.28</DistanceMeters>
  <Cadence>0.0</Cadence>
  <Extensions>
    <TPX xmlns="http://www.garmin.com/xmlschemas/ActivityExtension/v2">
  <Speed>0.0</Speed>
    </TPX>
  </Extensions>
</Trackpoint>  
<Trackpoint>
  <Time>2020-06-14T06:23:09Z</Time>
  <Position>
    <LatitudeDegrees>-36.215703705475136</LatitudeDegrees>
    <LongitudeDegrees>144.88646074463688</LongitudeDegrees>
  </Position>
  <AltitudeMeters>59.83164978027344</AltitudeMeters>
  <DistanceMeters>139946.448</DistanceMeters>
  <Cadence>1.0770432</Cadence>
  <Extensions>
    <TPX xmlns="http://www.garmin.com/xmlschemas/ActivityExtension/v2">
  <Speed>7.8678561104</Speed>
    </TPX>
  </Extensions>
</Trackpoint>

Negative speed using bluetooth speed and cadence sensor.

During my first session using this device, I noticed my total distance was wiped out when stopping the bike. I was able to replicate this by starting and stopping the bike several times and noticed the app detected a very large negative number for a second, undoing my total distance.

As seen in the screenshots, you can see the negative numbers.

I propose that aby negative numbers be ignored and simply treated as 0.

Screenshot_20210101-213303
Screenshot_20210101-213537

Magene H64

My Magene H64 HR ant+/btle sensor is having a hard time pairing. Says it pairs in btle mode, but no hr data. Never seen in ant+ mode. Is it possible for me to help provide the data needed to help support this device?

I have some limited experience in Java (even some in Kotlin).

Add dark mode

Change the display from white background and dark text to black background and white text to save battery on OLED displays.

Night/dark mode causes constant closing and reopening of the application

I wanted to switch the displays to night/dark mode but once I did that and I open/view it the application keeps closing and reopening itself. At least that seams to be what it's doing.
When I switch the display back to system settings or to Day/bright it works fine again.
I'm using v4.2 installed from the Play store on a OnePlus 5T running Android 9 with a dark theme.

Unstable sensor connection to heart rate sensor

I really appreciate a training tracker. Especially I love the feature that it is possible to record sensor data to the data analysis software friendly .csv format.

Unfortunately, I did not manage to get a stable sensor pairing. Again and again, sensor pairing is lost, and new pairing to a sensor is only possible after a complete hard reset of the smartphone.

I tried with Forerunner 235, Polar OH1, and Polar H7. The best experience I made with Polar H7. But also there I loose the heart rate signal after a while.

I m using a setup where sports sensors are used 24 * 7. With the Polar H7, sometimes it was helpful to moisture the chest strap, and then it was working again. But I still did not manage to get a stable connection to a heart rate sensor which is working 24 * 7.

Can someone confirm or recommend a specific heart rate sensor type which is working without any issues and problems with a training tracker?

Fails on Android 10, worked fine before upgrade to Android 10.

aTrainingTracker worked perfectly for me on my OnePlus6 until a few days ago on Android 9.

Then, a few days ago I got an update to Android 10 (official update from the maker of the phone).
Since then, aTrainingTracker doesn’t work anymore ☹.

aTrainingTracker-fails-android10
aTrainingTracker-fails-android10-android-version-information

It still starts tracking but tracks only a few dots and then it seems to stop. And then it fails saving the files to SD-card und uploading them to Strava.

Ability to pause recordings without losing averages

As it is, when you hit pause, your averages fall drastically and it is near impossible to get it back. It makes it really annoying to stop for anything, especially when if you go back to the Strava app and hit pause it actually pauses like it should. I love this app, but this is the only thing that bothers me. It is almost like the app is just filling in zeros for everything while it is paused, because the averages don't fall as much if you just leave it unpaused and let it average it out like normal. I would like the pause button to freeze everything in time, do not collect any data from any sensors while it is paused, and reconnect to the sensors when you unpause. As it is right now, when you hit pause, you see your averages freefall in real time and it exports that way to Strava.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.