summaryrefslogtreecommitdiffstats
path: root/makefu/2configs/wwan.nix
blob: 29a610ac637890e9af8d58522f39897ee9ae1ee5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
{ config, lib, pkgs, ... }:

#usage: $ wvdial

let
  mainUser = config.krebs.build.user;
in {
  environment.systemPackages = with pkgs;[
    wvdial
  ];

  environment.shellAliases = {
    umts = "sudo wvdial netzclub";
  };

  # configure for NETZCLUB
  environment.wvdial.dialerDefaults = ''
    Phone = *99***1#
    Dial Command = ATDT
    Modem = /dev/ttyACM0
    Baud = 460800
    Init1 = AT+CGDCONT=1,"IP","pinternet.interkom.de","",0,0
    Init2 = ATZ
    Init3 = ATQ0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
    ISDN = 0
    Modem Type = Analog Modem
    Username = netzclub
    Password = netzclub
    Stupid Mode = 1
    Idle Seconds = 0'';

  users.extraUsers.${mainUser.name}.extraGroups = [ "dialout" ];
}