Arduino 0021 for Windows, Mac, Linux (fixes PWM bug on Uno)
I just posted Arduino 0021 to the download page. It’s a quick release to fix the problems with analogWrite() (PWM) on pins 9 and 10 on the Arduino Uno.
This release also includes Linux (32-bit) support for the Uno and Mega 2560 (as well as the rest of the Arduino boards). The RXTX library was patched to support /dev/ttyACM* devices (which is what the ATmega8U2 on the Uno and Mega 2560 shows up as). Apologies for the delay in getting this out. Please note that there’s some weirdness when uploading to an Uno or Mega 2560 that’s running a program that sends data over the serial port. I’m not sure exactly what’s going on, but if you unplug and replug your board, or hold down the reset button, or manually delete the ACM0 lock file in /var/lock, you should be able to get it to work. Any suggestions on how to fix this properly are welcome.
Update: A 64-bit Linux version and a source archive for Arduino 0021 are now up on the download page (under “also available from Arduino.cc”).
October 2nd, 2010 at 20:58:43
One source of weirdness with USB CDC serial in Linux is that data must be flushed with tcdrain() by every application using /dev/ttyACM*. This affects LUFA.
http://groups.google.com/group/myusb-support-list/browse_thread/thread/e264ef273191a4a0?pli=1
Not sure if this is what you’re hitting or not…
October 2nd, 2010 at 21:30:13
The new 0021 with the Mega 2560 is working great on Linux (Ubuntu 10.04LTS). Thank you!
October 2nd, 2010 at 21:34:32
If you remove the librxtxSerial.so from the lib folder and install the version of librxtx that comes with your distro then it will work with most recent 64 bit versions of Linux.
October 2nd, 2010 at 23:29:02
Any chance of getting a 64bit build?
October 3rd, 2010 at 09:01:43
arduinoblog that is brilliant news, I can now program my uno from my laptop thanks for getting that out there. 😀
October 3rd, 2010 at 21:08:17
Nice… but what should 64bit linux users do? 🙁
October 4th, 2010 at 00:22:42
please check the download page, it is online now
October 4th, 2010 at 02:19:14
i have linux but pins 9 & 10 still don’t work using pwm
October 4th, 2010 at 19:26:22
Hej,
we are working on this, could you please tell me which version you are using?
0021, 32b or 64b?
/d
October 4th, 2010 at 23:24:33
i’m using it on ubuntu 9.10 but here i can’t see any /dev/ttyACMx on the selection in the IDE..i’m on 64 bit with 32 bit IDE cause 64 bit IDE says:
classe ELF errata: ELFCLASS32 (Possible cause: architecture word width mismatch
in 32 bit IDE if i upload on the board (linking /dev/ttyUSBx with /dev/ttyACMx)
something who talks to serial it gives me some troubles.
so i hope someone will write something about fixing this.
sorry for bad english.
October 5th, 2010 at 02:36:40
0021 32 bit
October 5th, 2010 at 07:25:13
ok, I am installing that version and will come back to you (I run 64b myself), if anybody can reproduce this problem please report here
/d
October 5th, 2010 at 13:03:03
i have found the problem with 0021 and ELFCLASS32
32 bit IDE and 64 bit IDE was in the same directory.
now is almost solved all the trouble, but i can’t use the serial monitor (32 and 64 bit on /dev/tty/ACMx) when i use to upload analogReadSerial to arduino (arduino UNO) the IDE seems to freeze but is not freezed is only much slow and to upload another sketch i must press much times the upload
button and reset also much times arduino.
so i can’t use serial communication with the computer.
i hope you fix also this or tell me how to fix.
thank you and sorry for bad english.
October 6th, 2010 at 08:21:21
Hej x64,
yes, this is the problem we have also found in linux. It is our believe the problem has to do with the ttyACM driver in linux. We are trying to get that fixed at the core of the linux distro while we try to roll out our own patch in our IDE. This is the reason why the IDE for linux was delayed, because there is a software issue that goes beyond our responsibility.
We just want all of you, Linux users, to know that we re doing our best to get a good solution for this asap. Of course any suggestions are welcome.
/d
October 6th, 2010 at 11:39:33
i found gtkterm a serial monitor in the ubuntu repo, with it i can read the values from arduino UNO if i run “rm /dev/ttyACMx” before using it.
i also found a way to erase the sketch uploaded to arduino:
by pressing reset button for 3 seconds and turning arduino off always pushing the reset button then turning arduino power on always pushing reset button for 3 seconds (sorry for bad english, i hope you understand)
i’ll write it in italian maybe someone could translate in a better english:
premendo il tasto reset per circa 3 secondi e spegnendo arduino e sempre tenendo premuto il tasto reset lo si riaccende e lo si tiene premuto altri 3 secondi arduino non “ricorda” lo sketch precedentemente caricato.
so linux people can use arduino in a temporary “survival mode” 🙂
October 7th, 2010 at 00:53:33
dcuartielles thanks for the help but i it figured out turns out i have to run the arduino program as root so it is most likely an OS proplem
October 7th, 2010 at 05:31:49
Looks like I’m still out of luck. I’m using a pure 64bit system and am unable to upload sketches due to the 64 bit build including a 32bit version of avrdude 🙁 this wasn’t a problem with my duemilanove since I could just delete it and link to my version of avrdude but latest version (5.10) doesn’t seem to work with the uno.
October 7th, 2010 at 10:36:00
Im running ubuntu 64 and the 21 version with mega 2560 and Uno and it works fine until i use serial communication.
Found that it still works fine if i use a delay but no shorter than 500millisek. Anything below that looks the IDE. So a tip is to always put a delay of at least 500 until there is a better solution.
But if you do (like me) upload a example like the ASCII send i can confirm that x64s solution works eg plug in in you board with the reset button pushed down, press upload and once you see the rx light on the board, release the reset button.
October 31st, 2010 at 21:46:26
I’m running Ubuntu 10.04 64-bit with arduino-0021. The uno just burns TX-light and wont accept anything from the IDE. Any chance of fixing this in 0022 and when might it be coming for 64-bit linuxes?
November 2nd, 2010 at 14:41:26
There is at least a temporary solution which has to be added to serial communication code at:
http://h00s.net/site/ubuntu/solved-problem-with-arduino-serial-communication-on-lucid-lynx-arduino-0021/
uffek
November 7th, 2010 at 11:42:26
The solution at my previous reply is not working properly on Ubuntu 10.04 LTS /Arduino Uno with software 0021. Any previous software is not supporting Uno.
So Ubuntu lovers need to use Duemilanove/0018 software as long as Duemilanove is available. On dual boot Ubuntu/Xp machine the XP/0021 software is working properly.
If someone has found a solution for Ubuntu please post it here.
November 7th, 2010 at 20:26:08
How do I get 0021 installed on 32bit Ubuntu 10.10?! The instructions say to go to the software center but that only has 0018. I have downloaded 0021 but don’t know what to do with it. 🙁
November 10th, 2010 at 16:41:48
The only solution that seems to be 100% working with uno and 64-bit 10.10 Ubuntu is using usbtinyisp to to program the chip via icsp. I’m not sure whether the problem is the linux kernel or the arduino IDE — but one thing is for sure, the 0021 version + linux does not work even with the delay-solution suggested earlier in the comments.
November 12th, 2010 at 02:18:24
I have this problem also. Ubuntu 10.10 32bit. Arduino-Uno.
Transmit light stayed on solid, IDE acted all squirrelly and sluggish, ttyACM0 would only show up at random. Did what x64 said above with the reset button and it was healed.
This should be fixable. Wouldn’t the Arduino be able to tell when the transmit light is on solid? Could it be made to give up transmitting when that happens?
PS. PPA is an old version that does not have Uno option.
November 28th, 2010 at 23:32:22
i’m using mint and arduino UNO without the IDE: avrdude and i can use it without
problems. just resetting the board via serial i use perl for this.
about the serial monitor i’m using screen with the same method.
imho is not the kernel the problem, Arduino needs only
a multiple serial “reset”.
in IDE if i reset Arduino with perl in Arduino.sh it works fine, but when it
refreshes the serial data (opening another sketch etc) it goes to be slow.
so i think is here the problem.
December 29th, 2010 at 19:16:27
[…] found an Ubuntu thread (may or may not be relevant), which mentioned the rxtx library package. This blog mentions it as well. Maybe you need to install it first. A quick search of openSUSE software […]
January 7th, 2011 at 20:59:50
It’s been reported here http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1286088093/30 (comment #34) that the new firmware fixes this – anybody tried that yet?
January 12th, 2011 at 17:48:17
This simple solution works well in Debian.
First, include experimental repositories in /etc/sources.list
#Experimental
deb http://ftp.ch.debian.org/debian/ experimental main contrib non-free
deb-src http://ftp.ch.debian.org/debian/ experimental main contrib non-free
Then upgrade arduino, arduino core and librxtx-java:
> sudo aptitude -t experimental upgrade arduino arduino-core librxtx-java
And relauch arduino IDE. /dev/ttyACM0 should appear as an option now.
Then you may want to comment out the experimental lines in sources.list to avoid other packages to be proposed for updates.
February 1st, 2011 at 08:17:56
[…] […]