Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New post_install.sh script that works for Nano Every #129

Merged
merged 1 commit into from
May 31, 2023

Conversation

seaxwi
Copy link
Contributor

@seaxwi seaxwi commented May 29, 2023

This PR adds a post_install.sh script consistent with the one for ArduinoCore-mbed. Using the same path for the script will simplify troubleshooting instructions. The new script also includes udev rules for Nano Every,

Changes in this PR

  • Replace scripts/create_udev_rule with post_install.sh (based on post_install.sh)
  • Use a simiilar structure (more readable)
  • Add udev rules for Nano Every
  • Change the name of the created file from 99-arduino-uno-wifi-rev2.rules to 60-arduino-megaAVR.rules.

Tests

Before running post_install.sh (missing udev rules)

UNO WiFi Rev2 ❌

Upload fails:

avrdude: usbdev_open(): cannot open device: Permission denied
avrdude: jtag3_open_common(): Did not find any device matching VID 0x03eb and PID list: 0x2145
Failed uploading: uploading error: exit status 1

Nano Every ❌

Upload fails:

avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): sign-on command: status -1
avrdude: jtagmkII_getsync(): timeout/error communicating with programmer (status -1)
Failed uploading: uploading error: exit status 1

After running post_install.sh (new udev rules added)

UNO WiFi Rev2 ✅

Upload successful, although on my system a "spurious" avrdude: usbdev_open(): WARNING: failed to set configuration 1: Device or resource busy warning is thrown. However, I get the same result with the rules set by scripts/create_udev_rule, so I believe its occurence is unaffected by this PR.

Nano Every ✅

Upload successful.

@facchinm facchinm merged commit 5e639ee into arduino:master May 31, 2023
@facchinm
Copy link
Member

Super, thanks for your contribution!

@seaxwi seaxwi deleted the post-install.sh branch May 31, 2023 14:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants