If you use Strava and a Garmin eTrex 30 and care about that the climbing figures you get are accurate, then you may be disappointed that Strava is ignoring the barometric data the eTrex 30 gives you and working it out roughly by itself, presumably through the average elevation of large map tiles or similar.
A generic “with barometer” device is provided to force the system to use the elevation data from TCX and GPX file types. One only needs to add “with barometer” to the end of the creator name.
Easy enough with a text editor, but a bit of a faff to do every time you upload.
So I’ve created some scripts to make it easier. My idea is that these scripts will be kept in the root directory of the GPS so that they’re always accessible at the same relative path to the file(s) they are editing. There are different scripts for different operating systems, so they should work even on unfamiliar computers. So when travelling and using other people’s computers, they should still work.
This Windows Script uses PowerShell 1.0, so should work on Windows XP SP2 or later. I’ve tested it on Windows 8 and 10. It’s the first bit of PowerShell I’ve written, so any comments are welcome.
Opening up a powershell window and running this script isn’t a lot quicker than editing the file manually, so I’ve also created a clickable shortcut to the script as described here. This avoids having to change the script execution policy on the machine, making an exception for this script only.
- In Windows Explorer, create a new shortcut in the root folder of the GPS device (this might be E:\ or F:\).
- Right-click on the new shortcut, and choose “Properties”.
- Change the shortcut’s Target to the following:
%SystemRoot%\system32\WindowsPowerShell\v1.0\powershell.exe -ExecutionPolicy Bypass -File "add_barometer.ps1"
- You may also want to name the shortcut something like “windows_add_barometer.ps1.link”.
- Click “OK”.
This Linux script uses generic linux shell commands and has been tested on Ubuntu 14.04 and 16.04. It can be run from the command line with: sh linux_add_barometer.sh or possibly by double-clicking the file if you use one of the methods described here. I’m certainly not a shell expert, so again, your comments are welcome.
I’m told that it’s possible to run *nix shell scripts under Mac OS, so the Linux solution may work with some tweaking. I’ll update this post when I’ve tried it.