Author Topic: Wiring 1.0 RC3 for Linux  (Read 6272 times)

0 Members and 1 Guest are viewing this topic.

marlonj

Wiring 1.0 RC3 for Linux
« on: July 01, 2011, 03:12:16 PM »
Hello There

I just download the new version of Wiring 1.0 RC3 for Linux
Thanks to Gabriel Zea !!!

- I can't program the Wiring 1.0 that i update to firmware 2.x, the serial port is recognized but when i try to upload the sketch the error : avrdude: stk500v2_ReceiveMessage(): timeout is show. I tested with Windows version and it works fine. I'm using Ubuntu 11.04 32 Bits
- I can't program the Arduino Uno, the serial port is not recognized, maybe is because the name of the serial port that is /dev/ttyACM0 and Wiring only recognize de ttyUSB type ?
- I was able to program a Freeduino (with the Arduino Uno Bootloader) that use a FTDI chip, so the Wiring can see the /dev/ttyUSB0 serial port

The debug info show when i try to upload the sketch :

/home/marlonj/sw/Wiring_1.0rc3/tools//avr/bin/avrdude -C/home/marlonj/sw/Wiring_1.0rc3/tools//avr/bin//avrdude.conf -v -v -v -v -patmega128 -cwiring -P/dev/ttyUSB1 -b115200 -D -Uflash:w:/home/marlonj/sw/Wiring_1.0rc3/examples/Basics/1.Getting Started/Blink/build/Blink.cpp.hex:i

avrdude: Version 5.10svn, compiled on Jun 30 2011 at 18:42:03
         Copyright (c) 2000-2005 Brian Dean, http://www.bdmicro.com/
         Copyright (c) 2007-2009 Joerg Wunsch

         System wide configuration file is "/home/marlonj/sw/Wiring_1.0rc3/tools//avr/bin//avrdude.conf"
         User configuration file is "/home/marlonj/.avrduderc"
         User configuration file does not exist or is not a regular file, skipping

         Using Port                    : /dev/ttyUSB1
         Using Programmer              : wiring
         Overriding Baud Rate          : 115200
avrdude: Send: . [1b] . [01] . [00] . [01] . [0e] . [01] . [14]
avrdude: ser_recv(): programmer is not responding

zea

Re: Wiring 1.0 RC3 for Linux
« Reply #1 on: July 02, 2011, 03:40:36 PM »
Hy Marlon!

I'm working on this to solve the problem, can you please download and test this new version : http://files.randomlab.net/wiring/1.0/Wiring_1.0rc3.tar.gz

Cheers!

zea

« Last Edit: July 02, 2011, 07:09:37 PM by zea »

marlonj

Re: Wiring 1.0 RC3 for Linux
« Reply #2 on: July 05, 2011, 11:25:38 PM »
Hello There

I just download the file but the problems persists :(
I think is not a problem with the Wiring IDE cause i try to upload the sketch using the avrdude package of Ubuntu and the same message is show. I think is a problem with my board

Not solution yet to discover the Arduino Uno port /dev/ttyACM0

Works fine with an Freeduino with optiboot and FTDI Usb-Serial

marlonj

barragan

Re: Wiring 1.0 RC3 for Linux
« Reply #3 on: July 06, 2011, 01:55:14 AM »
Could it be something related to this? http://ubuntuforums.org/showthread.php?t=1622981

There seems to be a solution here too: http://thenybble.de/projects/arduino-64-bit.html
« Last Edit: July 06, 2011, 01:59:40 AM by barragan »

marlonj

Re: Wiring 1.0 RC3 for Linux
« Reply #4 on: July 06, 2011, 01:44:32 PM »
Solutions for Arduino Uno Serial Port :

First Solution :
   Use the RXTX Java library patched to support the /dev/ttyACM* (easy)
   You need to download the Arduino IDE for Linux (32 or 64 bits) http://arduino.cc/en/Main/Software
   go to the directory arduino-0022/lib/ and copy the files RXTXcomm.jar librxtxSerial.so and replace
   the files at Wiring_1.0rc3/lib/serial   

Second Solution :
   Add a Symbolic link to the ttyACM* port (hard, needs root or sudo permissions)
   you need to create a rule where the kernel creates a symbolic link with the ttyUSB name for each ttyACM port
   KERNEL=="ttyACM*", SYMLINK+="ttyUSB%n"
   http://thenybble.de/projects/arduino-64-bit.html

I use the first Solution and works fine in my Ubuntu Linux 32bits
Maybe the patched version of RXTX can be added to the Wiring Linux Distribution

Troubleshooting

- Check if the librxtx-java package is installed and remove it or update to the last release

marlonj
« Last Edit: July 06, 2011, 01:52:54 PM by marlonj »

marlonj

Re: Wiring 1.0 RC3 for Linux
« Reply #5 on: July 07, 2011, 10:14:25 PM »
Hello

I'm trying to use the Wiring IDE to program an Arduino Uno Board
I change the Blink program just to use the 4 pin and connect a LED to it

Code: [Select]
void setup() {
  pinMode(4,OUTPUT);
}

void loop() {
  digitalWrite(4,HIGH);
  delay(1000);
  digitalWrite(4,LOW);
  delay(1000);
}

I test this program using Wiring in Windows 7 and works fine
but when i try to use the Linux version the LED is always ON

I test again open the Serial port to write some debug messages

Code: [Select]
void setup() {
  pinMode(4,OUTPUT);
  Serial.begin(9600);
}

void loop() {
  digitalWrite(4,HIGH);
  Serial.println("H"); 
  delay(1000);
  digitalWrite(4,LOW);
  Serial.println("L"); 
  delay(1000);
}

and it works fine in Linux
« Last Edit: July 07, 2011, 10:21:45 PM by marlonj »

barragan

Re: Wiring 1.0 RC3 for Linux
« Reply #6 on: July 08, 2011, 10:44:13 AM »
As far as I know it is a problem related to the binutils version. Arw you using the utils distributed with Wiring? or do you have them installed on your system?, (avr-binutils). The latest version has the problem.

barragan

Re: Wiring 1.0 RC3 for Linux
« Reply #7 on: July 08, 2011, 10:55:28 AM »
Yes, here is more info on the subject, http://arduino.cc/forum/index.php?action=printpage;topic=59409.0
We are using binutils-2.20.1 on Windows and macosx, the one with the bug is version 2.21, but there is a new version from Jun 27 2011 2.21.1, perhaps is worth to try it.

marlonj

Re: Wiring 1.0 RC3 for Linux
« Reply #8 on: July 08, 2011, 11:41:02 PM »
Hi

I'm using the avr that comes with the distribution of Wiring for Linux

Wiring_1.0rc3/tools/avr/bin/avr-as --version
GNU assembler (GNU Binutils) 2.21

That version have the bug

marlonj

zea

Re: Wiring 1.0 RC3 for Linux
« Reply #9 on: July 11, 2011, 04:34:13 PM »
Hi,

I compiled again the toolchain using binutils 2.20.1 and built the Wiring IDE with the RXTX libs from  Arduino.

Please test it!

http://files.randomlab.net/wiring/1.0/Wiring_1.0rc3.tar.gz

marlonj

Re: Wiring 1.0 RC3 for Linux
« Reply #10 on: July 11, 2011, 05:53:20 PM »
Hello

The Arduino UNo Serial Port is recognized :)
but the problem with the blink example persists :(

I check the version and is 2.21
 wiring/tools/avr/bin/avr-as --version
GNU assembler (GNU Binutils) 2.21

marlonj

zea

Re: Wiring 1.0 RC3 for Linux
« Reply #11 on: July 12, 2011, 12:05:43 AM »
 ??? mmmmm I'll check the binutils again

zea

Re: Wiring 1.0 RC3 for Linux
« Reply #12 on: July 12, 2011, 11:06:41 AM »
Marlon,

here is a new version, can you try it?

http://files.randomlab.net/wiring/1.0/Wiring1.0_RC3.tar.gz


zea

marlonj

Re: Wiring 1.0 RC3 for Linux
« Reply #13 on: July 12, 2011, 12:35:42 PM »
Hi Gabriel

It works !!!
Serial port /dev/ttyACM* is recognized
and Blink example works in Arduino Uno

thanks a lot
marlonj

zea

Re: Wiring 1.0 RC3 for Linux
« Reply #14 on: July 12, 2011, 03:25:03 PM »
Super!!