Go Down

Topic: Help - Random function not working (Read 6751 times) previous topic - next topic

mikalhart

Yeah, and the problem affects do_random() as well.  My fear is that if this problem affects these two core library functions, what others might be affected that we haven't discovered!

I'll investigate how to post this to the avr libc developers.

Mikal

mikalhart

Before I post a bug report to the avr-libc developers' forum let me ask our Linux users a question: when you install Arduino-0012, do we build the libc locally, or does it come precompiled?  I'm trying to assess whether or not the bug might be a problem with some build scripts under our (Arduino's) control.

Mikal

timmaah

Well both of my examples were done using Aurduino-0012. Not sure if that helps with your question.


Veronica

I installed all the avr stuff from the Ubuntu repository so it was precompiled. The linux Arduino tar file only contains avrdude and avrdude.conf

mikalhart

Thanks, Veronica.  So can we now say definitively that avr-libc is definitely being provided by the Linux distribution and not by Arduino?

I posted the bug report on the avr-libc-dev forum (http://lists.gnu.org/archive/html/avr-libc-dev/2009-01/threads.html), and they ask the following questions:

  • Which Linux distribution does the problem show up on?
  • Who is the maintainer of the AVR GCC toolchain on that Linux distribution?
  • Which version of AVR GCC is being built? (Is it 4.3.0?)
  • How is the AVR GCC toolchain being built? What patches are being used? What is the configuration command line?


Can someone using Linux -- especially on a distribution known to be failing -- answer these?

Mikal

Patzak

#50
Jan 04, 2009, 03:25 am Last Edit: Jan 04, 2009, 03:33 am by Patzak Reason: 1
@Mikal....This is the uname -a from the distro that started this thread.

Linux pat-desktop 2.6.27-9-generic #1 SMP Thu Nov 20 22:15:32 UTC 2008 x86_64 GNU/Linux

If you would like more information please let me know.

Pat

Forgot to add this:

pat@pat-desktop:~$ locate avr-gcc
/usr/bin/avr-gcc
/usr/bin/avr-gcc-4.3.0
/usr/bin/avr-gccbug
/usr/share/man/man1/avr-gcc-4.0.2.1.gz
/usr/share/man/man1/avr-gcc.1.gz
/usr/share/man/man1/avr-gccbug.1.gz
pat@pat-desktop:~$

mikalhart

Thanks, Patzak.  Is there any way to determine the version of the avr-libc module?

Veronica

Mine are:
Ubuntu 8.10 (Intrepid Ibex)
avr-libc 1:1.6.2-1
avr-gcc 1:4.3.0-2

Maintainer: Ubuntu MOTU Developers

Linux main 2.6.27-11-generic #1 SMP Fri Dec 19 16:29:35 UTC 2008 x86_64 GNU/Linux

BTW, I just installed the following files from debian sid and now the random function works as expected:

binutils-avr_2.18-4_amd64.deb
avr-libc_1.6.2.cvs20080610-2_all.deb
gcc-avr_4.3.2-1_amd64.deb

I still need to test that this doesn't break something else instead.

HTH

Ver

UziMonkey

Installing the updated packages from sid as described here fixes the problem.  I'm not sure if that's been mentioned in this thread yet.

UziMonkey

Oops, it's right there.  Nevermind.

One thing that wasn't mentioned is that you can find these packages on http://packages.debian.org/.

mikalhart

Thanks, UziMonkey.  That's good information.  

Mikal

mikalhart

See http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1236018369/0 for an update on this issue.

Go Up