maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   [Announce] modRana: a flexible GPS navigation system (https://talk.maemo.org/showthread.php?t=58861)

justmemory 2018-05-25 12:19

Re: [Announce] modRana: a flexible GPS navigation system
 
It doesn't work...
What I did was:
Code:

git clone https://github.com/M4rtinK/modrana.git
cd modrana/
python modrana.py

Error message is the same as earlier:
Code:

Traceback (most recent call last):
  File "modrana.py", line 35, in <module>
    from core import modrana_log
  File "/home/user/modrana/core/modrana_log.py", line 30, in <module>
    from core import utils
  File "/home/user/modrana/core/utils.py", line 13, in <module>
    from core.backports.six import b
  File "/home/user/modrana/core/backports/six.py", line 610, in <module>
    viewkeys = operator.methodcaller("viewkeys")
AttributeError: 'module' object has no attribute 'methodcaller'


MartinK 2018-05-26 12:44

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by justmemory (Post 1544657)
It doesn't work...
What I did was:
Code:

git clone https://github.com/M4rtinK/modrana.git
cd modrana/
python modrana.py


Oops, I think I see the issue now - I forgot the push the commit that downgrades the six module to the remote. :P

So please try again - it should be there now. :)

justmemory 2018-05-26 20:29

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1544676)
So please try again - it should be there now. :)

It is there, indeed :)
Many thanks, it is working now!

MartinK 2018-06-01 23:37

Re: [Announce] modRana: a flexible GPS navigation system
 
modRana 0.55.10 is out! :)
As mentioned already, this release is has some smaller (yet important!) improvements and fixes while bigger items (navigation/voice output overhaul & MapBox GL support) are being worked on.

The modRana OpenRepos package has been updated, Jolla Store package will be updated once it clears QA in a few days.

Localization
The main highlight of this new generally-available modRana release is localization - the modRana GUI can now be fully localized. And thanks to all of our intrepid community translators on Transifex modRana is now localized (80%+ of strings translated) to these languages:
  • Swedish
  • Spanish
  • Dutch (Belgium)
  • Dutch (nl)
  • Russian
  • German
  • Japanese
  • Polish
  • Finnish
  • Czech
Thanks a lot yet again for all the translation effort! :)

Other release highlights
  • distance from current position is now shown on all point detail pages
  • routes/tracklogs/logging traces no longer glitch after screen rotation
  • some smaller fixes

rinigus 2018-06-02 12:42

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1545001)
modRana 0.55.10 is out! :)
As mentioned already, this release is has some smaller (yet important!) improvements and fixes while bigger items (navigation/voice output overhaul & MapBox GL support) are being worked on.

Just let me know if you run into any stumbling block. And, with MapboxGL, get ready to offload all tile caching/downloading to it.

MartinK 2018-06-11 00:50

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by rinigus (Post 1545022)
Just let me know if you run into any stumbling block. And, with MapboxGL, get ready to offload all tile caching/downloading to it.

Thanks in advance, I really need to finally get to that. :)

MartinK 2018-06-11 00:58

Re: [Announce] modRana: a flexible GPS navigation system
 
In the meantime, one of the smaller things I've been looking into is the nice animated speed gauge mosen has recently created. It should look like this:
https://mosushi.de/misc/maemo/090.png

Unfortunately something is apparently wrong with the shaders used for it, as I just get a violet rectangle and a bunch of errors in the log:

Code:

ERROR: 0:11: 'atan2' : no matching overloaded function found
ERROR: 1 compilation errors.  No code generated.

[W] unknown:0 - QOpenGLShader::compile(Fragment): ERROR: 0:11: 'atan2' : no matching overloaded function found
ERROR: 1 compilation errors.  No code generated.


[W] unknown:0 - *** Problematic Fragment shader source code ***
[W] unknown:0 - #ifndef GL_FRAGMENT_PRECISION_HIGH
#define highp mediump
#endif
#line 1

      uniform lowp float qt_Opacity;
      uniform highp float angleBase;
      uniform highp float angle;
      varying highp vec2 coord;
      void main() {
        gl_FragColor = vec4(0.0,0.0,0.0,0.0);
        highp vec2 d=2.0*coord-vec2(1.0,1.0);
        highp float r=length(d);
        if (0.66<=r && r<=0.92) {
          highp float a=atan2(d.x,-d.y);
          if (angleBase<=a && a<=angle) {
            highp float p=(a-angleBase)/(angle-angleBase);
            gl_FragColor = vec4(0.9,0.2,0.1,p) * qt_Opacity;
          }
        }
      }
[W] unknown:0 - ***
[W] unknown:0 - QQuickCustomMaterialShader: Shader compilation failed:
[W] unknown:0 - "ERROR: 0:11: 'atan2' : no matching overloaded function found \nERROR: 1 compilation errors.  No code generated.\n\n"

Apparently the shaders fail to compile for whatever reason. I'm seeing the same thing happen both on Sailfish OS (2.2) and one my Fedora desktop system (Fedora 28 with Qt 5.10). Any ideas how to fix it ?

