Cannot upload (new CLI user) on headless

I am having trouble uploading my compiled sketch to an Arduino UNO device from a headless linux system.
With this command: arduino-cli upload -p /dev/ttyACM0 --fqbn arduino:samd:mkr1000 MyFirstSketch
the error that I get says "No device found on ttyACM0." However, when I run core list the result is:

arduino-cli core list
ID Installed Latest Name
arduino:samd 1.8.12 1.8.12 Arduino SAMD Boards (32-bits ARM Cortex-M0+)

Some research showed that the user needs to be a member of the dialout group, and I have addressed that. And I've rebooted a couple of times since..

ls -l /dev/ttyACM0
crw-rw---- 1 root dialout 166, 0 Jan 26 13:16 /dev/ttyACM0
ls -l /etc/udev/rules.d
total 4
-rw-r--r-- 1 root root 2535 Sep 30 03:14 99-com.rules
groups
dennis adm dialout cdrom sudo audio video plugdev games users input render netdev lpadmin gpio i2c spi

I also have double-pressed the reset button (many times) .. there is no pulse from the onboard LEDs. (They do light up, and stay on.)

I thought the problem might be with the parameter "arduino:samd:mkr1000" but as a new user, I could not determine any alternative here. I am uncertain how to come up with this value; it is from the getting-started instructions.

Can anyone tell me how to proceed from here, what I might be doing wrong? What logs I can share? (BTW: I have a seond UNO board (both official Arduino, both a few years old); both exhibit this problem.

You say you're uploading to an Uno, but you've selected a MKR1000. They're totally different beasts.

What board, exactly, do you have?

Back of the board is white and, near the top, says "Board Model UNO R3." As I implied the (very-limited) getting-started instructions don't say how to determine this value. It's just "type this" and a certain expected result. That's it.


Fix the fqbn to say UNO and search this forum for the Linux permissions required, dialot is one but my 83 yo memory is hinting at a second.

Once to install the AVR core:

arduino-cli core install arduino:avr

Then to compile and upload for an Uno R3:

arduino-cli compile -b arduino:avr:uno
arduino-cli upload -b arduino:avr:uno -p /dev/ttyACM0

Edit: fixed bad core name.

thanks, my result was:

arduino-cli core install arduino:avr:uno
Invalid argument passed: invalid item arduino:avr:uno

My bad.

arduino-cli core install arduino:avr
1 Like

Thanks so much! That solved it. That being true, though, how does one properly determine the fqbn for any given board? (Like, how did you come up with this answer, for example?) I have a couple of other varieties on order (two that are IOT-focused). Just curious; as I said, this problem is solved.

cli board listall

Will show you the plain text name that you'd select in the IDE ("Arduino Uno", in this example) and the FQBN ("arduino:avr:uno") beside it for all the boards in your installed cores.

cli board -b <fqbn> details

Will show you all the compile options available. Which for the Uno, is basically just which programmer you can use, and isn't applicable in your case.

Thanks so much again! Very helpful!