Skip to content
Snippets Groups Projects

Configuration for GNSS/GPS on the PinePhone

Merged Imported Administrator requested to merge pinephone-gps into master

These changes are reproduced from what I've configured manually, so it's not directly tested yet.

I'm pretty sure that at least the gpsd.conf file (installed in /etc/conf.d/gpsd) will conflict with the file installed by gpsd itself. Can we solve this except using e.g. sed in the .post-install script?

The gpsd device-hook script should also probably check the output from the modem (so the output of atinout) if it returned "OK" and not some error but it should be alright for now.

Edited by Administrator

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Administrator
  • Author Owner

    I'm pretty sure that at least the gpsd.conf file (installed in /etc/conf.d/gpsd) will conflict with the file installed by gpsd itself. Can we solve this except using e.g. sed in the .post-install script?

    It most definitely will. Sed is probably a cleaner solution. DEVICE="" is already in there so a simple sed -i 's/DEVICE=""/DEVICE="/dev/ttyUSB1"/g' /etc/conf.d/gpsd will do.

    By Bart Ribbers on 2019-07-14T18:09:33

  • Administrator added 1 commit · Imported

    added 1 commit

    • ec363185 - device/device-pine-dontbeevil: add gpsd configuration

    Compare with previous version

    By Luca Weiss on 2019-07-14T18:18:48

  • Author Owner

    It most definitely will. Sed is probably a cleaner solution. DEVICE="" is already in there so a simple sed -i 's/DEVICE=""/DEVICE="/dev/ttyUSB1"/g' /etc/conf.d/gpsd will do.

    "cleaner" :(

    I kinda feel the need to implement an option in apk that packages can cleanly override e.g. configuration files from another package. I'll ask on some Alpine mailing list (or the IRC/Matrix) for advice. Because we have a lost of weird post-install scripts that change files in some other packages...

    By Luca Weiss on 2019-07-14T18:20:44

  • Author Owner

    I kinda feel the need to implement an option in apk that packages can cleanly override e.g. configuration files from another package. I'll ask on some Alpine mailing list (or the IRC/Matrix) for advice. Because we have a lost of weird post-install scripts that change files in some other packages...

    Good idea, I also don't like these weird post-install hacks.

    I guess the cleanest way without any change in apk is changing the upstream program to read configs from a directory and not only from single config files. Then we can do it like with xorg or udev and add files like 10-postmarketos-specific-config.cfg. But of course this requires adjusting each upstream program where we have this problem (and this time the upstream program is openrc, since this is an openrc config.)

    By Oliver Smith on 2019-07-16T21:29:04

  • Administrator added category::device + 1 deleted label · Imported

    added category::device + 1 deleted label

  • Administrator mentioned in issue #318 (closed) · Imported

    mentioned in issue #318 (closed)

    By Luca Weiss on 2019-07-18T11:01:18

  • Administrator added 138 commits · Imported

    added 138 commits

    Compare with previous version

    By Luca Weiss on 2019-09-09T08:19:13

  • Administrator added 96 commits · Imported

    added 96 commits

    Compare with previous version

    By Luca Weiss on 2019-09-23T08:18:58

  • Administrator added 1 commit · Imported

    added 1 commit

    • 36b6fb2a - device/device-pine64-dontbeevil: add gpsd configuration

    Compare with previous version

    By Luca Weiss on 2019-09-23T08:24:27

  • Administrator added 1 commit · Imported

    added 1 commit

    Compare with previous version

    By Luca Weiss on 2019-09-23T10:01:18

  • Administrator added 99 commits · Imported

    added 99 commits

    Compare with previous version

    By Luca Weiss on 2019-10-14T21:00:29

  • Author Owner

    So from my side this is blocked by #318 (closed) , a.k.a adding support for something like overwrites="gpsd:/etc/conf.d/gpsd.conf" in apk.

    In the meantime it would probably be possible to implement that using a package hook (and potentially post-install scripts).

    By Luca Weiss on 2019-10-14T21:02:39

  • Administrator added 180 commits · Imported

    added 180 commits

    Compare with previous version

    By Luca Weiss on 2019-12-11T23:27:50

  • Author Owner

    Tested on the pinephone, cold start of the gps was ~12 minutes which is neatly in spec. warm starts are within a minute for that.

    I only had to add the eg25 service from icenowy to this to make it work on the dev phone.

    By Martijn Braam on 2019-12-12T15:56:06

  • Author Owner

    Great! I'll submit the gpsd changes to Alpine and we'll see what they say to it. (without the gpsd changes, gpsd refuses to start without changes to /etc/conf.d/gpsd)

    Done: https://gitlab.alpinelinux.org/alpine/aports/merge_requests/2125

    By Luca Weiss on 2019-12-13T17:29:22

    Edited by Administrator
  • Administrator added 341 commits · Imported

    added 341 commits

    Compare with previous version

    By Luca Weiss on 2020-01-24T17:28:14

  • Administrator added 9 commits · Imported

    added 9 commits

    Compare with previous version

    By Luca Weiss on 2020-01-26T16:46:43

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading