Partenza Arduino IDe come root

Buongiorno a tutti
questo è il mio primo post dopo la presentazione :slight_smile:

ho installato l'ambiete di Arduino su sistema Linux Mint 19.3, nessun problema di funzinamento, ma volevo chiedere se qualcuno sa, come automatizzare l'avvio di Arduino con il comando da terminale:

sudo ./arduino

perché altrimenti non riesco ad accedere alle periferiche hardware

grazie in anticipo

No
Funziona a rovescio

Aggiungi il tuo utente al gruppo che ha diritto di accesso alla periferica

Solitamente è 'dialout"

grazie
avevo già seguito le istruzioni per questo problema, e come suggerito dalla guida il mio utente l'ho aggiunto al gruppo dialout, ma non ho ottenuto i risultati sperati.

per questa ragione ho pensato di avviarlo con sudo e fare uno script o qualcosa di simile per avviarlo ed evitare l'inconveniente

crw-rw---- 1 root dialout 166, 0 mag 22 22:09 /dev/ttyACM0
dialout:x:20:luca

ma ottengo sempre questo messaggio

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/luca/PROGRAMMI/arduino-1.8.12/hardware/tools/avr/etc/avrdude.conf"
         User configuration file is "/home/luca/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/ttyACM0
         Using Programmer              : arduino
         Overriding Baud Rate          : 115200
avrdude: ser_open(): can't open device "/dev/ttyACM0": Permission denied

avrdude done.  Thank you.

Problema di caricamento sulla scheda. Guarda http://www.arduino.cc/en/Guide/Troubleshooting#upload per suggerimenti

grazie

Dopo varie prove, tra cui aggiungermi al gruppo root ed al gruppo TTY, ho ottenuto il seguente risultato, ma non mi è chiaro cosa dovrei fare

/home/luca/PROGRAMMI/arduino-1.8.12/hardware/tools/avr/bin/avrdude -C/home/luca/PROGRAMMI/arduino-1.8.12/hardware/tools/avr/etc/avrdude.conf -v -patmega328p -carduino -P/dev/ttyACM0 -b115200 -D -Uflash:w:/tmp/arduino_build_811395/pulsante.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/luca/PROGRAMMI/arduino-1.8.12/hardware/tools/avr/etc/avrdude.conf"
         User configuration file is "/home/luca/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/ttyACM0
         Using Programmer              : arduino
         Overriding Baud Rate          : 115200
         AVR Part                      : ATmega328P
         Chip Erase delay              : 9000 us
         PAGEL                         : PD7
         BS2                           : PC2
         RESET disposition             : dedicated
         RETRY pulse                   : SCK
         serial program mode           : yes
         parallel program mode         : yes
         Timeout                       : 200
         StabDelay                     : 100
         CmdexeDelay                   : 25
         SyncLoops                     : 32
         ByteDelay                     : 0
         PollIndex                     : 3
         PollValue                     : 0x53
         Memory Detail                 :

                                  Block Poll               Page                       Polled
           Memory Type Mode Delay Size  Indx Paged  Size   Size #Pages MinW  MaxW   ReadBack
           ----------- ---- ----- ----- ---- ------ ------ ---- ------ ----- ----- ---------
           eeprom        65    20     4    0 no       1024    4      0  3600  3600 0xff 0xff
           flash         65     6   128    0 yes     32768  128    256  4500  4500 0xff 0xff
           lfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           hfuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           efuse          0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           lock           0     0     0    0 no          1    0      0  4500  4500 0x00 0x00
           calibration    0     0     0    0 no          1    0      0     0     0 0x00 0x00
           signature      0     0     0    0 no          3    0      0     0     0 0x00 0x00

         Programmer Type : Arduino
         Description     : Arduino
         Hardware Version: 3
         Firmware Version: 4.4
         Vtarget         : 0.3 V
         Varef           : 0.3 V
         Oscillator      : 28.800 kHz
         SCK period      : 3.3 us

avrdude: AVR device initialized and ready to accept instructions

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: reading input file "/tmp/arduino_build_811395/pulsante.ino.hex"
avrdude: writing flash (1942 bytes):

Writing | ################################################## | 100% 0.33s

avrdude: 1942 bytes of flash written
avrdude: verifying flash memory against /tmp/arduino_build_811395/pulsante.ino.hex:
avrdude: load data flash data from input file /tmp/arduino_build_811395/pulsante.ino.hex:
avrdude: input file /tmp/arduino_build_811395/pulsante.ino.hex contains 1942 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.26s

avrdude: verifying ...
avrdude: 1942 bytes of flash verified

avrdude done.  Thank you.

se qualcuno può darmi un aiuto, grazie
aggiungo che ora anche quando lo lancio da terminale con sudo ottengo lo stesso messaggi ogni volta che provo ad inviare un progetto all'Arduino.

grazie in anticipo per l'aiuto

Nulla, alla fine ti dice che ha caricato e verificato correttamente il programma ...

Reading | ################################################## | 100% 0.00s

avrdude: Device signature = 0x1e950f (probably m328p)
avrdude: reading input file "/tmp/arduino_build_811395/pulsante.ino.hex"
avrdude: writing flash (1942 bytes):

Writing | ################################################## | 100% 0.33s

avrdude: 1942 bytes of flash written
avrdude: verifying flash memory against /tmp/arduino_build_811395/pulsante.ino.hex:
avrdude: load data flash data from input file /tmp/arduino_build_811395/pulsante.ino.hex:
avrdude: input file /tmp/arduino_build_811395/pulsante.ino.hex contains 1942 bytes
avrdude: reading on-chip flash data:

Reading | ################################################## | 100% 0.26s

avrdude: verifying ...
avrdude: 1942 bytes of flash verified

avrdude done.  Thank you.

... le altre sono solo informazioni di diagnostica, ma va bene così.

Guglielmo

Grazie
in effetti stavo per cancellare perché mi ero accorto che il programma era in esecuzione

grazie ancore a tutti per l'aiuto