mosen 2018-06-11 08:32

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1545308)
Unfortunately something is apparently wrong with the shaders used for it, as I just get a violet rectangle and a bunch of errors in the log:

[CODE]ERROR: 0:11: 'atan2' : no matching overloaded function found

Yay MartinK!
Sorry for not responding earlier, thanks for concidering the gauge :)

Please stop wasting time on debugging silly opengl. I will rewrite the gauge using pure qml. The code will be much longer but i can generate nearly the same design using RadialGradiant applied to a thick line.
Its just that i found the Shader thingy to be quite elegent but if it crashes, it crashes.
I don't have the SFOS Sdk installed so all i do is prototype in qmlscene. Sorry for letting you run into such an alpha stage problem.

Also on AsteroidOS we had problems with a watchface employing shaders that would not display on a single watch only, the sony tetra. After quite some debug kido decided to simply hide the watchface for tetra :/

Lets see when i get back to coding, i guess tomorrow evening.

MartinK 2018-06-11 08:53

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by mosen (Post 1545319)
Yay MartinK!
Sorry for not responding earlier, thanks for concidering the gauge :)

Please stop wasting time on debugging silly opengl. I will rewrite the gauge using pure qml. The code will be much longer but i can generate nearly the same design using RadialGradiant applied to a thick line.

Yeah, I was thinking it would be probably possible to implement it with some QtQuick transformation instead of shaders.

Quote:

Originally Posted by mosen (Post 1545319)
Its just that i found the Shader thingy to be quite elegent but if it crashes, it crashes.
I don't have the SFOS Sdk installed so all i do is prototype in qmlscene. Sorry for letting you run into such an alpha stage problem.

No problem really. :) BTW, I also don't have the Sailfish OS SDK installed & run everything via qmlscene during development, even on Sailfish OS. On desktop, qmlscene is actually the regular way of launching modRana, so any widgets have to work with it. :)

Quote:

Originally Posted by mosen (Post 1545319)
Also on AsteroidOS we had problems with a watchface employing shaders that would not display on a single watch only, the sony tetra. After quite some debug kido decided to simply hide the watchface for tetra :/

My guess would be that this is due to the overall sorry state of mobile Open GL drivers. I remember other issues, such as old Open GL on Jolla 1 preventing reasonable debugging of Mapbox GL native crashes or some article I've read from the Dolphin emulator developers where they wrote aqbout all the horrible drivers they have to work around on various Android devices.

Quote:

Originally Posted by mosen (Post 1545319)
Lets see when i get back to coding, i guess tomorrow evening.

Thanks! :-)

Android_808 2018-06-11 13:20

Re: [Announce] modRana: a flexible GPS navigation system
 
Apparently my earlier post disappeared. I found some references to atan being a substitute for atan2 as it can take 2 arguements.

Edit: because it was in wrong thread! D'oh.
https://forum.qt.io/topic/89307/qml-...colour-glow/10

MartinK 2018-06-24 22:28

Re: [Announce] modRana: a flexible GPS navigation system
 
modRana 0.52.18 has been released !

Still continuing with the theme of smaller yet important fixes and improvements though arguable the switch to SVG icons is actually pretty significant. Not only should the icons in modRana no longer be blurry - ever - but as a side effect the installation package is now just 1.3 MB instead of 1.9 MB, because SVG files compress really well. The installed size savings are less as unpacked SVG files often take up about the same space as the resulting bitmap in PNG format.

Work also continues on the two main planed bigger items, such as abstracting the API modRana uses to talk to the map page, so that an alternative map page based on MapBox GL Native can be added.

Changelog since last time (0.55.10):
* all icons are now SVG and thus resolution independent! :)
* it is now possible to easily clear things displayed on top of the map
* show distance on POI listings
* fix toggle highlight for centering icon
* show "Route here" option on all point & POI detail pages
* fix layout of search progress popup
* improved on-map button & button text sizing
* show distance to POI in POI detail page
* translation fixes & updates (big thanks to all translators yet again! :) )

Release status
OpenRepos package has been updated
Jolla Store package has been submitted to QA

rinigus 2018-08-31 07:49

Re: [Announce] modRana: a flexible GPS navigation system
 
@MartinK: I don't know how far are you with the porting to MapboxGL effort. Now, assuming that SFOS3 will come with QtLocation supporting Mapbox GL (5.9, isn't it?), maybe it will make more sense to port it over to QtLocation proper. That would allow you to get simpler installation on desktop (no extra plugins needed).

Although, without newer compiler, they will not be able to provide MapboxGL component in QtLocation and, in general, SFOS3 hopes should be probably as low as possible (aka 'please don't break anything'). But its an angle that you could think about when making priorities and timelines for future development.

In general, with this porting (mapbox gl plugin or qtlocation), make sure that Delete and Backspace and Ctrl-K work on your keyboard. There is a lot of code crafted around getting tiles that waits to be deleted. At least, that's expectation based on Poor Maps days.

MartinK 2018-09-02 21:21

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by rinigus (Post 1547814)
@MartinK: I don't know how far are you with the porting to MapboxGL effort. Now, assuming that SFOS3 will come with QtLocation supporting Mapbox GL (5.9, isn't it?), maybe it will make more sense to port it over to QtLocation proper. That would allow you to get simpler installation on desktop (no extra plugins needed).

I've recently finished decoupling the map page API from the pinchmap based implementation. This way I should be able to integrate another map widget quite easily while keeping pinchmap based one working until the new widget supports all the expected features. I guess this could be helpful for any API uncertainities as well. :)

BTW, how is the "official" Mapbox GL plugin API compared to "our" custom MapboxGL element API ? Is it 1:1 match feature wise ?

I would kinda fear the API is dumbed down to account for all the other plugins but (the QtLocation API, especially in the QtQuick 1.0 times was not very good). Or is it possibly the other way around (eq. we are missing some features they have ?).

Quote:

Originally Posted by rinigus (Post 1547814)
Although, without newer compiler, they will not be able to provide MapboxGL component in QtLocation and, in general, SFOS3 hopes should be probably as low as possible (aka 'please don't break anything').

That's definitely the only sensible way. :) It looks like they are working on QtLocation 5.9:
https://git.merproject.org/mer-core/...n/tree/mer-5.9
https://git.merproject.org/mer-core/...n/tree/mer1911

But who knows in which for it will actually be available, which plugins will work and if it will finally be whitelisted for Jolla Store apps.

BTW, thinking about it, would it be possible that the MapBoxGL plugin could be built with your updated GCC toolchain and still work with QtLocation 5.9 once available ?

That way there would still be a custom dependency that needs to be installed, but the custom element would not have to be maintained anymore & it would simplify desktop porting compatibility.

Quote:

Originally Posted by rinigus (Post 1547814)
But its an angle that you could think about when making priorities and timelines for future development.

Definitely thanks for the heads-up! :) While I think I'll just start with our current known-working solution, it's definitely good to explore other options (technically, the modRana codebase could be now able to support both if really really needed :D).

Quote:

Originally Posted by rinigus (Post 1547814)
In general, with this porting (mapbox gl plugin or qtlocation), make sure that Delete and Backspace and Ctrl-K work on your keyboard. There is a lot of code crafted around getting tiles that waits to be deleted. At least, that's expectation based on Poor Maps days.

I don't know I understand this ? You mean in modRana, the custom MapBoxGL plugin on Poor/Whogo/Pure maps code ?

For the record I definitely plan to continue supporting "classic" tiled maps as well as vector tiles. There are various useful pre-rendered or aerial map tile sets that should definitely continue to be available to users together with the on-the-fly rendered vector layers. :)

Still if I understand things correctly the MapBoxGL widgets has custom bitmap tile caching code, so indeed the modRana tile handling machinery will not be needed when running with MapBoxGL based map page. But it will still be needed for the time being for the pinchmap based map page & the old GTK2 based UI people apparently still use on the N900. :)

rinigus 2018-09-03 07:30

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1547916)
BTW, how is the "official" Mapbox GL plugin API compared to "our" custom MapboxGL element API ? Is it 1:1 match feature wise ?

From the brief look, it seems to have all features our plugin has. At least on 5.11 level. However, 5.9 seems to have backported Mapbox GL plugin as well, so it should be fine as well.

Quote:

Originally Posted by MartinK (Post 1547916)
I would kinda fear the API is dumbed down to account for all the other plugins but (the QtLocation API, especially in the QtQuick 1.0 times was not very good). Or is it possibly the other way around (eq. we are missing some features they have ?).

While general interface is maybe dumbed down, there is an access to Mapbox GL specific constructs too.

Quote:

Originally Posted by MartinK (Post 1547916)
That's definitely the only sensible way. :) It looks like they are working on QtLocation 5.9:
https://git.merproject.org/mer-core/...n/tree/mer-5.9
https://git.merproject.org/mer-core/...n/tree/mer1911

But who knows in which for it will actually be available, which plugins will work and if it will finally be whitelisted for Jolla Store apps.

Thanks for links. I asked at their pull request regarding packaging, let's see what they will reply.

Quote:

Originally Posted by MartinK (Post 1547916)
BTW, thinking about it, would it be possible that the MapBoxGL plugin could be built with your updated GCC toolchain and still work with QtLocation 5.9 once available ?

That way there would still be a custom dependency that needs to be installed, but the custom element would not have to be maintained anymore & it would simplify desktop porting compatibility.

Sure, the custom plugin works on 5.9 and probably later too. I am using it on PC.

Quote:

Originally Posted by MartinK (Post 1547916)

Definitely thanks for the heads-up! :) While I think I'll just start with our current known-working solution, it's definitely good to explore other options (technically, the modRana codebase could be now able to support both if really really needed :D).


I don't know I understand this ? You mean in modRana, the custom MapBoxGL plugin on Poor/Whogo/Pure maps code ?

I met mainly tile caching/downloading code in modRana :) . But if you want to keep backward compatibility, all is needed. As for raster tiles, they are supported by Mapbox GL too.

MartinK 2018-09-06 21:31

Re: [Announce] modRana: a flexible GPS navigation system
 
modRana 0.52.18 has been released !

This is still a rather small update that adds support for deleting individual stored POI and makes creation of new POI more intuitive.

Changelog
* it is now possible to delete individual saved POI
* adding new POI from the map should now be more intuitive
* translation update

carlosgonz 2018-09-06 21:44

Re: [Announce] modRana: a flexible GPS navigation system
 
yes \0/ new version finally. ;)
thnks

MartinK 2019-03-18 18:10

Re: [Announce] modRana: a flexible GPS navigation system
 
So looks like Sailfish OS 3.0.2 Oulanka has broken modRana due to the Python 3 upgrade (3.4.3 -> 3.7.2).

Basically, modRana uses the work "async" in a couple places in its source code, but that work became a reserved word used by Python starting from Python 3.7 and causes modRana to crash.

In any case I should have a fixed modRana version available shortly. :)

MartinK 2019-03-19 01:36

Re: [Announce] modRana: a flexible GPS navigation system
 
modRana 0.56.14 has been released ! :)

So finally, a new modRana release! There is not that much user visible (yet ;-) ) other than, well, working now with Sailfish OS 3.0.2 Oulanka, where Python 3 version upgrade (3.4.3 -> 3.7.2) kinda prevented modRana from starting correctly.

Other than that, modRana now has a shiny native launcher, that made it possible to drop many Sailfish OS specific packaging hacks, mainly imposed by sailfish-qml being very, very stupid. This also has user visible impact though.

You can now easily start modRana from CLI on Sailfish OS by typing:

Code:

harbour-modrana
That's the new native launcher binary, that launcher modRana the correct way (and no longer have to hack around sailfish-qml limitations). There is also some potential for modRana starting slightly faster.

This change also has an interesting side effect - modRana is no longer noarch - the launcher is compiled Qt5/C++ source code, so the modrana package needs to be architecture specific, even thought the rest of the application is all Python & QML. :)

I can't really think about any issues possibly stemming from this (other than me having to upload two packages to Jolla Store and OpenRepos. :) Also, you can of course still just clone the modRana source code from git, install qmlscene and then start the sailfish script from the run subfolder.

Also, one more update - translations! Thanks a lot to everyone taking part, IIRC there should be some more complete languages as well as general translation updates. :)

Where can I get modRana 0.56.14 ?

link to Open Repos:
https://openrepos.net/content/martink/modrana-0

link to Jolla Store:
is not there as Jolla Store still has no web version! :P

rinigus 2019-03-19 06:32

Re: [Announce] modRana: a flexible GPS navigation system
 
@MartinK: interesting, which limitations are you hitting with sailfish-qml? Having a dedicated launcher gives more flexibility in long run, though.

MartinK 2019-03-19 09:52

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by rinigus (Post 1555352)
@MartinK: interesting, which limitations are you hitting with sailfish-qml? Having a dedicated launcher gives more flexibility in long run, though.

There were a couple, mainly with sailfish-qml forcing a certain application structure, which is not really compatible with how modRana files are laid out & how it is launcher on other platforms:
  • the main qml file needs to be called harbour-<app name> and located in /usr/share/harbour-<app name>
  • all the QML files need to be in in /usr/share/harbour-<app name>/qml
  • sailfish-qml sets the PWD to /home/nemo, which complicates loading of Python modules
  • there is no option to set QML import path (needed for Universal Components), it has to be done via an environmental variable, which is a problem as invoker can't really take those in the Exec line of a desktop file
Normally modRana supports multiple GUIs and the GUI files are located in the corresponding GUI sub folder, it's expected the PWD is pointing to the top level modRana directory and the currently selected UC backend should be added to the QML import path.

To achieve this I had to do some pretty nasty & fragile source code mangling during the build of the Sailfish OS package.

Now with the native launcher, I have full control over QML import path, PWD/PYTHONPATH, argv and the QML execution environment in general.

It has also the nice side effect that people now can easily start modRana by typing:

Code:

harbour-modrana
This is also in $PATH & autocomplete will find it, unlike before.

There are also some other reasons for this:
  • IIRC Flatpak will need a launcher like this anyway
  • if I ever start doing packages for Android again a similar type of launcher is needed there as well
  • argument passing should be more doable with native launcher
    • no arg - start Qt 5 GUI
    • some args - pass them to modrana.py instead of starting GUI
  • if I ever need access to some C/C++ API or just want to compute something really quickly in native code, I now have the option via the launcher (likely with a pure-Python fallback where possible)

The only possible downside/change (aside from the time spent on this) is that the modRana package is no longer noarch, but so far I have not hit any real issues because of that.

