From bd53caf1ac5e1caf035d2773836e6eef7fbd5fb1 Mon Sep 17 00:00:00 2001 From: Gregor Kleen Date: Mon, 30 Oct 2017 13:26:59 +0100 Subject: GPS on hel? --- hel.nix | 66 ++++++++++++----------------------------------------------------- 1 file changed, 12 insertions(+), 54 deletions(-) diff --git a/hel.nix b/hel.nix index 4a3b6606..35df46cb 100644 --- a/hel.nix +++ b/hel.nix @@ -92,29 +92,6 @@ }); }; - # nixpkgs.config.packageOverrides = pkgs: rec { - # libqmi = pkgs.stdenv.lib.overrideDerivation pkgs.libqmi (old: { - # src = pkgs.fetchgit { - # url = "git://anongit.freedesktop.org/libqmi"; - # rev = "7a426340c9238f743b4641096ea86b89dd503041"; - # sha256 = "1lnr049hjakp864kq2lql04nfraaxgfh88rjayc7a7x993s75fzs"; - # }; - - # buildInputs = old.buildInputs ++ (with pkgs; [ libmbim automake114x ]); - # }); - # libmbim = pkgs.stdenv.lib.overrideDerivation pkgs.libmbim (old: { - # src = pkgs.fetchgit { - # url = "git://anongit.freedesktop.org/libmbim/libmbim"; - # rev = "c5ed53cfabc0d7ba20dea1047db718f2ca0a6d80"; - # sha256 = "07fy120703rwpf7p0d8fdbrswx9jn1ln8wnnn7zkwwjq9mgr6ppp"; - # }; - - # buildInputs = old.buildInputs ++ (with pkgs; [ autoconf automake gnome.gtkdoc libtool pkgconfig ]); - - # preConfigure = "./autogen.sh"; - # }); - # }; - nixpkgs.config.allowUnfree = true; services = { @@ -261,37 +238,18 @@ ''; }; - # udev.extraRules = '' - # ACTION!="add|change", GOTO="mbim_to_qmi_rules_end" - # SUBSYSTEM!="usb|drivers", GOTO="mbim_to_qmi_rules_end" - - # # load qmi_wwan module - # SUBSYSTEM=="usb", \ - # ATTR{idVendor}=="1199", ATTR{idProduct}=="9079", \ - # RUN+="/sbin/modprobe -b qmi_wwan" - - # # force Sierra Wireless EM7455 to configuration #1 - # SUBSYSTEM=="usb", \ - # ATTR{idVendor}=="1199", ATTR{idProduct}=="9079", \ - # ATTR{bConfigurationValue}="1" - - # # add the new id in the qmi_wwan driver - # SUBSYSTEM=="drivers", \ - # ENV{DEVPATH}=="/bus/usb/drivers/qmi_wwan", \ - # ATTR{new_id}="1199 9079" - - # # load qcserial module - # SUBSYSTEM=="usb", \ - # ATTR{idVendor}=="1199", ATTR{idProduct}=="9079", \ - # RUN+="/sbin/modprobe -b qcserial" - - # # add the new id in the qcserial driver - # SUBSYSTEM=="drivers", \ - # ENV{DEVPATH}=="/bus/usb-serial/drivers/qcserial", \ - # ATTR{new_id}="1199 9079" - - # LABEL="mbim_to_qmi_rules_end" - # ''; + udev.extraRules = '' + # Disallow ModemManager from touching Sierra Wireless EM7455 tty ports + SUBSYSTEM=="tty", \ + ATTR{idVendor}=="1199", ATTR{idProduct}=="9079", \ + ENV{ID_MM_DEVICE_MANUAL_SCAN_ONLY}="1" + ''; + + services.gpsd = { + enable = true; + device = "/dev/serial/by-path/pci-0000:00:14.0-usb-0:2:1.2-port0"; + readonly = false; + }; printing = { enable = true; -- cgit v1.2.3