Debian Codegraph @

udev/README.md

raw symbols SCIP
1 udev rules for Linux
2 ====================
3
4 On Linux, permission to access USB devices from user space must be explicitly granted
5 via udev rules. This directory contains example udev rules to allow pyOCD to access common
6 debug probes without requiring it to be run as root, something which is very highly
7 discouraged.
8
9 The following debug probes are supported:
10
11 - Atmel-ICE CMSIS-DAP
12 - Atmel EDBG CMSIS-DAP
13 - Atmel nEDBG CMSIS_DAP
14 - Cypress KitProg1/KitProg2 in CMSIS-DAP mode
15 - Cypress KitProg3
16 - Cypress MiniProg4
17 - DAPLink
18 - Keil ULINKplus
19 - NXP LPC-LinkII
20 - NXP MCU-Link
21 - Raspberry Pi Picoprobe
22 - STLinkV2
23 - STLinkV2-1
24 - STLinkV3
25
26
27 To install, copy the rules files in this directory to `/etc/udev/rules.d/` on Ubuntu:
28
29 ```
30 $ sudo cp *.rules /etc/udev/rules.d
31 ```
32
33 If you use different, but compatible, debug probe from one of those listed above, you can check the
34 IDs with the ``dmesg`` command.
35
36 - Run ``dmesg``
37 - Plug in your board
38 - Run ``dmesg`` again and check what was added
39 - Look for line similar to ``usb 2-2.1: New USB device found, idVendor=0d28, idProduct=0204``
40
41
42 To see your changes without a reboot, you can force the udev system to reload:
43
44 ```
45 $ sudo udevadm control --reload
46 $ sudo udevadm trigger
47 ```
48
49 By default, the rules provide open access to the debug probes for all users (0666 permissions).
50 If you share your Linux system with other users, or just don't like the idea of write permission
51 for everybody, you can replace `MODE:="0666"` with `OWNER:="yourusername"` to create the device
52 owned by you, or with `GROUP:="somegroupname"` and mange access using standard Unix groups.
53
54 _Note: STLink rules provided courtesy of STMicroelectronics._