6.1. Using Component Library Editor

6.1. Using Component Library Editor

  1. We can use the Component Library Editor (part of Eeschema) to make new components. In our project folder tutorial1 let’s create a folder named library. Inside we will put our new library file myLib.lib as soon as we have created our new component.
  2. Now we can start creating our new component. From KiCad, start Eeschema, click on the Library Editor icon libedit_png and then click on the New component icon new_component_png. The Component Properties window will appear. Name the new component MYCONN3, set the Default reference designator as J, and the Number of parts per package as 1. Click OK. If the warning appears just click yes. At this point the component is only made of its labels. Let’s add some pins. Click on the Add Pins icon pin_png on the right toolbar. To place the pin, left click in the centre of the part editor sheet just below the MYCONN3 label.
  3. In the Pin Properties window that appears, set the pin name to VCC, set the pin number to 1, and the Electrical type to Passive then click OK.

    Pin Properties

  4. Place the pin by clicking on the location you would like it to go, right below the MYCONN3 label.

  5. Repeat the place-pin steps, this time Pin name should be INPUT, Pin number should be 2, and Electrical Type should be Passive.
  6. Repeat the place-pin steps, this time Pin name should be GND, Pin number should be 3, and Electrical Type should be Passive. Arrange the pins one on top of the other. The component label MYCONN3 should be in the centre of the page (where the blue lines cross).
  7. Next, draw the contour of the component. Click on the Add rectangle icon add_rectangle_png. We want to draw a rectangle next to the pins, as shown below. To do this, click where you want the top left corner of the rectangle to be (do not hold the mouse button down). Click again where you want the bottom right corner of the rectangle to be.

    gsik_myconn3_l_png

  8. If you want to fill the rectangle with yellow, set the fill colour to yellow 4 in PreferencesSelect color scheme, then select the rectangle in the editing screen and edit (E), selecting Fill background.

  9. Save the component in your library myLib.lib. Click on the New Library icon new_library_png, navigate into tutorial1/library/ folder and save the new library file with the name myLib.lib.
  10. Go to PreferencesComponent Libraries and add both tutorial1/library/ in User defined search path and myLib.lib in Component library files.
  11. Click on the Select working library icon library_png. In the Select Library window click on myLib and click OK. Notice how the heading of the window indicates the library currently in use, which now should be myLib.
  12. Click on the Update current component in current library icon save_part_in_mem_png in the top toolbar. Save all changes by clicking on the Save current loaded library on disk icon save_library_png in the top toolbar. Click Yes in any confirmation messages that appear. The new schematic component is now done and available in the library indicated in the window title bar.
  13. You can now close the Component library editor window. You will return to the schematic editor window. Your new component will now be available to you from the library myLib.
  14. You can make any library file.lib file available to you by adding it to the library path. From Eeschema, go to PreferencesLibrary and add both the path to it in User defined search path and file.lib in Component library files.