IDE fails to upload to the Arduino M0/M0 Pro except in root on Linux

The subject pretty much sums it up: I added myself to the dialout group (which is the owner of /dev/ttyACM0), but I still cannot upload. I have used fuser, and it appears that no processes are using the port. In the programming port mode, I get “Error: No Valid JTAG Interface Configured.” In the native port mode, I get “openPort(); Exception type - Port busy.” I am using the latest version of the Arduino IDE and I have tested two NEW Arduino boards. Neither work.

The only way I can upload is in root. Interestingly, I CAN upload to an Arduino Uno in my normal user, leading me to believe that this is a bug. Furthermore, if I upload a serial echo sketch as root, I can use the serial monitor to talk to the Arduino in my normal user. One interesting line in syslog is “ModemManager[971]: Couldn’t create modem for device at ‘/sys/devices/pci0000:00/0000:00:1d.3/usb5/5-1’: Failed to find primary AT port.”
This happens whenever I plug the device in to the native usb port.

Currently I am running Java as root to upload sketches, so any solutions would be appreciated!

Try removing ModemManager and see if that helps. ModemManager, at least on Ubuntu, seems to serve no useful purpose.

Read this:

Thanks! The page you sent fixed the problem with the programming port! The native USB still doesn't work, but that's not an issue for me since I still can upload code.