Ridecast logo

MTBGuru blog

May 31, 2007

Customize your map

Filed under: Howtos / tips / tricks — mtbguru @ 7:06 pm

Embedding a trip map on your own website or blog has become a quite popular feature. To do this, you insert a snippet of HTML code (an ‘iframe’), which is listed on each trip page, onto your own site.

By default, the size of the embedded map is 500 pixels wide by 500 pixels long, giving you a street map view with zoom level chosen such to contain the entire track.

From now you will be able to change these settings and customize the way your map looks.

Let’s take a look at the code:

custommaps1.jpg

At the end of the iframe’s URL, appended right after the question mark, you see attributes ‘width’ and ‘height’ (which are bold faced here). To get a different map size, just change the numbers of pixels listed - make sure though to also change the corresponding “width=” and “height=” properties following this: add 10 pixels to width, and 65 pixels to height, to avoid ugly scroll bars. for instance, this code creates a 600 pixels wide by 300 pixels tall map:

custommaps2.jpg

You can also add new attributes to change the appearance of the map:

  • fit: default = 1. When set to 0, the map won’t scale to fit the track any longer, and you’ll have to provide your own zoom parameter (see next item).
  • zoom: Google maps zoom level. A higher number increases the zoom level and will show more detail (if available).
  • type: default = 0. When 0 -> show street map. When 1 -> show satellite view. When 2 -> show hybrid satellite + street map view
  • first: default = 1. When 1 -> show a marker on the first point of the track.
  • last: default = 0. When 1 -> add an additional marker to indicate the last point of the track and center the map around this marker.

You can append these to the iframe’s URL while separating them with ampersands; you can specify the options in any order you want and you can omit them if you’re happy with the default value.

This may all sound a bit complicated but it is very simple, just take a look at this example:

custommaps3.jpg

The changes with respect to our original code are indicated in bold: the map size has been changed, a zoom level of 12 is set (the map doesn’t simply just fit the track any longer) and a hybrid satellite/street view is shown.

If you’re using embedded maps or are planning to do so, make sure to play around with this, and give your map the look you prefer.

May 15, 2007

Sharing your trip

Filed under: General MTBGuru stuff, Howtos / tips / tricks — mtbguru @ 6:28 pm

When you’re creating or editing a trip, your browser shows you an ‘edit view’ of the trip page - its URL is reflecting this. Obviously only you (the trip owner) can see such ‘edit view’ and edit your trip, and this presented a bit of a problem: when people wanting to share their trip with others just copied and pasted the URL (of the ‘edit view’) from their browser’s address bar, the page that URL directed to wasn’t visible to others. The rather clunky solution we had for this was the ‘View Trip’ link in the sidebar, that toggles the page to a ‘view mode’ which is visible to others.

Simpler is better though, so we added a snippet at the bottom of the trip page (shown in both edit and view mode) which makes sharing the trip and trip page URL obvious (screenshot below). It also includes a link to post to your del.icio.us bookmarks (we may add other bookmarking services later). Thanks midtoad for the suggestion! Other suggestions are always welcome, at mtbguru@mtbguru.com.


Sharetrip

April 28, 2007

Setting trips public or private: update

Filed under: General MTBGuru stuff, Howtos / tips / tricks — mtbguru @ 2:32 pm

Up until now, when you created a trip on MTBGuru, there were two different default privacy settings in use:

  • When you had created the trip using ‘Add a Trip‘ in the sidepanel, the trip was by default ‘Public’, with comments disabled.

  • When you had created the trip using ‘Upload GPS Data‘, or out of one of your GPS files in ‘My GPS Files’, the trip was by default ‘Private’.

The thinking behind this was that when uploading straight GPS files, the user’s privacy would be better served by keeping the default setting of the resulting trip and the data private; this as opposed to ‘Add a trip’ where by default the user would ‘publish’ or add the trip to the public MTBGuru trip base.

