Skip to content

Commit 8c8ae50

Browse files
committed
add embedded development support for daisy hardware
1 parent c25aebd commit 8c8ae50

File tree

4 files changed

+49
-0
lines changed

4 files changed

+49
-0
lines changed

inventory/core/machines.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -154,6 +154,7 @@ _: {
154154
"llm-client"
155155
"password-manager"
156156
"cross-compile"
157+
"udev-rules"
157158
];
158159
deploy = {
159160
targetHost = "[email protected]";

inventory/core/roster.nix

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,7 @@ let
306306
"hyprland"
307307
"creative"
308308
"social"
309+
"embedded"
309310
];
310311
};
311312
};
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{ pkgs, ... }:
2+
{
3+
home.packages = with pkgs; [
4+
# Embedded development tools for Daisy and other ARM Cortex-M devices
5+
probe-rs
6+
cargo-binutils
7+
flip-link
8+
libusb1
9+
10+
# USB debugging and flashing tools
11+
usbutils # provides lsusb
12+
dfu-util # for DFU mode flashing
13+
];
14+
}

inventory/tags/udev-rules.nix

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
_: {
2+
# Add udev rules for embedded hardware and debug probes
3+
services.udev.extraRules = ''
4+
# STLink V1
5+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3744", MODE="0666", GROUP="plugdev", TAG+="uaccess"
6+
7+
# STLink V2
8+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3748", MODE="0666", GROUP="plugdev", TAG+="uaccess"
9+
10+
# STLink V2-1
11+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="374b", MODE="0666", GROUP="plugdev", TAG+="uaccess"
12+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3752", MODE="0666", GROUP="plugdev", TAG+="uaccess"
13+
14+
# STLink V3
15+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="374d", MODE="0666", GROUP="plugdev", TAG+="uaccess"
16+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="374e", MODE="0666", GROUP="plugdev", TAG+="uaccess"
17+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="374f", MODE="0666", GROUP="plugdev", TAG+="uaccess"
18+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3753", MODE="0666", GROUP="plugdev", TAG+="uaccess"
19+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="3754", MODE="0666", GROUP="plugdev", TAG+="uaccess"
20+
21+
# SEGGER J-Link
22+
ATTRS{idVendor}=="1366", MODE="0666", GROUP="plugdev", TAG+="uaccess"
23+
24+
# CMSIS-DAP compatible adapters
25+
ATTRS{product}=="*CMSIS-DAP*", MODE="0666", GROUP="plugdev", TAG+="uaccess"
26+
27+
# Daisy Seed DFU mode
28+
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="df11", MODE="0666", GROUP="plugdev", TAG+="uaccess"
29+
'';
30+
31+
# Ensure plugdev group exists
32+
users.groups.plugdev = { };
33+
}

0 commit comments

Comments
 (0)