1 Reply Latest reply on Mar 27, 2015 5:11 PM by CMata_Intel

    Using arduino IDE on ubilinux

    lilfighterr

      Hi,

      I have set up ubilinux on my edison and I have tried to use the Arduino IDE on it.

      The result is it get stuck on "uploading" and does not actually upload it on the edison and I am unable to use the serial monitor.

      Does anyone know how to get it to work?

       

      Any suggestions would be appreciated!

      Thanks.

       

       

      Edit: I pressed upload again and it ran. But now it says "Permission Denied"

       

      #!/bin/sh

      starting download script

       

       

      Args to shell: C:\Users\Dagul\Desktop\arduino-1.5.3-Intel.1.0.4/hardware/tools/x86/bin C:\Users\Dagul\AppData\Local\Temp\build7912053365949154825.tmp/sketch_mar25a.cpp.elf COM6

      echo "starting download script"

      COM PORT 6

      echo "Args to shell:" $*

      Converted COM Port COM6 to tty port /dev/ttyS5

       

       

      Sending Command String to move to download if not already in download mode

      # ARG 1: Path to lsz executable.

      # ARG 2: Elf File to download

      # ARG 3: COM port to use.

       

       

      #path contains \ need to change all to /

      path_to_exe=$1

      fixed_path=${path_to_exe//\\/\/}

       

       

      #COM ports are not always setup to be addressed via COM for redirect.

      #/dev/ttySx are present. Howwever, COMy -> /dev/ttySx where x = y - 1

       

       

      com_port_arg=$3

      com_port_id=${com_port_arg/COM/}

      echo "COM PORT" $com_port_id

      tty_port_id=/dev/ttyS$((com_port_id-1))

      echo "Converted COM Port" $com_port_arg "to tty port" $tty_port_id

      Deleting existing sketch on target

       

       

      echo "Sending Command String to move to download if not already in download mode"

      echo "~sketch download" > $tty_port_id

      C:\Users\Dagul\Desktop\arduino-1.5.3-Intel.1.0.4/hardware/arduino/edison/tools/izmir/clupload_win.sh: line 24: /dev/ttyS5: Permission denied

       

       

      #Move the existing sketch on target.

      echo "Deleting existing sketch on target"

      $fixed_path/lsz.exe --escape -c "mv -f /sketch/sketch.elf /sketch/sketch.elf.old" <> $tty_port_id 1>&0

      C:\Users\Dagul\Desktop\arduino-1.5.3-Intel.1.0.4/hardware/arduino/edison/tools/izmir/clupload_win.sh: line 28: /dev/ttyS5: Permission denied

       

       

      # Execute the target download command

       

       

      #Download the file.

      host_file_name=$2

      $fixed_path/lsz.exe --escape --binary --overwrite $host_file_name <> $tty_port_id 1>&0

      C:\Users\Dagul\Desktop\arduino-1.5.3-Intel.1.0.4/hardware/arduino/edison/tools/izmir/clupload_win.sh: line 34: /dev/ttyS5: Permission denied

       

       

      #mv the downloaded file to /sketch/sketch.elf

      Moving downloaded file to /sketch/sketch.elf on target

      target_download_name="${host_file_name##*/}"

      echo "Moving downloaded file to /sketch/sketch.elf on target"

      #$fixed_path/lsz.exe --escape -c "cp sketch /sketch/sketch.elf" <> $tty_port_id 1>&0

      $fixed_path/lsz.exe --escape -c "mv $target_download_name /sketch/sketch.elf; chmod +x /sketch/sketch.elf" <> $tty_port_id 1>&0

      C:\Users\Dagul\Desktop\arduino-1.5.3-Intel.1.0.4/hardware/arduino/edison/tools/izmir/clupload_win.sh: line 40: /dev/ttyS5: Permission denied