Dirish 2019-03-19 10:45

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by jobooth (Post 1555388)
Alright. Call me stupid but I love my mig welders and can't get this installed on my trusty N900. Updated to 1.3 and on CSSU. When I run apt-get install modrana I get
The following packages have unmet dependencies:
modrana: Depends: espeak but it is not going to be installed
E: Broken packages

Seems like a launcher is a no brainer. Why don't more people utilize that approach than?

jobooth 2019-03-20 04:04

Re: [Announce] modRana: a flexible GPS navigation system
 
Alright. Call me stupid but I can't get this installed on my trusty N900. Updated to 1.3 and on CSSU. When I run apt-get install modrana I get
The following packages have unmet dependencies:
modrana: Depends: espeak but it is not going to be installed
E: Broken packages

justmemory 2019-03-20 07:26

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by jobooth (Post 1555388)
Alright. Call me stupid but I can't get this installed on my trusty N900. Updated to 1.3 and on CSSU. When I run apt-get install modrana I get
The following packages have unmet dependencies:
modrana: Depends: espeak but it is not going to be installed
E: Broken packages

Modrana for N900 is version 0.53.1... All packages are in the repo so you should check which repos are enabled on your device. Otherwise you can still install it by hands - downloading and "dpkg -i"-ing the downloaded packages...
If you want an updated version you can use github repo - I use 0.55.18 on my N900 and it is working fine.

rinigus 2019-03-20 08:17

Re: [Announce] modRana: a flexible GPS navigation system
 
@MartinK - good reasons. Few comments below

For Pure Maps, I am using symlinks to select platform (similar to your UC) and just import using a known symlink name in QML sources. That way QML files are the same and symlink is set while building a package.

I ended up writing bash script for harbour-pure-maps, but that was for command line options support. Not sure whether its store-compatible, but that's a future-me problem.

Obviously there is more flexibility using C++, as you outlined.

Flatpak does require exe (script or something else), indeed. Have been using a script so far.

As for disadvantages - mainly missing noarch and a need to compile the code for distribution. As soon as you start extending with C++ (cannot use plane qmlscene or similar), development will be hit a bit. So, while not really needed, its better to avoid it as well.

olf 2019-03-20 14:19

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1555351)
modRana 0.56.14 has been released ! :)

Unfortunately the screen output is broken, so modRana 0.56.14 is unusable on my Xperia X and Jolla 1 (SFOS versions 3.0.1.11 and 2.2.1.18), see modRana issue #282 at Github for details and screenshots.

Fellfrosch 2019-03-20 17:18

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by olf (Post 1555411)
Unfortunately the screen output is broken, so modRana 0.56.14 is unusable on my Xperia X and Jolla 1 (SFOS versions 3.0.1.11 and 2.2.1.18), see modRana issue #282 at Github for details and screenshots.

Strange that you have this problems on two devices. I can just check at the moment with my Xperia X (as well on 3.01.11) and for me it works like it should.

MartinK 2019-03-20 18:06

Re: [Announce] modRana: a flexible GPS navigation system
 
I know about the issue on Github and was thinking it's maybe something <3.0.2 specific (even though I really don't know why it would happen this way) and I'm curretly trying to install the new package on some of my other Sailfish OS devices with older SFOS versions. Still, it seems to work with 3.0.1 for others, weird.

Can you maybe try to run it from terminal and send me the output (here ore privately - based on your preference) ? Just launch the terminal and run "harbour-modrana". :)

MartinK 2019-03-20 18:39

Re: [Announce] modRana: a flexible GPS navigation system
 
Tried just yet on my Jolla 1 with Sailfish OS 3.0.0.5 (Lemmenjoki), package from OpenRepos - seems to work fine. It really looks like some system state specific weirdness might be involved.

olf 2019-03-20 23:27

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1555419)
I know about the issue on Github ...

Oh, pitfalls, both technically and socially on multiple levels:
  • As I could (and still can) reproduce this "shifted screen"-issue on two different devices (by hardware and installed SFOS version), I assumed it to be present for many. But as nobody has chimed in to the Github issue or here at TMO, now I believe that it is just me being affected.
  • Sorry for cross-posting this issue yesterday. The intention was to make others aware of this (as most people seem to prefer a forum over a proper issue tracker), not to get on your (@MartinK) nerves (as you likely received a notification from Github, already).
  • Lets continue debugging and discussing the technical aspects of this issue at modRana's issue tracker at Github, e.g. that this issue "funnily" evades debugging. :confused:

MartinK 2019-03-21 00:39

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by olf (Post 1555431)
Oh, pitfalls, both technically and socially on multiple levels:
  • As I could (and still can) reproduce this "shifted screen"-issue on two different devices (by hardware and installed SFOS version), I assumed it to be present for many. But as nobody has chimed in to the Github issue or here at TMO, now I believe that it is just me being affected.

It could still be that many have not set started updating. Alternatively it might be "just you" in the sense of using some sort of UI patch or some other "non standard" software or setting that somehow, via a weird side-effect triggers this behavior.

In any case, weird! But we had issues like this with modRana in the past, that were tracked down to for example to IIRC a version of Sailfish OS with old <5.6 Qt on ported devices.

