Pages: [1] 2 3   Go Down
Author Topic: Arduino Library downloader  (Read 3842 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 36
Arduino rocks
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi everyone.

I don't know if something like this already exists or if this even works for everyone.

I am using the Arduino software and often i just want to know if there is already a library for the thing i want to do,
if there is a new version of a library or just to download and install a library easily.

i made an application in C++ and wxWidgets to do exactly this.
It is using currently using 7zip for extracting the libs after download.

It was my first try in coding with wxWidgets and Gui development in C++ so i hope it is not too bad. smiley-wink
I only tested it on my windows machine and compiled it there, but i tried to only use things that are multiplatform compatible.

I put a quick and small webpage together here:
http://ardulibrary.code-i.de/

The Sourcecode is in my SVN repository accessible with the username "gast":
http://svn.code-i.de/ardulibrary/

a small Screenshot:


there are not all librarys in the list at the moment but it does not mean i like this more than the other libs.
The list is of course maintained by hand.

a doubleclick on a library sends you to the homepage of that lib.
Logged

Norway@Oslo
Offline Offline
Edison Member
*
Karma: 13
Posts: 2033
loveArduino(true);
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

A good initiative! But, I would like to see this functionality as part of the official IDE. Maybe this will start a butterfly effect that results in just that.

Anyways, feel free to add any of my libraries:P
http://www.arduino.cc/playground/Profiles/AlphaBeta
Logged

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

nice. i have added your libs to the xml.
(it is easy if every lib have the same directory structure inside the zip-file)
The only bad is that you do not have a description for every lib.

Of course it would be nice if this feature would be added to the IDE.
Currently missing is a lib-uninstall feature in the application. Will look into this if i have time.
Logged

0
Offline Offline
Faraday Member
**
Karma: 16
Posts: 2855
ruggedcircuits.com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Nice! Even nicer would be a web-based interface that simply lists all third-party libraries and allows people to contribute, like shieldlist.org.

Just a suggestion!

--
The Rugged Motor Driver: two H-bridges, more power than an L298, fully protected
Logged

Norway@Oslo
Offline Offline
Edison Member
*
Karma: 13
Posts: 2033
loveArduino(true);
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Well, that is simple. smiley


A form for entering in an URL for a zip, and a field for version, and one for a description.

Then process and store in an SQL database.

Might add a 'report bug' (and then the form would need a contact mail) and maybe a vote up/down feature.


I'll be in on it, contact me if you want to set something up.


Downloader stays as it is, but downloads the XML from the site.

Cool idea, but should someone ask the Team if this is an effort best made part of the Arduino project?
Logged

0
Offline Offline
Faraday Member
**
Karma: 16
Posts: 2855
ruggedcircuits.com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

This kind of third-party repository interface has been around for many years and in several different communities. I'm wondering if there's even software already to manage the infrastructure.

For example, for Python:

http://pypi.python.org/pypi

For Perl:

http://www.cpan.org

For TeX:

http://www.ctan.org

In hindsight it's amazing that something like this doesn't already exist for Arduino! I guess you can say the Wiki/Playground is there but it's time for The Next Generation.

--
The Gadget Shield: accelerometer, RGB LED, IR transmit/receive, light sensor, potentiometers, pushbuttons
Logged

Norway@Oslo
Offline Offline
Edison Member
*
Karma: 13
Posts: 2033
loveArduino(true);
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Completely agree!
We should get a centralized third-party repository up and running soon.

[edit]Might rewrite the client for Java? Easier cross-platform and maintainable for the Arduino developers (as the IDE is java). Sorry to OP is this is the stupidest idea ever presented.[/edit]
« Last Edit: November 21, 2010, 09:18:11 pm by AlphaBeta » Logged

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

thanks for your kind responses.

I already thought about a posibility to post librarys.
And i would also host it on my server. I can configure it so it can also mirror it on your server.

the application might be able to load an xml from a repository like that already.

But some things need to be looked at if we do this.

At the moment everyone is compressing his own lib differently with different folder structures and different manual steps to install.

when we make a repository like that. Every library.zip should have the same structure and the structure should be checked by the upload script.

I do not know if i am allowed to host every library or what to do with librarys where the creator does not upload them on theyr own or the author is not longer aviable.

the cmd part in the xml should be removed so no one can post a malicious command in the xml. (for this every lib.zip needs the same structure to make it easier)

Doesnt need every lib checked before publishing in a repository like this?

as you see. I think the hardest part might be to get every lib-structure to be the same.
Most of them look the same but not all.

//Edit: yes. Sorry that this is not java but i can not write in java.
It is already cross platform except the 7zip exe i used.
And i know this part needs a rewrite.
« Last Edit: November 21, 2010, 09:51:32 pm by beowulf6 » Logged

Norway@Oslo
Offline Offline
Edison Member
*
Karma: 13
Posts: 2033
loveArduino(true);
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

I think we need to model the 'structure' after how the official team does it, and that is to zip the archive which the files resides in. That is, so one extracts within the libraries archive (this way one does not have to create a new folder before extracting).
Reference: http://www.arduino.cc/en/Hacking/LibraryTutorial


I think the community should be the 'check' so that we could have a flag for 'does not work' for instance. And maybe also a vote up/down.

We could add categories to the libraries. Math, Data Structures, Timing, Processing, Hardware Abstraction etc etc etc.
« Last Edit: November 21, 2010, 09:52:09 pm by AlphaBeta » Logged

Norway@Oslo
Offline Offline
Edison Member
*
Karma: 13
Posts: 2033
loveArduino(true);
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Sooo...

I've purchased a domain/webhotel and started on the UI: http://www.arduinolibraries.net/
Please come with ideas and feedback!

Nothing is carved in stone, and I'm not in favor of any one solution.



I for one think this effort can be of great service for the Arduino community.


I've created a first draft of an Arduino Library Markup Language
Sample XML: http://alexanderbrevig.com/hosting/arduinolibraries.net/ArduinolibML.xml
Sample XSD: http://alexanderbrevig.com/hosting/arduinolibraries.net/ArduinolibML.xsd



Thoughts and feedback VERY much welcome.

@beo6 since you know C++ you'll need just a minimal amount of time to understand Java
These types of applications is what works best on Java, IMHO.
Logged

Global Moderator
Dallas
Offline Offline
Shannon Member
*****
Karma: 210
Posts: 13030
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset


I suggest using "tags" instead of "categories".
Logged

Norway@Oslo
Offline Offline
Edison Member
*
Karma: 13
Posts: 2033
loveArduino(true);
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

They're intended to behave like tags, but I've got to add a tags input box to the form for entring new libraries.
True That.
Logged

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

Nice work.

i didn't expected so much response for my application especially from people that have more than 1000 posts.

But isn't there a upload field missing?

Will look to change my application as soon as the XML format is right.

So i will change it that every uploaded zip needs only 1 folder with the libraryname and inside that the library cpp files with examples.

I am no expert in C++ and don't want to learn Java right now.

I for one would ask why the Arduino IDE is Not! in C++.

But this might end in a programming language war.
Everyone should code in the language that he likes most. smiley-wink

@AlphaBeta´s Edit:
I don't really understand what idea you mean that is stupid. :-?
« Last Edit: November 22, 2010, 07:31:30 am by beowulf6 » Logged

Norway@Oslo
Offline Offline
Edison Member
*
Karma: 13
Posts: 2033
loveArduino(true);
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
But isn't there a upload field missing?

Will look to change my application as soon as the XML format is right.
There's probably several things missing. But, because I would want to keep track of versions, the 'upload a library' (which will actually be 'provide an URL to your zip archive) will be an action that has to do with a library version. So I think it's best to have a separate form for adding a new version of a library.

Feel free to have a look at the XML and rewrite it as you would like it to be. The most important features for me is:
  • any number of authors
  • a short library descriptions
  • any number of library versions, with a version number, a .zip and a short description

Quote
So i will change it that every uploaded zip needs only 1 folder with the libraryname and inside that the library cpp files with examples.
That is brilliant.

Quote
@AlphaBeta´s Edit:
I don't really understand what idea you mean that is stupid. :-?
If you thought I was an ass for suggesting a rewrite, I'd like to apologize. That's all.
Keeping this project a separate endeavor is probably not a problem at all. It is the service which is in focus, and when we get used to being able to easily download libraries, and have an XML and a backing website in place, adding a downloader to the IDE won't be hard at all.
Logged

Left Coast, CA (USA)
Offline Offline
Brattain Member
*****
Karma: 361
Posts: 17301
Measurement changes behavior
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
Quote
I for one would ask why the Arduino IDE is Not! in C++.

It's because the Arduino team used an already developed multiplatform/open sourced IDE used in the Processing project. This allowed the Arduino project to come to light much quicker then if they had to create the IDE from scratch. Nothing to do with language wars.  smiley-wink

Lefty
Logged

Pages: [1] 2 3   Go Up
Jump to: