Installing libraries in the Arduino IDE. Installing and connecting libraries in the Arduino IDE How to add new objects to the archicad library

Library parts in ArchiCAD are parameterized complex elements created in the system itself or in applications from other developers that can be used in the project as elements. At the first start of this system, the ArchiCAD Library is loaded.

You will need

  • - ARCHICAD.

Instruction

  • Copy to your computer required libraries to upload to archicad. A library is understood as a folder containing data used by ArchiCAD: textures, background images, library items, specification data. You can load the library both from a local drive and from a network drive, as well as from an FTP server and web pages.
  • In addition, use Archikad archive projects as a library, from which the program is able to read the library elements that are stored there. When working on a project, you can only use those library elements, textures, and specifications that are installed libraries in this project or uploaded individually.
  • Install the libraries in ArchiCAD. To do this, go to the "File" menu, select "Library Manager". The dialog box that opens has four tabs: The local network”, “Ftp Sites”, “History”, “Web Objects”. Go to the "Local Network" tab to load the library into ArchiCAD, which is located on a local or network drive. The list of loaded libraries is displayed in the right part of the bookmark window. To install a library, select it in the window on the left side, click the Add button.
  • Go to the second tab to download the library from the FTP server. This bookmark differs from the previous one by elements that set the parameters for connecting to the server. You can download the library in the same way as the previous step. To load GDL objects from web pages, go to the Web Objects panel, add them to your local libraries.
  • To view them, double-click on the Objects tool, the Object Settings dialog box will appear. The dialog contains a Library Parts Browser at the top of the window, as well as a System Tree Browser at the left. Select the desired display option.
  • The library already has most of the code that you will not need to write, the library makes it easy to work with a specific module or one of their types and it just needs to be included in your sketch.

    For example, if you want to display text on an LCD display without connecting a library, then you need to transfer several bytes of commands and data to it, which will take several lines of code, and most importantly, you need to know the type of microcontroller under which the LCD operates, the purpose of the commands that it controls, know its memory architecture, addresses and register assignments, for which you will need to find and re-read its datasheet.

    Whereas when writing code using a library (for example, LiquidCrystal_I2C.h) you can display text by calling just one library function:

    lcd.print("my text");

    You can include any library with the following command:

    "#include<файл.h>"

    <файл.h>- this is the very library that we connect.

    You can also see an example of connecting the library in the article.

    Before you start using the methods and functions of the library, you need to:

    • download (download to your computer)
    • install (place in the correct folder),
    • to plug (insert text “#include<файл.h>” to the sketch).

    Each library must contain 2 files with extensions .h And .cpp.

    The files of the first type contain:

    • class description,
    • constants,
    • variables.

    The second type contains method codes.

    Additionally, you need to understand that the files .h And .cpp may not lie in the root of the downloaded archive. They can also go with the main files "keywords.txt" and a folder with examples (examples).

    How to install the library?

    After you have downloaded (downloaded) the library to your computer, you need to install it. You can install the library manually or do it using the Arduino IDE:

    Installing the Library Using the Arduino IDE

    We will do this through the menu. Enter the menu:

    Sketch - Connect library - Add .zip library

    In the window that appears, click on the "This PC" icon and select the "Downloads" folder. If when downloading ZIP archive and from the site, you specified the path to save the file, then instead of the "Downloads" folder, specify the path to the file.

    Select ZIP file library you have downloaded. The file name may not match the library name. Then click on the button " Open » ( open ).

    This completes the installation of the library, you can start connecting it to the sketch.

    Important! After installing the Arduino IDE on the computer, it creates separate folder to store all libraries. For Linux OS "Scetchbook", located in /home/. For Windows OS, the "Arduino" folder is located in /My Documents/.

    Installing the library manually

    Unpack the ZIP archive you downloaded and place the folder (the folder name usually matches the library name) from this archive to folder:

    This computer Documentation Arduino libraries

    If the Arduino IDE was running (open) during copying, then you need to close all the windows of this program, then start (open) the Arduino IDE and you can start connecting the library to the sketch.

    The fact is that the program is constantly evolving and the number of its versions is constantly growing. If you would like to install new version Arduino IDE, then the libraries located in the folder ( This PC → Documents → Arduino → libraries) will be available in both the old and the new (installed) versions of the Arduino IDE, and the libraries located in the folder libraries Arduino IDE programs old version(which was installed earlier) will be available only in it (until you copy them to a new one).

    Where can I find the required library?

    For convenience, our website has a whole section, which is called -. Most libraries can be found on the Internet in the public domain.

    Also, a number of standard kits can be found on the official Arduino website: arduino.cc.

    What libraries are already installed?

    As we have already discussed - the IDE itself already comes with some .

    There are two ways to view installed libraries.

    Method 1

    To see which set is already installed, you need to go to the tab:

    Method 2

    The second way is to use the "Sketch" menu and the "Include Library" submenu. This way you can also see the list of libraries.

    Go to Sketch and select Include Library:

    Sketch → Include Library

    Possible mistakes

    Sometimes when installing libraries or in the process of using them, some errors may occur. Below we will analyze the main ones.

    'xxxx' does not name a type

    The error appears when the library is not yet installed.

    Also, an error occurs if the folder or library has the wrong name.

    The folder location address may be incorrect, or the Arduino IDE may not have been restarted!

    Wrong folder location

    Check if all libraries are at the right address. Folder addresses for different operating systems we have given above.

    Wrong library name

    The error appears when the name after the #include tag does not match the name of the library.

    incomplete library

    All necessary files and folders are missing.

    Library dependencies

    It is necessary to connect additional dependent libraries without which correct/correct work is impossible.

    Library parts in ArchiCAD are parameterized hard elements, made in the system itself or in applications of other developers, can be used in the plan as elements. At the first start of this system, the ArchiCAD Library is loaded.

    You will need

    • - ARCHICAD.

    Instruction

    1. Copy the necessary libraries to your computer to load into the archicad. A library is perceived as a folder containing data used by ArchiCAD: textures, background images, library items, specification data. You can load the library from both a local and network drive, as well as from an FTP server and web pages.

    2. Also, use as a library archival plans"Archicad", from which the program is able to read the library elements that are stored there. When working on a plan, you can only use those library elements, textures and specifications that are installed libraries in this plan or loaded individually.

    3. Perform the installation of the libraries in ArchiCAD. To do this, go to the "File" menu, select "Library Administrator". The dialog box that opens has four tabs: "Local Network", "Ftp Sites", "History", "Web Objects". Go to the "Local Network" tab to load the library into ArchiCAD, which is located on a local or network drive. The list of loaded libraries is displayed in the right part of the bookmark window. To install a library, select it in the window on the left side, click the Add button.

    4. Go to the second tab to download the library from the FTP server. This tab differs from the previous one in the elements that set the parameters for connecting to the server. You can load the library like the previous step. To load GDL objects from web pages, go to the Web Objects panel, add them to your local libraries.

    5. To view them, double-click the Objects tool, and the Object Settings dialog box will appear. The dialog contains a Library Parts Browser at the top of the window, as well as a System Tree Browser at the left. Select the desired display option.

    The Windows 7 operating system has pleased users with a new component - Libraries. They are places to manage files and documents. In the library, viewing files is carried out as in an ordinary folder. Here you can also arrange files - by type, date, etc. The library can contain the contents of various folders. In addition to standard libraries ("Images", "Music", "Documents", "Video"), it is allowed to create personal ones.

    You will need

    Instruction

    1. In the menu, choose Computer.

    2. Locate the Libraries tab on the left navigation panel and open it.

    3. On the toolbar, click Make library. It is also possible to press free space right click windows and prefer to context menu Create and then Library.

    4. Give the created library a new name. To do this, click Libraries in the navigation panel of Explorer or Computer, find the one you need, right-click on it. From the context menu, select Rename library, enter a new name and press Enter.

    Note!
    Objects are not stored in libraries. With the support of the library, it is only possible to track the folders that contain objects, view and organize them. For example, you have music files located on external and hard drives. With the help of the "Music" library, you will be able to organize integral access to them.

    Helpful advice
    There are several more methods to make a new library. One of them: select a folder whose files must be located in the library you made. Click on the folder with the right mouse button. In the context menu that opens, select Add to Library, after which you must prefer the Create Library command.

    A library is a special cultural institution that collects, stores and provides readers with information sources for temporary use. Preferably, library collections consist of printed publications: books, brochures, magazines, newspapers, etc. However, in specialized departments there are electronic editions on disks, microcopies, filmstrips and audio recordings. To make the most of your visit to the library, pay attention to a few points.

    Instruction

    1. Determine which one library you want to visit. Libraries differ in terms of availability and composition of the fund. They are mass (public) and specialized.

    2. The first are located in every microdistrict and prepared for a wide range of readers. Here you will find fresh detective novels, knitting magazines, children's books, and famous encyclopedias. The stock of the public library is diverse, but rather superficial. This is a collection of books for fun, not for serious work.

    3. Specialized libraries exist for certain categories of readers: university, school, medical, scientific and technical, libraries for the blind, libraries of foreign literature, etc. Here documents of a certain subject are collected. The selection is carried out very scrupulously in accordance with the characteristics of the institution that the library serves. Often, the rarest editions of past years are stored in specialized funds along with the latest industry publications.

    4. To be eligible to use the library, you must obtain a library card on your first visit. Traditionally, it is issued on the basis of passport data, but additional documents may be required. For example, for students - a student card of a given university, and for children - a certificate from the school. The reader's card is nominal, it cannot be transferred to other people. The ticket must be presented at all visits to the library. There is a nominal fee for the form.

    5. After registration, observantly read the rules for using the library. They list the main services that the institution offers, including paid ones, the working hours of departments, data on the use of various funds, the terms for issuing books, etc. The rules also describe in detail the design of the library and the purpose of each of its subdivisions.

    6. It is necessary to start the selection of literature from the reference unit: catalogs and file cabinets. In small libraries, colleagues know the fund very well and can find a book from memory. But in large, catalog information is indispensable. The reference unit will correctly answer whether there is a book in the library and in which department to look for it.

    7. Catalogs are alphabetical and systematic. In the first, cards with presentations of all the books in the library are arranged alphabetically. It is easy to search in it if we keep the author and title. The basic rule of the alphabetical catalog: if there are more than 2 authors, look for a book by title.

    8. The systematic catalog contains expositions of books grouped by branches of knowledge. Here it is convenient to select literature on a specific topic. Find the desired section on the catalog box, separators with more detailed questions will be installed inside it. In the thematic sections, the cards are arranged alphabetically.

    9. Often, a systematic catalog is supplemented by a card file of articles. It contains sections similar to the catalog, but contains cards with presentations of magazine and newspaper publications. For the comfort of readers, library staff also maintain small file cabinets on popular topics.

    10. In many libraries, in parallel with traditional card libraries, there are electronic catalogs and file cabinets. The search in them is organized according to different signs and is subconsciously intelligible. The advantages of electronic databases are obvious: ease of use and speed of acquiring information. But pay attention to the chronological framework of the electronic catalog - it can only contain information about new arrivals.

    11. After the information about the book is found in the catalog, fill in the reader's requirement. Do it diligently and according to the example accepted in the library. Usually, the requirement indicates the code of the book (its “address” on the shelf), the author and title, year of publication, data about the reader. Present the completed request to the department employee.

    12. Every library has at least two departments: a subscription and a reading room. Depending on the profile of the library, its structure may additionally include: a reading room for periodicals, a reading room for electronic publications, a reading room for new acquisitions, a music department, a department for rare books, a subscription for children's literature, etc.

    13. The reading room assumes work with documents only in this room. Here the rarest and most expensive editions are issued, which are stored in the library in an exceptional copy, or books of increased demand. Ask if there is a possibility of photocopying books from the department's fund. This paid service is very convenient: having made a copy of the necessary pages, you can work with them at home.

    14. From the subscription fund, publications are taken home for a certain period. This section has open and closed parts. In the first one, you can search for books on your own, from the 2nd one an employee will bring them at your request. The open part of the fund is organized by thematic thesis. Look for inscriptions on the shelves about what writing is placed on it. On the shelves of the section, the books are arranged alphabetically by authors and titles. Once you receive the book, please ask for a return date. A fine will be charged for violation. However, if the book is not relevant to other readers, you can extend the time of using it.

    Related videos

    Note!
    If you are unable to find literature independently, feel free to contact the library staff for support.

    Helpful advice
    In the reading rooms, they organize thematic expositions of literature and conduct information reviews about new arrivals.

    Related videos

    Installing and connecting the library to arduino is a fairly common operation, any developer will face it sooner or later. External pluggable code in all programming languages ​​is used to save time. Arduino is no exception: many sensors, modules, shields and motors require enough complex schemes interactions that are difficult to implement in your code. It is much easier and faster to download the required library, quickly connect it manually or using the Arduino IDE, and then use it in all your sketches. In this article you will find a short instruction on connecting and using libraries.

    The library in Arduino is the program code in external files, which can be installed and connected to your sketch. The library stores various methods and data structures that are needed to simplify the work with sensors, indicators, modules and other components. Using libraries greatly simplifies the work on projects, because you can focus on the main logic of the program without wasting time on a lot of little things. Today, a huge number of libraries are posted on the Internet, where they can be easily downloaded, and completely free of charge. can be found on our website.

    From point of view file system a library is a directory containing certain folders. During compilation and build Arduino project The IDE automatically includes in the code those classes, data structures, and methods from libraries that are included and used in the sketch. Thus, the only thing we need to do is put the appropriate instructions in our code, after making sure that the required library is installed.

    How to find out the list of connected libraries to the Arduino IDE

    Each installed library contains one or more examples to work with. They are used to display the capabilities of the device connected to the Arduino. Therefore, the most fast way get a list of all installed arduino libraries - use the list of examples in the Arduino IDE. To do this, select File from the main menu, and then open the Examples submenu.

    Another way is to use the Sketch menu and the submenu - Include Library. There you can also see the list of libraries:

    Including the header h file with the #include operator

    To start using the library, you need to include the header h file at the beginning of the program with the include directive. For example, the inclusion of the LiquidCrystal.h library will look like this: #include

    You can see the full example using the library itself.

    Required files in the library

    Each library must contain at least 2 files - a header file with .h extension and a file with source code with .cpp extension. The header file contains the class description, constants and variables. The second file contains the method codes. In addition to the two main files, it may contain text documents keywords.txt and an examples folder with codes for examples of using the library. The h and cpp files are not necessarily in the root

    Editing files is not possible in the Arduino IDE, all changes can be made in any text editor, or the C++ development environment. This is due to the fact that in the Arduino IDE we do not work with cpp files, the code editor is not designed for “pure” C, it only works with the Arduino language.

    Where to find the required library

    The required library can be downloaded from the Internet. Most of the libraries are available on the Github site. After downloading the library, it is important to add it to the correct folder so that the compiler can find it and load the sketch. The folder where all the codes are saved is created on the computer after the Arduino IDE is installed. For operating system The Linux folder is named “Scetchbook” and is located in /home/, on Windows folder"Arduino" can be found under "My Documents".

    All libraries that are installed additionally are located in the “Libraries” folder. For earlier versions of Arduino, you need to create the folder yourself, and starting from version 1.0.2, it is added automatically when installing the Arduino IDE.

    How to install the library. Step-by-step instruction

    As soon as the library is downloaded to the PC, you need to start installing it. There are two ways to install the library - using the Arduino IDE tools and manually.

    Connecting with the Arduino IDE

    The library is downloaded as a zip archive. To enable it in this way, the archive does not need to be unpacked. To install it, you need to go to the menu Sketch - Include Library - Add .Zip Library.

    When the window opens, you need to select the "downloads" folder in the "This PC" section. If, after loading the library, it was saved to another location, you need to specify it.

    Then you need to select the downloaded file and click "open".

    The library will be installed and you can use it. In order to start using the examples File - examples, you need to restart the Arduino development environment.

    Installing a library manually from a zip file

    Before starting the installation, you need to exit the Arduino IDE. The downloaded zip file with the library needs to be unpacked. As a result, we will get a folder in which the library files with the .cpp and .h extensions and directories will be located. The resulting folder will need to be placed in libraries.

    On Windows, the libraries folder can be found along the route My Documents - Arduino - Libraries. On Linux, this will be the libraries folder with the sketches.

    At the end, you need to restart the Arduino IDE, the downloaded library will be available for inclusion via Sketch - Include Library.

    Errors when connecting the Arduino library

    Below is a list possible errors when installing the library and how to deal with them:

    • 'xxxx' does not name a type - this error appears if the library has not yet been installed, the folder or library is named incorrectly, the folder location address is incorrect, or the Arduino IDE has not been restarted.
    • Wrong folder location - if this error is displayed, you need to check if the library is in a folder that is searchable by the environment.
    • Incorrect library name - an error occurs if the name after #include does not match the name of the library.
    • Incomplete library - may appear if not all have been downloaded necessary files and folders.
    • Library dependencies - since this type of library only works with additional ones, you need to initially include them.

    Instruction

    Copy the necessary libraries to your computer to download in . A library is understood as a folder containing data used by ArchiCAD: textures, background images, library items, specification data. You can load the library both from a local drive and from a network drive, as well as from an FTP server and web pages.

    In addition, use Archikad archive projects as a library, from which the program is able to read the library elements that are stored there. When working on a project, you can use only those library elements, textures and specifications that are installed libraries in this project or loaded individually.

    Install the libraries in ArchiCAD. To do this, go to the "File" menu, select "Library Manager". The dialog box that opens has four tabs: "Local Network", "Ftp Sites", "History", "Web Objects". Go to the "Local Network" tab to load the library into ArchiCAD, which is located on a local or network drive. The list of loaded libraries is displayed in the right part of the bookmark window. To install a library, select it in the window on the left side, click the Add button.

    Go to the second tab to download the library from the FTP server. This tab differs from the previous one in the elements that set the parameters for connecting to the server. You can download the library in the same way as the previous step. To load GDL objects from web pages, go to the Web Objects panel, add them to your local libraries.

    To view them, double-click on the Objects tool, the Object Settings dialog box will appear. The dialog contains a Library Parts Browser at the top of the window, as well as a System Tree Browser at the left. Select the desired display option.

    Related videos

    Sources:

    • libraries for archicad
    • Object Libraries for ArchiCAD

    During the installation of the Archicad 13 program, certain difficulties may arise only if you use an incorrect installer or try to crack the protection, which is strictly prohibited. In case of detection unlicensed version immediately contact the developers of Archicad 13.

    You will need

    • - computer;
    • - Internet access;
    • - means of payment.

    Instruction

    Purchase software Archicad 13. Depending on the location of the distribution, run the Setup.exe file from the root folder. Carefully read the terms of the license agreement, and then install the software on your computer, if they suit you.

    If you downloaded the distribution package of the program from any Internet portal, check the files for viruses. It is best to download this software from the official websites of the developers or purchase it from well-known online stores.

    During the installation of the program, set certain parameters at your discretion, and then connect to the Internet to complete the registration of the software product. Carefully follow the menu instructions and rewrite the activation code so that you can later use it during reinstallation and reduce the registration time. Do not provide further given code outsiders.