Arduino mega 2560 r3 non carica lo sketch

Arduino non mi carica lo sketch, fino a poco fa pero fuzionava, adesso quando lo collego ad una fonte di energia il led lampeggia e si spegne, stessa cosa non il led del TX. ho provato a caricare il blink e altri programmi, ma l output mi da :la porta seriale selezinata non esiste o la scheda non e connessa, anche se e connessa. come posso risolvere?

:warning:
Ti segnalo che, nella sezione in lingua Inglese, si può scrivere SOLO in Inglese ... quindi, per favore, la prossima volta presta più attenzione in quale sezione metti i tuoi post; questa volta esso è stato spostato, da un moderatore della sezione di lingua Inglese, nella sezione di lingua Italiana ... la prossima volta potrebbe venire direttamente eliminato. Grazie.

1 Like

Oltre a quanto ti è stato detto, ti segnalo che ...

... essendo il tuo primo post, nel rispetto del regolamento della sezione Italiana del forum (… punto 13, primo capoverso), ti chiedo cortesemente di presentarti IN QUESTO THREAD (spiegando bene quali conoscenze hai di elettronica e di programmazione ... possibilmente evitando di scrivere solo una riga di saluto) e di leggere con molta attenzione tutto il succitato REGOLAMENTO ... Grazie. :slight_smile:

Guglielmo

P.S.: Ti ricordo che, purtroppo, fino a quando non sarà fatta la presentazione nell’apposito thread, nel rispetto del suddetto regolamento nessuno ti risponderà (eventuali risposte verrebbero temporaneamente nascoste), quindi ti consiglio di farla al più presto. :wink:

Prima di tutto, ha scollegato qualsiasi cosa dal Arduino (tutti i pin liberi)?

Poi, hai provato a cambiare cavo USB (c'è in giro un mucchio di porcheria con cavi USB che portano solo l'alimentazione, ma non i dati)?

Che sistema operativo usi? Vedi la porta seriale dal sistema operativo (non dall'IDE)?

Guglielmo

1 Like

ho scollegato tutto e mi dà l'errore, ho anche provato a cambiare cavo e fa lo stesso.uso linux mint 20 cinammon. comunque ho provato a collegarlo a un altro compuer con windows 7 e funziona, quindi il problema è il pc. su arduino ide la rileva la porta seriale,però non funziona, invece su computer me la rileva.

Ho visto spesso discussioni relative a Linux e, quasi sempre, si trattava di "diritti" dell'utente nell'utilizzo della seriale ... magari prova a cercare (con la lente in alto a destra) qui sul forum Italiano perché se ne è parlato più volte ... :roll_eyes:

Guglielmo

Ciao Guglielmo, cosa dovrei cercare esattamente?

Mah ... prova con "linux permessi seriale" ... qualche cosa salterà fuori spero ...

Comunque devi aggiungere il tuo utente al gruppo che ha accesso alla porta seriale (se ben ricordo, o qualche cosa di simile ... NON uso linux, quindi non so esattamente) ... :roll_eyes:

Guglielmo

Prova a lanciare questi comandi, in questa sequenza:

    sudo groupadd plugdev
    sudo groupadd dialout
    sudo usermod -a -G tty <tuo_user_name>
    sudo usermod -a -G dialout <tuo_user_name>
    sudo usermod -a -G uucp <tuo_user_name>
    sudo usermod -a -G plugdev <tuo_user_name>

Ciao, Ale.

Ricordo vagamente bastasse aggiungersi al gruppo dialout

Facci sapere come va...

Ho provato a eseguire i primi 2 comandi e mi diceva che già esistevano. Gli altri quattro dopo che gli ho eseguiti non hanno lasciato scritte...

Quando provo a caricare uno sketch, (anche il semplice blink) l'output mi dà:


Arduino:1.8.19 (Linux), Scheda:"Arduino Mega or Mega 2560, ATmega2560 (Mega 2560)"

/home/pietro/Scaricati/arduino-1.8.19/arduino-builder -dump-prefs -logger=machine -hardware /home/pietro/Scaricati/arduino-1.8.19/hardware -hardware /home/pietro/.arduino15/packages -tools /home/pietro/Scaricati/arduino-1.8.19/tools-builder -tools /home/pietro/Scaricati/arduino-1.8.19/hardware/tools/avr -tools /home/pietro/.arduino15/packages -built-in-libraries /home/pietro/Scaricati/arduino-1.8.19/libraries -libraries /home/pietro/Arduino/libraries -fqbn=arduino:avr:mega:cpu=atmega2560 -vid-pid=2341_0042 -ide-version=10819 -build-path /tmp/arduino_build_403024 -warnings=all -build-cache /tmp/arduino_cache_995546 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.avr-gcc.path=/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7 -prefs=runtime.tools.avr-gcc-7.3.0-atmel3.6.1-arduino7.path=/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7 -prefs=runtime.tools.arduinoOTA.path=/home/pietro/.arduino15/packages/arduino/tools/arduinoOTA/1.3.0 -prefs=runtime.tools.arduinoOTA-1.3.0.path=/home/pietro/.arduino15/packages/arduino/tools/arduinoOTA/1.3.0 -prefs=runtime.tools.avrdude.path=/home/pietro/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17 -prefs=runtime.tools.avrdude-6.3.0-arduino17.path=/home/pietro/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17 -verbose /home/pietro/Scaricati/arduino-1.8.19/examples/01.Basics/Blink/Blink.ino
/home/pietro/Scaricati/arduino-1.8.19/arduino-builder -compile -logger=machine -hardware /home/pietro/Scaricati/arduino-1.8.19/hardware -hardware /home/pietro/.arduino15/packages -tools /home/pietro/Scaricati/arduino-1.8.19/tools-builder -tools /home/pietro/Scaricati/arduino-1.8.19/hardware/tools/avr -tools /home/pietro/.arduino15/packages -built-in-libraries /home/pietro/Scaricati/arduino-1.8.19/libraries -libraries /home/pietro/Arduino/libraries -fqbn=arduino:avr:mega:cpu=atmega2560 -vid-pid=2341_0042 -ide-version=10819 -build-path /tmp/arduino_build_403024 -warnings=all -build-cache /tmp/arduino_cache_995546 -prefs=build.warn_data_percentage=75 -prefs=runtime.tools.avr-gcc.path=/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7 -prefs=runtime.tools.avr-gcc-7.3.0-atmel3.6.1-arduino7.path=/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7 -prefs=runtime.tools.arduinoOTA.path=/home/pietro/.arduino15/packages/arduino/tools/arduinoOTA/1.3.0 -prefs=runtime.tools.arduinoOTA-1.3.0.path=/home/pietro/.arduino15/packages/arduino/tools/arduinoOTA/1.3.0 -prefs=runtime.tools.avrdude.path=/home/pietro/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17 -prefs=runtime.tools.avrdude-6.3.0-arduino17.path=/home/pietro/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17 -verbose /home/pietro/Scaricati/arduino-1.8.19/examples/01.Basics/Blink/Blink.ino
Using board 'mega' from platform in folder: /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5
Using core 'arduino' from platform in folder: /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5
Detecting libraries used...
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /tmp/arduino_build_403024/sketch/Blink.ino.cpp -o /dev/null
Generating function prototypes...
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -w -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -flto -w -x c++ -E -CC -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /tmp/arduino_build_403024/sketch/Blink.ino.cpp -o /tmp/arduino_build_403024/preproc/ctags_target_for_gcc_minus_e.cpp
/home/pietro/Scaricati/arduino-1.8.19/tools-builder/ctags/5.8-arduino11/ctags -u --language-force=c++ -f - --c++-kinds=svpf --fields=KSTtzns --line-directives /tmp/arduino_build_403024/preproc/ctags_target_for_gcc_minus_e.cpp
Sto compilando lo sketch...
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /tmp/arduino_build_403024/sketch/Blink.ino.cpp -o /tmp/arduino_build_403024/sketch/Blink.ino.cpp.o
Compiling libraries...
Compiling core...
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -x assembler-with-cpp -flto -MMD -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/wiring_pulse.S -o /tmp/arduino_build_403024/core/wiring_pulse.S.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/WInterrupts.c -o /tmp/arduino_build_403024/core/WInterrupts.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/wiring_analog.c -o /tmp/arduino_build_403024/core/wiring_analog.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/wiring.c -o /tmp/arduino_build_403024/core/wiring.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/hooks.c -o /tmp/arduino_build_403024/core/hooks.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/wiring_digital.c -o /tmp/arduino_build_403024/core/wiring_digital.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/wiring_pulse.c -o /tmp/arduino_build_403024/core/wiring_pulse.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -c -g -Os -Wall -Wextra -std=gnu11 -ffunction-sections -fdata-sections -MMD -flto -fno-fat-lto-objects -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/wiring_shift.c -o /tmp/arduino_build_403024/core/wiring_shift.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/CDC.cpp -o /tmp/arduino_build_403024/core/CDC.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/HardwareSerial.cpp -o /tmp/arduino_build_403024/core/HardwareSerial.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/HardwareSerial1.cpp -o /tmp/arduino_build_403024/core/HardwareSerial1.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/HardwareSerial0.cpp -o /tmp/arduino_build_403024/core/HardwareSerial0.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/HardwareSerial2.cpp -o /tmp/arduino_build_403024/core/HardwareSerial2.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/HardwareSerial3.cpp -o /tmp/arduino_build_403024/core/HardwareSerial3.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/IPAddress.cpp -o /tmp/arduino_build_403024/core/IPAddress.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/PluggableUSB.cpp -o /tmp/arduino_build_403024/core/PluggableUSB.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/Print.cpp -o /tmp/arduino_build_403024/core/Print.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/Stream.cpp -o /tmp/arduino_build_403024/core/Stream.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/Tone.cpp -o /tmp/arduino_build_403024/core/Tone.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/USBCore.cpp -o /tmp/arduino_build_403024/core/USBCore.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/WMath.cpp -o /tmp/arduino_build_403024/core/WMath.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/WString.cpp -o /tmp/arduino_build_403024/core/WString.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/abi.cpp -o /tmp/arduino_build_403024/core/abi.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/main.cpp -o /tmp/arduino_build_403024/core/main.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-g++ -c -g -Os -Wall -Wextra -std=gnu++11 -fpermissive -fno-exceptions -ffunction-sections -fdata-sections -fno-threadsafe-statics -Wno-error=narrowing -MMD -flto -mmcu=atmega2560 -DF_CPU=16000000L -DARDUINO=10819 -DARDUINO_AVR_MEGA2560 -DARDUINO_ARCH_AVR -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino -I/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/variants/mega /home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp -o /tmp/arduino_build_403024/core/new.cpp.o
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp: In function 'void* operator new(std::size_t, std::nothrow_t)':
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp:59:60: warning: unused parameter 'tag' [-Wunused-parameter]
 void * operator new(std::size_t size, const std::nothrow_t tag) noexcept {
                                                            ^~~
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp: In function 'void* operator new [](std::size_t, const std::nothrow_t&)':
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp:68:63: warning: unused parameter 'tag' [-Wunused-parameter]
 void * operator new[](std::size_t size, const std::nothrow_t& tag) noexcept {
                                                               ^~~
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp: In function 'void operator delete(void*, const std::nothrow_t&)':
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp:103:55: warning: unused parameter 'tag' [-Wunused-parameter]
 void operator delete(void* ptr, const std::nothrow_t& tag) noexcept {
                                                       ^~~
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp: In function 'void operator delete [](void*, const std::nothrow_t&)':
/home/pietro/.arduino15/packages/arduino/hardware/avr/1.8.5/cores/arduino/new.cpp:106:57: warning: unused parameter 'tag' [-Wunused-parameter]
 void operator delete[](void* ptr, const std::nothrow_t& tag) noexcept {
                                                         ^~~
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/wiring_pulse.S.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/WInterrupts.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/hooks.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/wiring.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/wiring_analog.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/wiring_digital.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/wiring_pulse.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/wiring_shift.c.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/CDC.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/HardwareSerial.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/HardwareSerial0.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/HardwareSerial1.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/HardwareSerial2.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/HardwareSerial3.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/IPAddress.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/PluggableUSB.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/Print.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/Stream.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/Tone.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/USBCore.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/WMath.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/WString.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/abi.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/main.cpp.o
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc-ar rcs /tmp/arduino_build_403024/core/core.a /tmp/arduino_build_403024/core/new.cpp.o
Archivio il core (caching) compilato in: /tmp/arduino_cache_995546/core/core_arduino_avr_mega_cpu_atmega2560_9fe94c247e6322f72aaf9c15c924f672.a
Linking everything together...
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-gcc -Wall -Wextra -Os -g -flto -fuse-linker-plugin -Wl,--gc-sections -mmcu=atmega2560 -o /tmp/arduino_build_403024/Blink.ino.elf /tmp/arduino_build_403024/sketch/Blink.ino.cpp.o /tmp/arduino_build_403024/core/core.a -L/tmp/arduino_build_403024 -lm
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-objcopy -O ihex -j .eeprom --set-section-flags=.eeprom=alloc,load --no-change-warnings --change-section-lma .eeprom=0 /tmp/arduino_build_403024/Blink.ino.elf /tmp/arduino_build_403024/Blink.ino.eep
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-objcopy -O ihex -R .eeprom /tmp/arduino_build_403024/Blink.ino.elf /tmp/arduino_build_403024/Blink.ino.hex
/home/pietro/.arduino15/packages/arduino/tools/avr-gcc/7.3.0-atmel3.6.1-arduino7/bin/avr-size -A /tmp/arduino_build_403024/Blink.ino.elf
Lo sketch usa 1536 byte (0%) dello spazio disponibile per i programmi. Il massimo è 253952 byte.
Le variabili globali usano 9 byte (0%) di memoria dinamica, lasciando altri 8183 byte liberi per le variabili locali. Il massimo è 8192 byte.
/home/pietro/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17/bin/avrdude -C/home/pietro/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17/etc/avrdude.conf -v -patmega2560 -cwiring -P/dev/ttyACM0 -b115200 -D -Uflash:w:/tmp/arduino_build_403024/Blink.ino.hex:i 

avrdude: Version 6.3-20190619
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2014 Joerg Wunsch

         System wide configuration file is "/home/pietro/.arduino15/packages/arduino/tools/avrdude/6.3.0-arduino17/etc/avrdude.conf"
         User configuration file is "/home/pietro/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/ttyACM0
         Using Programmer              : wiring
         Overriding Baud Rate          : 115200
avrdude: ser_open(): can't open device "/dev/ttyACM0": Permission denied
ioctl("TIOCMGET"): Inappropriate ioctl for device
ioctl("TIOCMGET"): Inappropriate ioctl for device
avrdude: ser_send(): write error: Bad file descriptor
avrdude: stk500_send(): failed to send command to serial port
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: ser_send(): write error: Bad file descriptor
avrdude: stk500_send(): failed to send command to serial port
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: ser_send(): write error: Bad file descriptor
avrdude: stk500_send(): failed to send command to serial port
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: ser_send(): write error: Bad file descriptor
avrdude: stk500_send(): failed to send command to serial port
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: ser_send(): write error: Bad file descriptor
avrdude: stk500_send(): failed to send command to serial port
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: ser_send(): write error: Bad file descriptor
avrdude: stk500_send(): failed to send command to serial port
avrdude: stk500v2_ReceiveMessage(): timeout
avrdude: stk500v2_getsync(): timeout communicating with programmer

avrdude done.  Thank you.

La porta seriale selezionata
non esiste o la scheda non è connessa

Grazie..

Quindi tu hai scritto:

sudo usermod -a -G tty pietro

Ti ha chiesto la password, l'hai inserita e poi?
Ciao.

Quando riportate tutte quelle righe, cortesemente, come ho fatto io, racchiudete tra i tag code (</>) per migliorare la leggibilità del post e la sua lunghezza. Grazie.

Guglielmo

... il messaggio comunque mi sembra chiaro ... "Permission denied", quindi, come detto, è, molto probabilmente, un problema di permessi ... :roll_eyes:

Guglielmo

Guarda, il gruppo è dialout

lo vedi listando la directory dei device:
ls -al tty*
oppure
ls -al ttyA*
ti dice a che gruppo appartiene il possessore del file
poi il comando sudo ecometihannogiaspiegato
poi devi spegnere e riaccendere (oppure ricaricare la sessione o come diavolo si dice in mint, fai prima a spegnere e riaccendere)
stanne certo che ho controllato!

se proprio non sei sicuro che sia una questione di permessi fai come faccio sempre io quando uso una macchina "foresta"
cd /
cd dev
chmod 777 ttyA*

non devi preoccuparti di lasciare permessi strambi in giro, il device ttyA... muore quando lo scolleghi, quindi i suoi permessi "evaporano"

2 Likes

grazie per il cuoricino

1 Like

Quando ho inserito la passwd non ha mostrato niente e si è ricaricata la riga di comando

grazie per i cuore, ma va o no?

Ok, chiudi sessione, rientra con lo stesso utente e da shell dai il comando, groups e anche ls -al suggerito da @Standardoil

Ciao.