On the other hand this was all quite confusing, so we just implemented a new and better way of tackling this:

  • When you now create a trip using ‘Upload GPS Data’, instead of the ‘Create Trip’ button after the upload you will be presented with two ‘Create Trip’ choices: [Public] or [Private] (see screenshot below). As you need to select one of either to create the trip, there is no need anymore for a ‘default setting’.

  • Createtripexample2




  • Creating a trip using ‘Add a Trip’ remains unchanged and still results in a default ‘Public’ setting; comments are enabled by default now as well (screenshot below).

  • Create trip example



Of course, afterwards you can still change trip settings on the fly, as before.

And if you want to switch a whole set of your trips at once from Private to Public or vice versa, you can make use of the ‘Choose Action’ feature and the checkboxes on ‘My Trips’, as was previously possible as well (screenshot below).


Convert settings

March 6, 2007

GPX file Howtos

Filed under: GPS, Howtos / tips / tricks — mtbguru @ 1:36 am

A quick recap and list of useful links related to uploading and using GPX files on MTBGuru:

When you create trips on MTBGuru based on GPX files you’ve uploaded, the resulting trip pages may not always look the same:

  • We’re scanning the GPX file for tracks - lists of waypoints or routes are currently not supported. If the GPX file doesn’t contain at least one track, you won’t see a map on your trip page. Read more here

  • Most GPX files that originate from GPS units will contain elevation data, but this is not necessarily true - some GPS devices or software tools won’t save the elevation data in the file. Unless the latter is the case, you’ll see an elevation profile (elevation versus distance) on your trip page.

  • Not all GPX files will contain timing information - timing info is needed for the automatic photo geotagging to work, as well as to create the distance versus time and elevation versus time graphs. Most GPS units and loggers do allow you to save the timing info though, check your unit’s manual for more information or experiment with the settings.



More information and details on downloading GPX files from your GPS device are given in this blog post.

Alternatively, read this if you want to use GPX files you find on the site and upload them to your GPS to retrace the given trip.

Finally, here we describe how we treat multiple tracks in GPX files.

February 17, 2007

Add video and audio to your trip page

Filed under: General MTBGuru stuff, Howtos / tips / tricks — mtbguru @ 1:26 am

Did you know you can add video and audio clips to your trip page?

Check out for instance this trip, a hike to the summit of Mount Tyndall in California’s Sierra Nevada, where a Google Earth flyover movie was added to the trip description field (screenshot below).


Embedvideoscreenshot

MTBGuru isn’t hosting the video files but you can use material you’ve stored or found on YouTube or any other video sharing site that allows you to embed movies on external sites. Just copy the snippet of code these sites point you to and paste it in the trip description box. Here’s what such code looks like (in ‘Edit Description’ mode):


Embed edit

The same works for audio. If you want to add a tune to your trip page, share some footage or perhaps an entire podcast in which you describe your adventures, you can use web apps such as Podomatic to create the podcast or upload mp3 audio files, and then embed them on your trip page. As an exampe, check out this trip of mine, with some FunkyLondon sounds for increased enjyoment…
Of course, make sure you respect the terms of use of these sites and any applicable copyrights.

February 11, 2007

How to undo stripped (disc brake rotor) bolts

Filed under: Howtos / tips / tricks — mtbguru @ 6:56 pm

Now for something completely different: last weekend I needed to perform a simple bike maintenance task: replace the worn out front rotor of the disc brake on my mountain bike. I’d done this before, and it’s one of the easiest things to do: take out wheel, undo the six bolts that keep the rotor on the hub, put new rotor on.

It becomes less straightforward however when you manage to strip one or more of the bolt heads. For obvious reasons, these bolts which go in the threads of the hub are treated with (blue) Loctite; they do tend to get stuck pretty well in there. The bolt heads are of the Torx type and I managed to undo all but one of them with the wimpy Torx tool I was using. Unfortunately, the last one turned out to be really stubborn, and my screwing around with it (no pun intended) resulted in this:

stripped torx head

Visions of taking drastic measures such as throwing a blow torch at the problem, buying an impact wrench or having to accept defeat and go to the shop arose… luckily however I needn’t fear, as there is a much simpler and quite efficient trick, which I’d like to share in this post.

