Custom Profiles

Custom Profiles

⚠️
This feature is unfinished and intended for advanced users.

Chainlane is built on the routing engine brouter, which allows creation of custom routing profiles.

This feature is enabled through the advanced features toggle. When turned on, you can paste a link to your profile under preset settings. Note that this must point to a text file and not a web page. On Github and Gist, use the raw link, for example:

https://raw.githubusercontent.com/abrensch/brouter/refs/heads/master/misc/profiles2/trekking.brf

The user experience around custom profiles will be reworked in the future.

Preset configuration values are available via the Velocity template language. Parameters are: surface, elevation, traffic, forests, rivers, routes, noise. Values are uppercase, as shown in the app.

For example, assigning a track penalty based on the surface preference:

#if ($surface == "PAVED")
assign trackpenalty
    switch tracktype=grade1 1.0
    switch tracktype=grade2 1.5
    switch tracktype=grade3 3.0
    switch tracktype=grade4 5.0
    switch tracktype=grade5 10.0 10.0
#elseif ($surface == "GRAVEL")
assign trackpenalty
    switch tracktype=grade1 1.0
    switch tracktype=grade2 1.2
    switch tracktype=grade3 1.5
    switch tracktype=grade4 2.0
    switch tracktype=grade5 3.0 3.0
#elseif ($surface == "DIRT")
assign trackpenalty
    switch tracktype=grade1 2.0
    switch tracktype=grade2 1.2
    switch tracktype=grade3 1.0
    switch tracktype=grade4 1.2
    switch tracktype=grade5 1.5 1.5
#else
assign trackpenalty = 1.0
#end