Skip to content

Commit 7eb96d6

Browse files
committed
snap: Need separate connection for each hidraw device
Signed-off-by: Daniel Schaefer <dhs@frame.work>
1 parent 5615410 commit 7eb96d6

File tree

3 files changed

+33
-10
lines changed

3 files changed

+33
-10
lines changed

README.md

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,11 @@ sudo snap connect framework-tool:cros-ec
4949
sudo snap connect framework-tool:hardware-observe
5050

5151
# Required for HID devices (touchpad, touchscreen, PD controller firmware)
52-
sudo snap connect framework-tool:hidraw
52+
sudo snap connect framework-tool:hidraw-hdmi-card
53+
sudo snap connect framework-tool:hidraw-dp-card
54+
sudo snap connect framework-tool:hidraw-touchpad-p274
55+
sudo snap connect framework-tool:hidraw-touchpad-p239
56+
sudo snap connect framework-tool:hidraw-touchscreen
5357

5458
# Required for USB devices (expansion cards, input modules, camera)
5559
sudo snap connect framework-tool:raw-usb
@@ -67,7 +71,7 @@ sudo snap connect framework-tool:physical-memory-observe
6771
You can connect all interfaces at once:
6872

6973
```sh
70-
for plug in cros-ec hardware-observe hidraw raw-usb block-devices io-ports-control physical-memory-observe; do
74+
for plug in cros-ec hardware-observe hidraw-hdmi-card hidraw-dp-card hidraw-touchpad-p274 hidraw-touchpad-p239 hidraw-touchscreen raw-usb block-devices io-ports-control physical-memory-observe; do
7175
sudo snap connect framework-tool:$plug
7276
done
7377
```

contrib/snap.md

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,8 @@ sudo snap install --dangerous framework-tool_*.snap
3333
## Connecting Interfaces
3434

3535
The snap uses strict confinement, so hardware interfaces must be connected
36-
manually after install:
37-
38-
```sh
39-
for plug in cros-ec hardware-observe hidraw raw-usb block-devices io-ports-control physical-memory-observe; do
40-
sudo snap connect framework-tool:$plug
41-
done
42-
```
36+
manually after install. See the [Snap Interfaces](../../README.md#snap-interfaces)
37+
section in the README for the full list of commands.
4338

4439
Verify the connections:
4540

snap/snapcraft.yaml

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,26 @@ plugs:
3333
custom-device: cros-ec
3434
devices:
3535
- /dev/cros_ec
36+
hidraw-hdmi-card:
37+
interface: hidraw
38+
usb-vendor: 0x32AC
39+
usb-product: 0x0002
40+
hidraw-dp-card:
41+
interface: hidraw
42+
usb-vendor: 0x32AC
43+
usb-product: 0x0003
44+
hidraw-touchpad-p274:
45+
interface: hidraw
46+
usb-vendor: 0x093A
47+
usb-product: 0x0274
48+
hidraw-touchpad-p239:
49+
interface: hidraw
50+
usb-vendor: 0x093A
51+
usb-product: 0x0239
52+
hidraw-touchscreen:
53+
interface: hidraw
54+
usb-vendor: 0x222A
55+
usb-product: 0x5539
3656

3757
parts:
3858
framework-tool:
@@ -72,7 +92,11 @@ apps:
7292
# EC communication via /dev/cros_ec ioctl
7393
- cros-ec
7494
# HID devices: touchpad, touchscreen, PD controller firmware
75-
- hidraw
95+
- hidraw-hdmi-card
96+
- hidraw-dp-card
97+
- hidraw-touchpad-p274
98+
- hidraw-touchpad-p239
99+
- hidraw-touchscreen
76100
# USB devices: audio card, camera, USB hub, input modules
77101
- raw-usb
78102
# NVMe device access for firmware version detection

0 commit comments

Comments
 (0)