summaryrefslogtreecommitdiff
path: root/hardware
diff options
context:
space:
mode:
Diffstat (limited to 'hardware')
-rw-r--r--hardware/cmsb-001/configuration.nix36
1 files changed, 24 insertions, 12 deletions
diff --git a/hardware/cmsb-001/configuration.nix b/hardware/cmsb-001/configuration.nix
index 53217cd..a4fb9bb 100644
--- a/hardware/cmsb-001/configuration.nix
+++ b/hardware/cmsb-001/configuration.nix
@@ -1,4 +1,6 @@
# https://citizen428.net/blog/installing-nixos-raspberry-pi-3/
+# https://faint.day/blog/raspberry-pi-3-hardware-accelerated-video-playback/
+# https://github.com/jc-kynesim/rpi-ffmpeg/tree/dev/7.1/rpi_import_2
{ config, lib, pkgs, modulesPath, ... }: {
imports = [
#"${modulesPath}/installer/sd-card/sd-image.nix"
@@ -42,12 +44,15 @@
"i2c_bcm2835"
"reset-raspberrypi"
];
- boot.initrd.kernelModules = [];
+ boot.extraModulePackages = [ config.boot.kernelPackages.v4l2loopback ];
+ boot.kernelModules = [ "v4l2loopback" ];
boot.kernelParams = [ "mitigations=off" "file_caps=1" ];
boot.blacklistedKernelModules = [ "snd_bcm2835" ];
hardware.enableRedistributableFirmware = true;
- hardware.graphics.enable = true;
+ hardware.graphics = {
+ enable = true;
+ };
console = {
font = "Lat2-Terminus16";
@@ -114,6 +119,7 @@
})
mesa-demos
vulkan-tools
+ v4l-utils
cage
nfs-utils
mpv
@@ -127,18 +133,24 @@
source = "${pkgs.cage}/bin/cage";
setuid = true;
};
- };
-
- services.cage = {
- enable = true;
- user = "naunet";
- environment = {
- WLR_LIBINPUT_NO_DEVICES = "1";
+ "mount.nfs" = {
+ owner = "root";
+ group = "root";
+ source = "${pkgs.nfs-utils.out}/bin/mount.nfs";
+ setuid = true;
};
- program = "${pkgs.camu}/bin/cmv";
};
- systemd.services."cage-tty1".serviceConfig.StandardOutput = lib.mkForce "journal+console";
- systemd.services."cage-tty1".wantedBy = [];
+
+ #services.cage = {
+ # enable = true;
+ # user = "naunet";
+ # environment = {
+ # WLR_LIBINPUT_NO_DEVICES = "1";
+ # };
+ # program = "${pkgs.camu}/bin/cmv";
+ #};
+ #systemd.services."cage-tty1".serviceConfig.StandardOutput = lib.mkForce "journal+console";
+ #systemd.services."cage-tty1".wantedBy = [];
# https://pablo.tools/blog/computers/nixos-generate-raspberry-images/
#sdImage = {