Author Topic: [Tasker] BRouter routing files / Geonames downloader  (Read 365 times)

Offline tapio

  • Expert
  • Master of Locus
  • ****
  • Posts: 805
  • Thanked: 184 times
    • View Profile
[Tasker] BRouter routing files / Geonames downloader
« on: January 05, 2022, 17:48:35 »
Hi guys,

here's a Tasker script which downloads BRouter routing files (rd5). In the task, just adjust the rd5 path to match your own system. It will then download and overwrite exactly those rd5 files it finds in that directory. Task has no error handling whatsoever.

BRouter rd5 files are typically in:
//ExtOrIntSD/Android/media/btools.routingapp/brouter/segments4/

Please execute task in a reasonable manner and have server load in mind.

HTH.

https://taskernet.com/shares/?user=AS35m8kdDIMDeveQcQfRglam%2Fah1mTW%2FWcg05FZ39c0i1q%2F77iY3E7cIwxCkXqJTaTA%3D&id=Task%3ALocusDownloads
« Last Edit: January 06, 2022, 17:22:29 by tapio »
LM4 USER ID: 1AACAFF2A2
 
The following users thanked this post: freischneider

Offline Andrew Heard

  • Expert
  • Professor of Locus
  • *****
  • Posts: 1021
  • Thanked: 89 times
    • View Profile
  • Device: Samsung Galaxy A5 v8.1, Samsung Tab A7 v10
Re: [Tasker] BRouter routing files downloader
« Reply #1 on: January 05, 2022, 22:44:44 »
@tapio - can you please explain the underlying purpose of your script, now that LM has BRouter built-in with behind-the-scenes handling of .RD5 files, the average user (like me) no longer needs to be aware of their existence? Note to myself - .RD5 files are stored in Locus/router/segments4 directory.
LM4.5.7.3 GOLD
user ID 142d400c7
 

Offline tapio

  • Expert
  • Master of Locus
  • ****
  • Posts: 805
  • Thanked: 184 times
    • View Profile
Re: [Tasker] BRouter routing files downloader
« Reply #2 on: January 05, 2022, 23:06:43 »
Well, what you say applies only to gold subscription of LM4 afaik. May also be useful outside of Locus context.
LM4 USER ID: 1AACAFF2A2
 

Offline Andrew Heard

  • Expert
  • Professor of Locus
  • *****
  • Posts: 1021
  • Thanked: 89 times
    • View Profile
  • Device: Samsung Galaxy A5 v8.1, Samsung Tab A7 v10
Re: [Tasker] BRouter routing files downloader
« Reply #3 on: January 06, 2022, 00:17:41 »
I was about to delete my post, but you were too quick
also I guess - to force a manual update/ download from BRouter server if LM is not working correctly
LM4.5.7.3 GOLD
user ID 142d400c7
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12603
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: [Tasker] BRouter routing files downloader
« Reply #4 on: January 06, 2022, 08:28:01 »
I see two more differences:

1. app takes care of updates fully automatically in the defined interval, which I consider a huge benefit.

2. app and also BRouter offers updates over "diffs" > only changes are downloaded. The difference is, that in the case of BRouter if you do not update within 10 days, you always download the completely new file. Which is quite slow in the case of BRouter if I remember correctly. Locus Map offers diffs up to 60 days. And even if you download full files, it should be really fast as we have a server hosted on 1GB network.

Otherwise routing engines are still identical, so there should be no difference in computed routes (in case of identical routing profile).
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline tapio

  • Expert
  • Master of Locus
  • ****
  • Posts: 805
  • Thanked: 184 times
    • View Profile
Re: [Tasker] BRouter routing files downloader
« Reply #5 on: January 06, 2022, 09:01:21 »
Aside from that - it's easily extendable to Geonames download + unpacking - will definitely add that.
It's Taskers DNA (ie. Profiles and Triggers) to automatically execute tasks... 😊
Menion, no, downloads are fast here: http://brouter.de/brouter/segments4/
But we should not stress the server, I think I read the brouter downloader ui is throttled on purpose.
« Last Edit: January 06, 2022, 09:07:14 by tapio »
LM4 USER ID: 1AACAFF2A2
 

Offline Menion

  • Locus team
  • Professor of Locus
  • *****
  • Posts: 12603
  • Thanked: 835 times
    • View Profile
    • http://www.asamm.com
  • Device: Pixel 5, A12
Re: [Tasker] BRouter routing files downloader
« Reply #6 on: January 06, 2022, 10:14:07 »
Oki, thanks, good to know :). Then we will have to figure out any bigger benefit then just "easy-to-use" :)
- Official help (ideas, questions, problems): help.locusmap.eu
- Advanced topics, sharing of knowledges: you're here!
- LM 4 Beta download, LM 4 final download
 

Offline tapio

  • Expert
  • Master of Locus
  • ****
  • Posts: 805
  • Thanked: 184 times
    • View Profile
Re: [Tasker] BRouter routing files downloader
« Reply #7 on: January 06, 2022, 13:53:27 »
« Last Edit: January 13, 2022, 14:15:00 by tapio »
LM4 USER ID: 1AACAFF2A2
 

Offline freischneider

  • Expert
  • Master of Locus
  • ****
  • Posts: 998
  • Thanked: 114 times
    • View Profile
  • Device: Xiaomi Redmi Note 10 Pro, Android 11, Locus Map 4 Gold, Locus-Device-ID: aa54a2bc9
Re: [Tasker] BRouter routing files downloader
« Reply #8 on: January 06, 2022, 17:01:56 »
I get the message: Too often ? More than 7 files (0) ?

I have only adjusted the path in the 1st set to my system.
 

Offline tapio

  • Expert
  • Master of Locus
  • ****
  • Posts: 805
  • Thanked: 184 times
    • View Profile
Re: [Tasker] BRouter routing files downloader
« Reply #9 on: January 06, 2022, 17:06:22 »
I get the message: Too often ? More than 7 files (0) ?

I have only adjusted the path in the 1st set to my system.
I removed a stupid check which caused your error. Redownload https://taskernet.com/shares/?user=AS35m8kdDIMDeveQcQfRglam%2Fah1mTW%2FWcg05FZ39c0i1q%2F77iY3E7cIwxCkXqJTaTA%3D&id=Task%3ALocusDownloads
« Last Edit: January 06, 2022, 17:09:09 by tapio »
LM4 USER ID: 1AACAFF2A2
 

Offline Andrew Heard

  • Expert
  • Professor of Locus
  • *****
  • Posts: 1021
  • Thanked: 89 times
    • View Profile
  • Device: Samsung Galaxy A5 v8.1, Samsung Tab A7 v10
Re: [Tasker] BRouter routing files / Geonames downloader
« Reply #10 on: January 06, 2022, 22:12:22 »
Slightly off-topic sorry, but is separate BRouter app needed any more if all routing is performed with LM4Gold? Can I safely uninstall BRouter?
LM4.5.7.3 GOLD
user ID 142d400c7
 

Offline freischneider

  • Expert
  • Master of Locus
  • ****
  • Posts: 998
  • Thanked: 114 times
    • View Profile
  • Device: Xiaomi Redmi Note 10 Pro, Android 11, Locus Map 4 Gold, Locus-Device-ID: aa54a2bc9
Re: [Tasker] BRouter routing files / Geonames downloader
« Reply #11 on: January 06, 2022, 22:26:11 »
Slightly off-topic sorry, but is separate BRouter app needed any more if all routing is performed with LM4Gold? Can I safely uninstall BRouter?
Yes, I don't have a BRouter app on my new phone.
 
The following users thanked this post: Andrew Heard

Offline freischneider

  • Expert
  • Master of Locus
  • ****
  • Posts: 998
  • Thanked: 114 times
    • View Profile
  • Device: Xiaomi Redmi Note 10 Pro, Android 11, Locus Map 4 Gold, Locus-Device-ID: aa54a2bc9
Re: [Tasker] BRouter routing files / Geonames downloader
« Reply #12 on: January 06, 2022, 22:31:14 »
I thought so that I could get newer data through the direct DL. But that is not the case. With the automatic I get every 4 days. Now I have made a DL with Tasker. But no newer data was loaded. but have changed 2 days ago in OSM what. Normally this is available within a day at BRouter.
currently I do not see any advantage with the task.
 

Offline tapio

  • Expert
  • Master of Locus
  • ****
  • Posts: 805
  • Thanked: 184 times
    • View Profile
Re: [Tasker] BRouter routing files / Geonames downloader
« Reply #13 on: January 07, 2022, 07:59:24 »
Freischneider, if you have LM4 you don't need that, except maybe for the offline Geonames files.
LM4 USER ID: 1AACAFF2A2
 
The following users thanked this post: freischneider

Offline freischneider

  • Expert
  • Master of Locus
  • ****
  • Posts: 998
  • Thanked: 114 times
    • View Profile
  • Device: Xiaomi Redmi Note 10 Pro, Android 11, Locus Map 4 Gold, Locus-Device-ID: aa54a2bc9
Re: [Tasker] BRouter routing files / Geonames downloader
« Reply #14 on: January 13, 2022, 08:29:10 »
I have tested this now anyway. Since I have LM4 for over a week no new routing data. From time to time I would like to have changes in OSM the next day for routing. I used to download the file from the server and then replace it in the folder. BRouter has the changes already the next day.

Now for my test.
With the geonames came an error message. But I don't care, I don't really know what I need them for. Can I possibly later times exactly look at me.
But with BRouter the message came so that 0 files were changed.
In my folder are files from 31.12. and on the server of BRouter were yesterday data from 12.01..
Nevertheless nothing was loaded ?

Translated with www.DeepL.com/Translator (free version)