Skip to main content

max / alloy

6.1 KB · 164 lines History Blame Raw
1 # 13. Hardware and peripherals
2
3 ## Displays
4
5 alloy display
6
7 lists the outputs sway is driving, with their scale and whether they are on.
8 `s` walks the scale ladder. The console writes what it changes to
9 `~/.config/sway/config.d/50-display.conf`, which the shipped sway config
10 includes after the system drop-ins, so your setting beats the image's.
11
12 A fresh install seeds that file at install time by reading the panel's size out
13 of EDID and snapping to the nearest scale, so a high-density laptop boots at a
14 sensible scale rather than at 1.0. A panel that cannot be read seeds nothing,
15 which means 1.0 and one keypress from correct.
16
17 Mode picking (refresh rate and resolution) is not built. Multi-output setups
18 are the untested case: nothing has attached a second display to an Alloy
19 machine yet, so if you do, expect the display view to be the rough part.
20
21 Anything the view does not cover is a sway `output` line in that same file.
22 `swaymsg -t get_outputs` names your outputs.
23
24 ## Audio
25
26 alloy audio
27
28 Two panes: the streams that are playing and the devices they could play
29 through. Move a stream from one to the other, change volumes, pick defaults.
30 The Fn keys handle the everyday case with an on-screen indicator.
31
32 Underneath is PipeWire, and `pactl` is the command the view shows you.
33
34 ## Brightness
35
36 The brightness keys work, through the same on-screen indicator. If they do not,
37 see the note in chapter 14: it takes two separate grants (a udev rule and your
38 account being in the `video` group) and either one alone leaves the keys dead
39 silently.
40
41 Screen dimming before the lock is separate, and handled by `alloy-dim` from the
42 idle configuration.
43
44 ## Power and idle
45
46 The shipped idle behaviour, in `~/.config/sway/config`:
47
48 | After | What happens |
49 |---|---|
50 | 4.5 minutes | The screen dims. Move the mouse or type and it comes back |
51 | 5 minutes | swaylock takes over |
52 | 10 minutes | Displays power off |
53 | Lid close or suspend | Always locks first |
54
55 The dim stage is the closest thing to a grace period on offer: upstream
56 swaylock has no `--grace` flag, and thirty seconds of dimmed screen is enough
57 to notice before the lock arrives.
58
59 Fullscreen mpv, imv, and the browser hold the lock off. A fullscreen terminal
60 deliberately does not: walking away from a shell should not leave the machine
61 unlocked indefinitely.
62
63 ## Fingerprint reader
64
65 fprintd is installed, and nothing is enrolled, so nothing asks for a finger
66 until you do:
67
68 fprintd-enroll
69
70 Once enrolled, the lock screen, the greeter and `run0` all accept it from that
71 one step, because they share a PAM stack. A finger that does not match, a
72 reader that is busy, and a user with nothing enrolled all fall through to the
73 password prompt.
74
75 ## Printing
76
77 Alloy prints to **IPP Everywhere (driverless) printers and nothing else**.
78 There are no vendor driver packages in the image, and there will not be. Nearly
79 every printer sold since about 2015 speaks the protocol.
80
81 A driverless printer on the same network appears by itself; discovery over mDNS
82 is already set up. The surface for anything else is CUPS' own web interface:
83
84 http://localhost:631
85
86 The daemon is socket-activated, so nothing runs until something connects to it.
87
88 A printer that needs a vendor driver is not supported. Saying so here is better
89 than you discovering it at the moment you need to print.
90
91 ## Scanning
92
93 Not shipped. Scanning means per-device backends and USB permission work with
94 opaque failures, and no one has needed one yet. If you do:
95
96 rpm-ostree install sane-backends
97
98 Worth trying first: most network scanners scan to a folder or to email with no
99 host driver at all.
100
101 ## Bluetooth
102
103 bluez is installed and running. PipeWire's Bluetooth plugins are in the image,
104 LC3 and AAC included, so a paired headset plays.
105
106 alloy bluetooth
107
108 Put the device in pairing mode, press `s` to scan, move to the `nearby` tab,
109 and press `p`. The terminal is handed to `bluetoothctl` while it scans and while
110 it pairs, so if the device wants a passkey confirmed you answer it there.
111
112 The screen is built around a distinction Bluetooth panels usually hide. bluez
113 keeps five separate facts about every device:
114
115 | Field | What it means |
116 |---|---|
117 | paired | Keys have been exchanged |
118 | bonded | Those keys were written down, so they survive a reboot |
119 | trusted | bluez will accept a connection this device starts |
120 | blocked | bluez refuses the device outright |
121 | connected | A link is up right now |
122
123 They move independently, and the one that catches people is trusted. Pairing
124 does not set it. A device that is paired and untrusted works when you connect it
125 by hand and will not come back on its own, which is what "Bluetooth keeps
126 forgetting my mouse" usually is. Press `t` on it.
127
128 The detail block at the bottom shows all five for whatever is selected, along
129 with a sentence saying what that combination means and which key changes it, and
130 the `bluetoothctl info` command it read them from.
131
132 Nothing on the screen happens on its own. A connected headset does not take over
133 your audio; press `d` if you want it to be the default sink.
134
135 If the adapter is down, `w` powers it on. If a hardware switch is blocking the
136 radio, the screen says so rather than offering a key that cannot work.
137
138 ## USB storage
139
140 There is no automounter. Plugging in a stick makes the kernel see it and
141 nothing else happens on screen.
142
143 lsblk
144 run0 mkdir -p /mnt/stick
145 run0 mount /dev/sdX1 /mnt/stick
146 # and when you are done
147 run0 umount /mnt/stick
148
149 This is a known gap rather than a position.
150
151 ## Locale and keymap
152
153 Both are rows on the System tab of `alloy settings`, fronting `localectl`.
154
155 The keymap row works as you would expect: the image carries the full `kbd`
156 keymap set, so the row lists what is really there.
157
158 Locale is the one to know about. The image ships `glibc-minimal-langpack` and no
159 language packs at all, so the only locale installed is `C.UTF-8` and that is
160 what the system formats and sorts in. The locale row shows this and is not
161 settable, because there is nothing to pick between. To get another locale, layer
162 its `glibc-langpack-*` package (chapter 7) or add it to the Containerfile and
163 rebuild; the row turns settable on its own once a second locale is present.
164