Skip to content

Conversation

@lucarin91
Copy link

@lucarin91 lucarin91 commented Oct 31, 2025

Add a post-installation script for adding udev rules for UNO Q

@lucarin91 lucarin91 changed the title feat: install udev rules feat: install udev rules for UNO Q Oct 31, 2025
@lucarin91 lucarin91 marked this pull request as ready for review October 31, 2025 16:45
if [ "$EUID" -ne 0 ]; then
if [ -e "${PWD}/post_install.sh" ]; then
if command -v pkexec > /dev/null 2>&1; then
echo "Requesting root privileges via $PKEXEC..."
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
echo "Requesting root privileges via $PKEXEC..."
echo "Requesting root privileges..."

The PKEXEC variable is not defined by the script, and at least on my Ubuntu machine, not defined globally. So the previous command would output:

Requesting root privileges via ...

I don't see any need to surface to the user the exact tool that is being used to request the privileges, so I think the best approach is to reword it as in my suggestion above.

Comment on lines +7 to +8
# Arduino UNO Q
SUBSYSTEM=="usb", ATTR{idVendor}=="2341", ATTR{idProduct}=="0078", MODE="0666"
Copy link
Collaborator

@per1234 per1234 Nov 23, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Arduino UNO Q
SUBSYSTEM=="usb", ATTR{idVendor}=="2341", ATTR{idProduct}=="0078", MODE="0666"
# Arduino UNO Q
# Operating mode
SUBSYSTEM=="usb", ATTR{idVendor}=="2341", ATTR{idProduct}=="0078", MODE="0666"
# EDL mode
SUBSYSTEM=="usb", ATTR{idVendor}=="05c6", ATTR{idProduct}=="9008", MODE="0666"

Even though it is not required for the specific use case of uploading a sketch to the board, I think it is worth also adding a rule for the "EDL mode" we put the board in when flashing the Linux operating system image to the board.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants