I've noticed when comparing library access using my desktop connection to Arduino and then using the web editor, the web edition doesn't provide me with access to SR04.h ....needed for a ultra sonic component boxed with the super starter kit. Is the the web editor intended for some other use? any advice gratefully received
Hi @connelsey. Unlike the desktop Arduino IDE, the Arduino Web Editor has every one of the ~4000 libraries of the Arduino Library Manager pre-installed. So it actually has immensely more "library access" out of the box.
However, not all Arduino libraries are in the Library Manager. That is likely the case with the library that provides the SR04.h file on your desktop. In this case, you will need to install the library, just like you needed to install the library to use it on your desktop.
In Arduino Web Editor, installing additional libraries can be done by following these instructions:
- Download the
.zipof the library you want to install, or zip the library from your computer if that's more convenient.
- Select "Libraries" from the menu on the left side bar of the web page.
- In the libraries pane that opened, click the upward pointing arrow button ("Import").
- If you get a dialog about importing your sketchbook, click the IMPORT button (though you might like to consider the option of importing your sketchbook).
- From the "Open" dialog that opens, select the
.zipfile of the library.
- Click the Open button.
- Wait for the import to finish.
Thanks for your email, I only appear to have access to this zip from another computer which has a CD drive and where I find the libraries I have so far used. Apologies for being so thick
No cause for apologies. This can be very confusing stuff. Please let me know if you have any questions and problems and I'll see if I can help get you up and running with Arduino Web Editor.
Thanks, so how would I access the zip file from my main computer, where I'd like to do my coding from and which does not have a CD drive. I can't see how to navigate to the correct zip using the web editor?
.zip file will need to be accessible on a computer you can open Arduino Web Editor on. But you only need that for the import. Once you have imported the library, it is stored on Arduino's server on the cloud, so it will be accessible when you are logged in to Arduino Web Editor from any computer
I extracted this SR04 file from my CD onto my computer, and then followed your 7 point plan of instructions down to number 6, but unfortunately I'm then presented with a message that tells me; Libraries could not be imported, parse library properties not found. Any advice?
The reason for this error is that modern Arduino libraries have a metadata file named
library.properties. The Arduino IDE has support for the old library format in order to provide backwards compatibility, but Arduino Web Editor only supports the new format of library.
It doesn't take much effort or special knowledge to convert a library to the new format though.
Please do this:
- Unzip the library
- Delete the
- Open the unzipped folder. You should now see
SR04.hand maybe some other files as well.
- Create a new file named
- Click the icon that looks like two pieces of paper that appears at the top right corner of the code block below when you hover your mouse pointer over it. This will copy the text to the clipboard.
name=SR04 version=0.0.0 author=unknown maintainer=nobody sentence=A library for the SR04 paragraph= category=Sensors url=http://example.com/ architectures=*
- Open the
library.propertiesfile you created in a text editor.
- Press Ctrl+V. This will paste the copied text into your text editor.
- Save the
- Create a new
.zipfile from the library folder.
- Repeat the import procedure I described in my previous reply.
Thanks for your continued patience, but now when I attempt to create a new file named library.properties, I get the message;
Error creating file, not implemented.
- could I simply download these libraries from elegoo as suggested on my CD onto my favoured computer?
Please provide a detailed description of what you did when you attempted to create the file.
I appear to have mislaid your message explaining how to create this library.properties file. could you please repeat it, allowing me to tell you the exact actions I took. Thanks
Thanks, so when I attempt to extract this HC-SR04 file, I'm asked where I'd like to copy to (strange it should ask about copying)....... I chose to download it to my own personal download folder on my C drive......I then delete this folder from my C drive....then, head back to my E drive, where my CD is held and open up the original HC-SR04 folder, and select create new file, I type libraries.properties and hit the complete button......then I get the, Error Creating file, Not implemented, message.
But, like I said before, could I not simply open up the old libraries from my original download of Elegoo on my preferred computer and perform the operation necessary to allow amalgamation of the libraries?
You're not supposed to delete the folder. I did say to delete the .zip file because I assumed you had copied the .zip file from the CD to your computer and I didn't want you to get mixed up between the original .zip file and the updated one you are going to create at step (9). But it's not required for you to delete it.
Most likely because you're trying to create the file on the CD drive. You need to create it on your hard drive.
Thanks for all your help, I think I'm just going to continue using my old laptop for coding and where I have access to both libraries.
I think it will be a whole lot easier if I just continue using my old laptop for coding, it has access to both libraries
Thanks for all your help and patience.
You're welcome. I'm glad if I was able to be of assistance. Enjoy!