I remembered to have read somewhere that a simple trick was to cut a slot in the bolt head and then use a regular screwdriver to undo the bolt. Time to try this out so I took off and got this mini-hacksaw ($6 in ACE Hardware):

hacksawhacksaw 2

It worked like a charm. The bolt material turned out to be relatively soft, and the finer blade that came with the saw was just right.

slotbolt undo

When the slot was deep enough so that I could apply some decent force with the regular screwdriver, the bolt went off fairly easily.

boltsnew rotor

Time then for new bolts and a new rotor. The blue Loctite was conveniently already applied on the bolts that came with the new rotor.

This is how the old rotor looked like:

old rotor

It was getting worn out significantly, notice the thinned down center area (where the pads grab). With the new rotor, braking power immediately felt much higher.

Note to myself: next time use a proper Torx tool to undo the bolts:

Torx tools
(Wimpy and Beefy tool)

February 5, 2007

Text markup using Textile

Filed under: Howtos / tips / tricks — mtbguru @ 10:11 pm

Trip descriptions and trip comments on MTBGuru are entered and edited using simple text boxes, into which you can type your lines just like you’d do in any regular text editor.

However, there’s much more you can do with it: we support Textile, a simple text markup language, or, as its creators describe it, a ‘Humane Web Text Generator’. It eliminates the need to know HTML or juggle around with HTML tags anytime you want to do simple things like insert a hyperlink. Instead, you have a very simple and elegant yet versatile and powerful way to achieve this, as well as perform a host of other text structuring and formatting tasks. It hardly takes effort to memorize the simple syntax, and this brief Textile reference nicely summarizes everything.

For instance, to create a hyperlink, put the word(s) that make up the link anchor in between double quotation marks, followed by a colon and the URL you want to make it point to (without spaces in between):

This is "a link":http://www.thispointstomywebsite.com to my web site.

This is parsed when you’re done editing and turned into a regular hyperlink in your description or comment box:

This is a link to my web site.

