Pages: [1]   Go Down
Author Topic: Fresh Start  (Read 5028 times)
0 Members and 1 Guest are viewing this topic.
Ohio
Offline Offline
Newbie
*
Karma: 2
Posts: 22
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi all.  Im an ArduiNoob here.  I have been trying to get my system to run some code written by TinHead over at LetsMakeRobots.com.  I was getting compile errors due to avr/c++ library references.  Anyways, I never did get that problem fixed.  I switched gears and started working on a simpler robot that me and my 9 year old brother could build.  Basically, I have things messed up to a point where arduino cannot ever compile the simplest code.  I am getting the error:

In file included from blinkLED.cpp:2:0:
/home/josh/arduino-0022/hardware/arduino/cores/arduino/WProgram.h:4
:20: fatal error: stdlib.h: No such file or directory
compilation terminated.

I am running Ubuntu 10.10 and Arduino 22, both 64 bit.  I know the problem stems from me installing jre, avr-g++ and c++ because it was working fine (with the exception of the aforementioned Valkyrie code written by TinHead) until then.  Basically, I just want to wipe out jre, avr-g++, c++ and arduino, then reinstall with a clean slate.  I don't know how to do this though.  Please help! (my brother is getting impatient).
Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Try this command.  This will reinstall arduino
sudo apt-get install --reinstall arduino
Logged

Ohio
Offline Offline
Newbie
*
Karma: 2
Posts: 22
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Is there a way to specify using aptitude that I want to use version 22?  When using apt-get, synaptic or ubuntu software updater, it always installs version 18
Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The last time I did it I used the following instructions:

Download version 0022 from:
   http://arduino.cc/en/Main/Software
   // it downloaded to my /home/mark/Downloads directory

// open terminal from ubuntu menu
Applications->Accessories->Terminal

// go to downloads directory
cd ~/Downloads

// untar the downloaded file
tar -vxzf arduino-0022.tgz

// change directory to replace librxtxSerial library    
cd arduino-0022/lib
 
// backup original lib
mv librxtxSerial.so librxtxSerial.so.orig

//find librxtxSerial library that works for this system
find / -ls 2>&1 | grep -i librxtxSerial

if librxtSerial library is not found somewhere in a /usr/lib subdirectory
   //  this will require root  password
  sudo apt-get install arduino
  // rerun the find command

else

// found it in /usr/lib/jni
// copy it to arduino-0022/lib directory
cp /usr/lib/jni/librxtxSerial.so .

// go up one directory
cd ..                            

// exec arduino software
./arduino      
  
« Last Edit: January 20, 2011, 06:36:16 pm by mrtaylor » Logged

Ohio
Offline Offline
Newbie
*
Karma: 2
Posts: 22
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Ok... I have reinstalled and also followed the steps in your last post after the reinstall.  Same error message.  I think it is looking for C librarys that are not where they belong.  I was following a walk through that had me installing things (avr, jre and c++) in the home directory.  As I stated before, I think it just needs to all be uninstalled and then reinstalled.  Unfortunately, I am not very familiar with linux.  
Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

reinstall gcc-avr, avr-libc

edited again
sudo apt-get install --reinstall gcc-avr
sudo apt-get install --reinstall avr-libc

reinstall java
sudo apt-get install --reinstall openjdk-6-jre

my system also has binutils-avr installed
sudo apt-get install --reinstall binutils-avr

and avrdude
sudo apt-get iinstall --reinstall avrdude
« Last Edit: January 20, 2011, 07:19:50 pm by mrtaylor » Logged

Ohio
Offline Offline
Newbie
*
Karma: 2
Posts: 22
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

No joy.

josh@Satellite-A215:~$ sudo apt-get install --reinstall avr-gcc-c++
Reading package lists... Done
Building dependency tree      
Reading state information... Done
E: Unable to locate package avr-gcc-c+
E: Couldn't find any package by regex 'avr-gcc-c+'


josh@Satellite-A215:~$ sudo apt-get install --reinstall avr-gcc
Reading package lists... Done
Building dependency tree      
Reading state information... Done
E: Unable to locate package avr-gcc
josh@Satellite-A215:~$



The 3rd one installed fine, then....



josh@Satellite-A215:~$ sudo apt-get install --reinstall sun-java6-jre
Reading package lists... Done
Building dependency tree      
Reading state information... Done
Package sun-java6-jre is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'sun-java6-jre' has no installation candidate




josh@Satellite-A215:~$ sudo apt-get install sun-java6-jre
Reading package lists... Done
Building dependency tree      
Reading state information... Done
Package sun-java6-jre is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source

E: Package 'sun-java6-jre' has no installation candidate
josh@Satellite-A215:~$






Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Sorry I was try to follow the instruction for ubuntu on the arduino web page. I have edited the post to show what on my system.
Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
0: fatal error: stdlib.h: No such file or directory
stdlib.h is located in directory /usr/lib/avr/include
and is part of package avr-libc
The command to show this is:
dpkg -S stdlib.h

Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 3
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thank you mrtaylor for your help, your instructions have succesfully helped me to install arduino 22 on my system, finally.
Logged

Ohio
Offline Offline
Newbie
*
Karma: 2
Posts: 22
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Alright,  I've done everything suggested, but am now getting the following error:

In file included from
/home/josh/Downloads/arduino-0021/hardware/arduino/cores/arduino/wiring.c:25:0:
/home/josh/Downloads/arduino-0021/hardware/arduino/cores/arduino/wiring_private.h:28:20:  fatal error:  avr/io.h:  No such file or directory

I installed version 21 this time as I couldn't find the 64 bit version 22 again.
Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

io.h should be located in directory /usr/lib/avr/include/avr/.  Check and see if the file is there.
Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Just a thought try running arduino as the root

sudo ./arduino
Logged

Colorado
Offline Offline
Full Member
***
Karma: 1
Posts: 220
Arduino 0022 and Ubuntu 11.10 64bit.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

After rereading this thread, I am wonder if you are still trying to use the software from tinhead, if so try using the blink example and see if it works.
Logged

Pages: [1]   Go Up
Jump to: