Merge pull request 'fix(nfc): make the Bolt Card reader an opt-in machine capability' (#115) from fix/nfc-opt-in into dev

Reviewed-on: #115
This commit is contained in:
padreug 2026-09-29 20:51:37 +00:00
commit 7000720ae9
6 changed files with 160 additions and 95 deletions

View file

@ -144,6 +144,21 @@
sintra = "04:00 Europe/Paris";
};
# Which models have a contactless (CCID) card reader fitted, for Bolt
# Card taps. Same keying caveat as the two tables above.
#
# This can't live in a hardware file: hardware/upboard.nix is shared by
# sintra (HID Global OMNIKEY 5022) and tejo (nothing fitted), so before
# this table the tejo inherited pcscd it had no use for while the douro,
# with its own hardware file, got none and wedged on boot — nfc-pcsc
# busy-spins Electron's main thread when pcscd is absent (see
# apps/machine/electron/nfc-service.ts). Flip a model to true when a
# reader is actually fitted; douro and tejo are planned.
nfcReaderForModel = {
batm3 = true; # Feitian KP382
sintra = true; # HID Global OMNIKEY 5022
};
lib = nixpkgs.lib;
# Helper to create a live USB NixOS config for a specific machine model
@ -200,6 +215,7 @@
services.bitspire = {
enable = true;
appDir = "${atm-app}";
nfc.enable = nfcReaderForModel.${machineModel} or false;
};
# Operator TUI and CLI tools