It’s also very easy to format your text. For instance, use h1. (or h2., h3. etc) as a prefix to create headers. Lists are generated by using the star (*) or pound (#) symbol as prefix. And so on. Check the Textile reference for many more examples. It’s vastly more convenient than using HTML to mark up or format your text (no need to worry about properly closing your tags etc).

And the nice thing is: Textile also understands regular HTML code - so you can mix up simple text, Textile syntax and HTML code in the same document if you wanted to.

February 2, 2007

Set up your home map

Filed under: General MTBGuru stuff, Howtos / tips / tricks — mtbguru @ 1:10 am

It’s really cool to see people posting trips from all corners of the world: for instance Australia, Croatia, Taiwan, besides numerous states in the US.

When someone arrives on the site, be it a registered user or not, we use services like HostIP and GeoIP to try to figure out where she or he is coming from, in order to center the home page’s map this visitor will see on this location. These services essentially consist of databases relating IP addresses to geographic locations.

Instead of some default location the main map will initially zoom in and center on an area which is most likely the area of interest to this person. Unfortunately, the databases are not 100% accurate; also, there are cases where you’ll be using a different IP address that may alter this location - for instance when you’re using public WiFi or when you’re traveling.

To overcome these issues, we’ve now implemented a feature that allows you to control and set your home map’s initial location. Look for the two buttons on the right top corner of the map, just below the ‘Hybrid’ button (screenshot below):

  • Set Home: click on this button to set your home location to the current view of the map.
  • To Home: click on this button and the map will move back from wherever you’re at to the home location you’ve set.

Homemapbuttons

So in case you’re not happy with the map you see when you log in or land on the site, you can now navigate (zoom/pan) to an area that you’d like to have as your home map and use the ‘Set Home’ button to save this view. This setting overrules the GeoIP detection.

We use cookies to do this, so you’ll need to have these enabled in your browser - the only thing they’ll do is store a map coordinate on your computer so your browser knows where to point your home map. And of course, we’re not sharing any of this information with anyone, we are strongly committed to ensure the privacy of our users, as we state in our privacy policy.

January 23, 2007

Comments and comment notification

Filed under: Howtos / tips / tricks — mtbguru @ 9:12 pm

When you create a trip on MTBGuru, you can enable other users to add comments by adjusting the ‘Trip Settings’ in the sidebar (see screenshot below):


Commentsscreenshot2

Click ‘Change’, then switch the ‘Allow Comments’ field to ‘Everybody’.
By default, comments are enabled but only registered users of MTBGuru can leave comments, in order to avoid comment spam.

If a trip is public, also its comments will be visible for anyone visiting the site.

You can get notified by e-mail when someone left a comment on one of your trips by our ‘Comment Notification’ feature. Go to ‘User Settings’ (sidebar), and you’ll find the ‘New Comments Notification’ field (screenshot below):


Commentsscreenshot

There are three settings. ‘Never’, in case you don’t ever want to receive a notification e-mail, ‘Immediately’, so you’ll receive an e-mail for every new comment that gets posted on one of your trips, and ‘Max. once per day’, then you’ll receive at most one notification e-mail per day. The latter is the default setting.

Leaving comments works pretty much like leaving comments on blogs - you can use html tags to insert hyperlinks etc. Moreover, we also support Textile, a very simple and elegant text markup language. More about that in a later blog post.
Finally, trip owners have of course the ability to delete comments on their trip.

Update 6/19/07: There seems to be a bug at work preventing deletion of comments - we’ll try to fix this asap.

January 10, 2007

Uploading trip data to your GPS

Filed under: GPS, Howtos / tips / tricks — mtbguru @ 10:51 pm

In a previous article we talked about some tools to download data from your GPS unit and save into GPX files. Now we’d like to outline what you can do with GPX files you’ll find on MTBGuru (which aren’t necessarily yours).

For each public trip on MTBGuru that has GPS data, you can download the associated GPX file (using the ‘Download GPX file’ link in the sidebar) as well as a Google Earth (KML) file. By browsing around the map, using the search box or by clicking the ‘Recently Added Trips‘ link you may find a trip or ride that catches your interest. Say you want to do this ride yourself: the trip summary gives you an idea of what to expect in terms of distance and elevation gain and if there’s timing info you’ll know even better what you’re up for. You can now use the GPX file to send the data to your GPS unit, so you’ll be able to retrace the given route.

Some units allow a straight upload of the entire GPX file with its waypoints and tracks. In some cases though, there are complications:

  • For instance, on some Garmin units (e.g. the Etrex family) the size of tracks you can upload is limited to 500 points (even though they can *record* tracks of much larger size) - larger tracks will be truncated
  • Some units don’t allow upload of tracks, only waypoints and/or routes

A quick GPS terminology 101 may be in place here:
A ‘route’ is a sequence of waypoints that indicates a certain route. A ‘waypoint’ is basically a set of three numbers (latitude, longitude, elevation) indicating a point in space, usually on the surface of the planet ;). A track is a sequence of (recorded) waypoints but generally also contains time information.

GPX files you download from public trips on MTBGuru contain tracks. The time info in this file is stripped but all spatial information (long,lat,ele) from the trip is available. Only trip owners have access to the time info in the GPX - using the ‘My GPS Files’ link in the sidebar they can always retrieve the original uploaded data.

As mentioned before, uploading these files directly to your unit can sometimes result in truncated data and other problems. However, you generally don’t need that many points to navigate and retrace a given trip. You can use a host of software tools (e.g. Garmin’s MapSource on PC, Routebuddy on Mac OS X) to create routes with a limited number of points from tracks and upload these instead.


GPSBabel filter

Our favorite tool, GPSBabel, has a very neat and simple way to achieve the same: by using its ‘filters’ you can automatically reduce the amount of points in a GPX file. Select your GPX file as input file and set up your filter as shown in the screenshot (using distance between the points as filter); the output file will be a GPX file with a reduced number of points. You can change the amount of points by changing the merge distance between points.

Next Page »