Quote:

Originally Posted by olf (Post 1555431)
  • Sorry for cross-posting this issue yesterday. The intention was to make others aware of this (as most people seem to prefer a forum over a proper issue tracker), not to get on your (@MartinK) nerves (as you likely received a notification from Github, already).

No problem with cross-posting at all & I do know about the issue on GitHub. :) I simply was too busy to properly analyze it yet and posting a quick comment here on the thread was simply the quickest thing to do. :)

Quote:

Originally Posted by olf (Post 1555431)
  • Lets continue debugging and discussing the technical aspects of this issue at modRana's issue tracker at Github, e.g. that this issue "funnily" evades debugging. :confused:

Sure, that sounds reasonable. :) I have a few suggestions what to try & will take a look at the logs you have attached to the issue (thanks! :) ).

MartinK 2019-03-21 01:08

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by Dirish (Post 1555361)
Seems like a launcher is a no brainer. Why don't more people utilize that approach than?

It just fits pretty good to what modRana needs on Sailfish OS, other projects might have other (and likely simpler) requirements, especially if the application (or at least its GUI) is only targeting Sailfish OS.

Quote:

Originally Posted by rinigus (Post 1555398)
@MartinK - good reasons. Few comments below

For Pure Maps, I am using symlinks to select platform (similar to your UC) and just import using a known symlink name in QML sources. That way QML files are the same and symlink is set while building a package.

That's clever, relatively clean & simple! :) Would have not thought about something like this, but thinkin about it now, symlinks is what for example systemd uses to mark a unit enabled/disalber, to set the default target, etc. So that validates the concept I guess. :)

For modRana and Universal Components I guess it would likely work as well:
  • no UC backend seems to use "Import UC 1.0" internally, so it not being in QML import path should not be a problem
  • while technically possible there could be 2+ supported component sets on a single platform, non platform actually provides this (eq. two sets that are both supported well enough by UC)

The only possible problem I can thing of are environments where symlinks can't be used, such as running on top of FAT32 or from resource files on Android. But both is again more or less theoretical.

So while I don't think I want to change the launcher architecture for UC usage for modRana now, the symlink method seems like a good tip to add to the UC docs. Thanks for the idea! :)


Quote:

Originally Posted by rinigus (Post 1555398)
I ended up writing bash script for harbour-pure-maps, but that was for command line options support. Not sure whether its store-compatible, but that's a future-me problem.

That's the conclusion I also ended with - since you can't prepend QML_IMPORT_PATH to the Exec line in the .desktop file, you would have to put that to a script instead. Not sure if "bash some script" is acceptable in the Exec line either, but maybe an executable script residing in /usr/bin/harbour-<app name> might get through. But that would still (due to Harbor requirements) require me to use sailfish-qml and submit to all its more or less stupid hardcoded limitations. At that point I've decided to just got the Qt5/C++ launcher code.

As I don't really do any C/C++ coding regularly, it was more or less cobled together from how other OSS Sailfish OS apps do app startup & QtCreator autocomplete. :D

Quote:

Originally Posted by rinigus (Post 1555398)
Obviously there is more flexibility using C++, as you outlined.

Flatpak does require exe (script or something else), indeed. Have been using a script so far.

Do they provide a binary that can launch QML files (qmlscene ro something like that) ? IIRC from reading the Pure Maps flatpak packaging metadata it looked like such a binary the script can call is not available and the app needs to build it itself.

Quote:

Originally Posted by rinigus (Post 1555398)
As for disadvantages - mainly missing noarch and a need to compile the code for distribution.

My idea is that the native launcher is only really important for modRana that gets installed from a package (or in the future Flatpak). The package already goes through a buildsystem so might as well contain some C++ code and generate arch-specific artifacts. Users will very likely not notice any difference.

ModRana itself still continues to be noarch and I don't plan to change it. Also all the other startup methods (running modrana.py directly or the qmlscene using shell scripts in the "run" subfolder are still fully supported & are actually the main/intended method of running modRana if you just do a checkout from git or grab a tarball.

Quote:

Originally Posted by rinigus (Post 1555398)
As soon as you start extending with C++ (cannot use plane qmlscene or similar), development will be hit a bit. So, while not really needed, its better to avoid it as well.

This is just an idea at this point in time. If I ever start using that I plan to make the features provided by C++ code to either be backed a fallback implemented in Python (this is actually how many Python modules do C extensions - there is a fast C path and a slow but correct Python path that gets used if the compiled C code is not available) or make the functionality an optional addon, not something that would prevent modRana from running (otherwise) normally.

MartinK 2019-03-21 01:33

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by jobooth (Post 1555388)
Alright. Call me stupid but I can't get this installed on my trusty N900. Updated to 1.3 and on CSSU. When I run apt-get install modrana I get
The following packages have unmet dependencies:
modrana: Depends: espeak but it is not going to be installed
E: Broken packages

Quote:

Originally Posted by justmemory (Post 1555395)
Modrana for N900 is version 0.53.1... All packages are in the repo so you should check which repos are enabled on your device. Otherwise you can still install it by hands - downloading and "dpkg -i"-ing the downloaded packages...

Indeed, the latest modRana Maemo package is indeed pretty old, yet stable. I have wanted to update it for quite some time but never really get to it so far. The other issue is that I'm starting to wonder if updating it is actually a good idea. I don't really have a working Maemo SDK available locally and all the "recent" Maemo packages have been built by the Maemo autobuilder.

Given that by now likely all remaining Maemo/N900 users have Extras Devel enabled & the autobuilder packages (if successfully built) do directly to Extras devel, I'm kinda afraid a broken package would affect users, resulting in possibly lengthy back-and-forth by feeding the autobuilder and hoping a working package comes out.

If someone had the needed knowledge/tooling (I barely understood how Maemo packages are made back then, let alone now) and wanted to accept the challenge of updating the Maemo modRana package I (and surely any remaining users on Maemo) would be very happy. :)

Quote:

Originally Posted by justmemory (Post 1555395)
If you want an updated version you can use github repo - I use 0.55.18 on my N900 and it is working fine.

Yes, that's basically the recommended way & should work in general. Just grab a release tarball/checkout a release tag and run modrana.py.

I don't really test this regularly (as I don't have any functional Python 2.5 environment outside of my trusty N900), so please let me know if you hit some issues. :)

In any case, it's good to know there are still people using modRana on the N900 - which is what, 10 years old about now ? :D Well, modRana itself will hit the 10 year mark in January of the next year. Crazy! :D

Is still don't have any immediate plans for dropping support for the N900, but there are a few things to consider:
  • I've recently completely dropped the old abandoned Qt4/QML UI that just kinda worked on the N900 and did not provide much useful features & AFAIK no one really used it anyway
  • I'm developing modRana on Fedora (and actually developing the Fedora installer as my day job ;-) ) and due to the upcoming upstream end of support for Python 2, Python 2 only packages are currently getting dropped left and right
  • it is therefore not unthinkable that some of the Python 2 only dependencies of modRana (such as PyGTK for example) will get dropped from Fedora in the near future

Not having the Python 2 only deps (and possibly even Python 2 itself!) available in the distro I use would make harder assuring that the Python 2/GTK2 based GUI used on the N900 continues to be working.

So at some point in the future a time might come, where it would make more sense to maintain basically a separate branch for the N900, that would likely just get occasional fixes than much (if any) new development.

On the other hand this could help to make the "modern" codebase targeting Python 3 + Qt 5 cleaner by dropping all the hacks needed to support Python 2.5 - 3.7 at the same time + all the (rather messy code) that constitutes the GTK GUI.

And, potentially the "n900-branch" would no longer need to care about any of that newfangled Python >2, GTK >2 and GUI != GTK stuff, potentially making the life of anyone interested in stepping in and improving the N900 version easier. :)

rinigus 2019-03-21 07:45

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1555434)
Do they provide a binary that can launch QML files (qmlscene ro something like that) ? IIRC from reading the Pure Maps flatpak packaging metadata it looked like such a binary the script can call is not available and the app needs to build it itself.

That's what https://github.com/rinigus/qmlrunner is for. It also has all options that are needed for flatpak distribution of Pure Maps and we can surely extend it as needed. Also, QML path can be extended as needed.

jobooth 2019-03-21 21:48

Re: [Announce] modRana: a flexible GPS navigation system
 
Nokia N900 1.3 on CSSU
I got modrana 0.53.1 installed and running from the repositories. Works great except trying to route just gives me a "routing failed". I had an active data connection the entire time.
I'm now trying to get offline routing working. The monav.openstreetmap.de site is down so I downloaded my state from data.modrana.org. The tar file was empty, however. It didn't create any directories. I tried the north-america_car.tar.gz as well. Empty. Tried with root too.
I guess I'll try to generate my own. It just seems like I'm either doing something wrong or nothing's working.

Secondly, how again to update? I downloaded the 0.55.18 file, tar'd it, and ran the modrana.py script. modrana opened but info-about doesn't show a version. The icon in the app drawer still loads 0.53.1 too

MartinK 2019-03-22 02:42

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by rinigus (Post 1555442)
That's what https://github.com/rinigus/qmlrunner is for. It also has all options that are needed for flatpak distribution of Pure Maps and we can surely extend it as needed. Also, QML path can be extended as needed.

Interesting! :) I guess I've basically just rolled all that and some into the modRana native launcher.

Due to some o the less than ideal packaging rules and practices on Sailfish OS, having the launcher as part of the modRana project is simply easier, than pulling in an external project. I guess I can always put it in a separate project if needed in the future and pull it in via git subtree like with Universal Components.

Thinking about it, some sort of a unified launcher that would accept config files in some unified format to set all the paths could be rather useful for any QML only or Python QML application that has grown too big to be launched by qmlscene or for environments where qmlscene is not available.

Quote:

Originally Posted by jobooth (Post 1555465)
Nokia N900 1.3 on CSSU
I got modrana 0.53.1 installed and running from the repositories. Works great except trying to route just gives me a "routing failed". I had an active data connection the entire time.
I'm now trying to get offline routing working. The monav.openstreetmap.de site is down so I downloaded my state from data.modrana.org. The tar file was empty, however. It didn't create any directories. I tried the north-america_car.tar.gz as well. Empty. Tried with root too.

Weird, I'll try checking as well what's in those archives. These are all generated by my scripts, but I have not really re-run those since setting up the OSM Scout Server mirror.

Quote:

Originally Posted by jobooth (Post 1555465)
I guess I'll try to generate my own. It just seems like I'm either doing something wrong or nothing's working.

Secondly, how again to update? I downloaded the 0.55.18 file, tar'd it, and ran the modrana.py script. modrana opened but info-about doesn't show a version. The icon in the app drawer still loads 0.53.1 too

That's expected - these are basically two independent modRana deployments. One installed from a package & the other one from a release tarball. The modRana that has not been installed via package not showing version is actually expected as well, as IIRC the version file gets generated at package build time.

In any case good to know recent modRana versions are still working on the N900. :)

justmemory 2019-03-22 08:08

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1555435)
Yes, that's basically the recommended way & should work in general. Just grab a release tarball/checkout a release tag and run modrana.py.

I don't really test this regularly (as I don't have any functional Python 2.5 environment outside of my trusty N900), so please let me know if you hit some issues. :)

Sure I will :) BUT...

Quote:

Originally Posted by MartinK (Post 1555435)
In any case, it's good to know there are still people using modRana on the N900 - which is what, 10 years old about now ? :D Well, modRana itself will hit the 10 year mark in January of the next year. Crazy! :D

Is still don't have any immediate plans for dropping support for the N900, but there are a few things to consider:
  • I've recently completely dropped the old abandoned Qt4/QML UI that just kinda worked on the N900 and did not provide much useful features & AFAIK no one really used it anyway
  • I'm developing modRana on Fedora (and actually developing the Fedora installer as my day job ;-) ) and due to the upcoming upstream end of support for Python 2, Python 2 only packages are currently getting dropped left and right
  • it is therefore not unthinkable that some of the Python 2 only dependencies of modRana (such as PyGTK for example) will get dropped from Fedora in the near future

Not having the Python 2 only deps (and possibly even Python 2 itself!) available in the distro I use would make harder assuring that the Python 2/GTK2 based GUI used on the N900 continues to be working.

So at some point in the future a time might come, where it would make more sense to maintain basically a separate branch for the N900, that would likely just get occasional fixes than much (if any) new development.

On the other hand this could help to make the "modern" codebase targeting Python 3 + Qt 5 cleaner by dropping all the hacks needed to support Python 2.5 - 3.7 at the same time + all the (rather messy code) that constitutes the GTK GUI.

And, potentially the "n900-branch" would no longer need to care about any of that newfangled Python >2, GTK >2 and GUI != GTK stuff, potentially making the life of anyone interested in stepping in and improving the N900 version easier. :)

... but I'm thinking about trying out Sailfish on a Samsung device (community port is available) because... Yes, n900 and Maemo 5 is pretty old. Still... I really need the capabilities that n900 has so I do not know. Talking about python... You know... Maemo 5 is quite old and even Leste won't be a real Maemo 6 but we will see. I do not know whether it is needed to have a n900 branch of ModRana if the tarballs are working so... :)

MartinK 2019-03-22 15:44

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by justmemory (Post 1555481)
I do not know whether it is needed to have a n900 branch of ModRana if the tarballs are working so... :)

To clarify, the idea is that - eventually in the future - a n900 Git branch for modRana would be needed as the default Git branch & releases would no longer run on Python 2.5 & N900 with GTK2.

The n900 branch would be kept Python 2.5, GTK2 & N900 compatible while the default development branch would be able to drop all the hacks needed for Python 2.5 support & all the GTK2 GUI code.

MartinK 2019-03-28 14:19

Re: [Announce] modRana: a flexible GPS navigation system
 
A small modRana bugfix release - 0.56.17 - has been released, most likely fixing the incorrect viewport issue reported by Olf and others.

If you want to know what turned out to be the root cause and how it was fixed, check the corresponding issue on GitHub.

jobooth 2019-03-29 23:07

Re: [Announce] modRana: a flexible GPS navigation system
 
A huge thank you MartinK for all your hard work.

Quick question... Should online routing work on the N900?

robthebold 2019-03-31 02:51

Re: [Announce] modRana: a flexible GPS navigation system
 
Quote:

Originally Posted by MartinK (Post 1555351)
You can now easily start modRana from CLI on Sailfish OS by typing:

Code:

harbour-modrana

Does launching from CLI take any commands, parameters, options, etc.? I haven't found anything in the available documentation, but that could be my search skill and not the reality.

And thanks for continued support.


All times are GMT. The time now is 18:46.

vBulletin® Version 3.8.8