Go Down

Topic: Help Installing Library (Read 1 time) previous topic - next topic

day26

Jul 07, 2011, 02:02 pm Last Edit: Jul 07, 2011, 02:21 pm by day26 Reason: 1
Hi,

I'm using an Arduino Uno with version 0022 of the software.  It's installed on a Windows Vista SP2 machine and, up until this morning, everything has worked as expected. I'm new to the Arduino but am pretty experienced with PCs and software. (I write software for a living).

I've been trying to install some libraries for use on my board.  This morning I installed the Tone library (from http://code.google.com/p/rogue-code/wiki/ToneLibraryDocumentation) without any problems.  I copied this into the C:\Users\MyUserName\Documents\arduino-0022\arduino-0022\libraries folder on my machine.  The Tone library appeared in the Import Library list as expected and loaded correctly when selected.

Later I tried to install the TimeDate library from http://www.arduino.cc/playground/Code/Time (again by copying to the C:\Users\MyUserName\Documents\arduino-0022\arduino-0022\libraries folder on my machine).

This would not appear in the Import Library list and compiling fails with a selection of error messages!

Now neither the TimeDate nor the Tone libraries appear in the Import Library list. (Odd that the Tone library should disappear when I haven't removed it).

I have also tried copying the Sketchbook folder as described at http://www.arduino.cc/en/Reference/Libraries without success.

If anyone could offer any advice on:

1) Why the Tone library has disapeared?
2) Where I'm going wrong installing the other library?

If I've missed any information you need to know please let me know.

many thanks.



day26

To add to my question above I've just tried adding (any) one of the inbuilt libraries and got the following error:

core.a(main.cpp.o): In function `main':
D:\Software\Arduino\arduino-0022\hardware\arduino\cores\arduino/main.cpp:7: undefined reference to `setup'
D:\Software\Arduino\arduino-0022\hardware\arduino\cores\arduino/main.cpp:10: undefined reference to `loop'

I'm just about to try installing and reinstalling the software (just in case!)

MarkT

You should have just installed it in sketchbook/libraries/  - libraries that are built into the Arduino software itself are compiled differently I believe. 

In general putting code into the Arduino distribution means you'll lose it when you next upgrade!
[ I won't respond to messages, use the forum please ]

robtillaart

When installing libraries - ALL occurences of the IDE needs to be restarted, did you do that?
Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

day26

Yes, all instances of the IDE were restarted.

Also, the machine has been restarted several times.

I reinstalled the IDE last night and again copied across the libraries - again, they do not show up in the IDE.


robtillaart

How many libraries do you have ?  - don't know if there is a limit, just thinking out loud ...

The pattern I see is that Time << Tone (alphabetically) are there other libs missing beyond the letter T?


Rob Tillaart

Nederlandse sectie - http://arduino.cc/forum/index.php/board,77.0.html -
(Please do not PM for private consultancy)

day26

Apologies for delay in replying to previous post but I've been away for a few days.

The libraries I'm trying to install are the first two after a default software installation so I wouldn't think that that would be a problem so soon.

retrolefty

Are you sure you are placing the libraries in the correct place and format?

Here is how my contributed library looks like, note that this library directory is located in the arduino sketch folder not anywhere in the arduino core structure.

Quote
C:\Documents and Settings\Primary Windows User\My Documents\Arduino\libraries

15 Folders:

Button
DS1307
EasyTransfer
Flash
FreqCount
FreqMeasure
MsTimer2
NewSoftSerial
Playtune
SoftEasyTransfer
Streaming
String
Tone
WString
__MACOSX


0 Files:


And here are the contents of my Tone library:

Quote
C:\Documents and Settings\Primary Windows User\My Documents\Arduino\libraries\Tone

2 Folders:

examples
Tone


3 Files:

keywords.txt
Tone.cpp
Tone.h


See if your folder structure is similar. You will know you have it correct when you can in the IDE click on sketch/import Library and see the library listed in the lower 'contributed' section of the listing shown.

Lefty

day26

Thanks for your reply Lefty.

Firstly, my Vista machine maps the path to C:\Users\[Username]\Documents\Arduino\Libraries

Having said that, something strange has happened.  When I started up my machine today and opened the IDE the libraries were visable and worked perfectly.

Nothing has been added, removed or changed since I shut down the machine last night when the libraries weren't working.

As I may have said above, I work as a software developer and am no stranger to weird things happening with Windows machine configurations so I'm writing this off as a Windows quirk.

If I figure out what happened then I'll post again so others can benefit.

Many thanks to everyone who posted.

retrolefty

Quote
Firstly, my Vista machine maps the path to C:\Users\[Username]\Documents\Arduino\Libraries


That needs to be libraries (as in lower case l) for the IDE to find the folder.


Lefty

smeezekitty

Case name does not differentiate in Windows. that means fopen, open and readdir don't care so it shouldn't matter.
Avoid throwing electronics out as you or someone else might need them for parts or use.
Solid state rectifiers are the only REAL rectifiers.
Resistors for LEDS!

CrossRoads

I struggle with this also. I have my IDE at c:/program files/arduino-0021.
When I download stuff, windows vista keeps putting it in some virtual storage folder, and makes it difficult to get it in the program files/arduino area.
freakin' windows ...  I really miss the older versions before it was assumed we were all idiots and needed to be spoon fed everything.
Designing & building electrical circuits for over 25 years.  Screw Shield for Mega/Due/Uno,  Bobuino with ATMega1284P, & other '328P & '1284P creations & offerings at  my website.

Go Up