Lost in Kicad libraries

He starts off “As a first step create a new project just for following this tutorial”.
That is a part of the narrow track"!

I don’t want to do that. I already have a project.

I start with File - New Footprint, that’s what I want do. The dialog just asks for Footprint name.

Just now, I can’t get further because I have my unsaved footprint blocking make a new one. The dialog points to kicad root,so I save and get Footprint exported to file “C:\Users\Robin Hayman\Robins documents\IoTkit\Kicad\Resistor_0.25W.kicad_mod.”
So it should be safe to close the new foot print. Exit with warning ‘Not saved’. But it is exported to ok.

So now I am free to restart. Kicad already has project “Project name:
C:\Users\Robin Hayman\Robins documents\IoTkit\Modules\Term 4.4\Term 4.4.pro” That has .sch and some custom symbols. Continue with it.
Now select Kicad Footprint icon.
A dialog pops up
“Loading footprint libraries”. I does not say whic ones. It should say
"Loading library collection from c:…
so I know what I am loading. Instead it loads a collectionfrom an unknown place. I can deuce by content that is a Digikey library read only collection…
I had no say in this.
This a dead end.

Instead I can got to Preferences - Manage Footprints ad choose Project specific libraries

It lists two nicknames, digikey-footprints with path
and Term 4 with path.
Are these nicknames for Library Collections sometimes called tables?
Both are marked Active.
I choose Term4 and OK.
Now Footprint dialog disappeared. Just Kicad now.

Dead end? I was managing Footprint library.

Stop here. What next?

Back to

@bobc
Thanks for how to recover from export and recover .kicad_mod files.
I am trying do that.

Blockquote
How to recover my footprint in a xxx.kicad_mod file?

    First, find the path of the file.
    Create a new folder C:\my_kicad_data\my_footprints
    Copy the file to that folder
    Go to the Footprint Library Table editor
    Click “Browse libraries”
    Navigate to your folder
    Add it to the table

@bobc Where is the Footprint Library Table editor
Do you mean Kicad - Manage Footprint Libraries
But it has no browse.

Follow the tutorials, they have been written for you. They are not intended to fix your immediate problem, but to give you the understanding required to fix problems you might encounter, or better avoid them in the first place.

Creating a new dummy project for the tutorial is not difficult.

There is no such thing as library collections.

2 Likes

Yes I do.

Good point, it has been replaced with the “folder” symbol.

2 Likes

@bobc

The saved footprint is at

C:\Users\Robin Hayman\Robins documents\IoTkit\Kicad\Resistor_0.25W.kicad_mod.

Create a new folder ...\IoTkit \Kicad \exported footprints
Add it in to the table. 
Then a long list of  libraries  load
It would be much better if it listed the name of each library collection it is  loading before it sarts the big long list
e.g System footprints
Digikey foot prints
Local user footprints.
Kicad dos not make enough use of collection names to say what is going on
At the end of the listing, I got a message
There were errors.
My particular footprint did not load.
Any ideas?

How do you get here?

A footprint can only be saved into a library. A library is a folder whose name ends in .pretty, for example maylib.pretty. And the library must be loaded in the fp-lib-table with “Manage Footprint Library…”

Of course, a footprint can be copied with the system file browser to any other folder not ending in .pretty. But in this case it would not be recognised as belonging to any library.

1 Like

@pedro > “How do you get here?”
By trying to attach a Digikey library and messing up somewhere.

But I still want to recover my footprint!

Save does not work because the Digikey target library is read only. And something is choosing to write my footprint there (Hint: Digikey set me up some how).

The the only option left was Save as …
which makes a xxx.kicad_mod file which I would now like to make into a .pretty and put in my User library.

Should I just wrap the kicad_mod in a pretty folder and put it in the right place ? From comments above I understand Footprints are written in .kicad_mod format.

@bobcThere is no such thing as library collections.”
Isn’t the KiCad System library just that, a protected collection of libraries?
And this Digikey thing adds another protected collection of libraries which somehow, my footprint wants to write to but can’t because it is write protected.
And Kicad does not tell me (If I recall correctly), which collection of libraries it is trying to write to, it just says something failed along the way.

Kicad then displays the merged set of collections of libraries as a linear list of libraries and it does not tell you where they came from or if they are protected. And my User library is not in the linear list.

Have I got messed up by Digikey writing:

“(fp_lib_table (lib (name digikey-footprints)(type KiCad)(uri “C:/Users/Robin Hayman/Robins documents/IoTkit/Kicad/digikey-kicad-library/digikey-footprints.pretty”)(options “”)(descr “”))”

What is fp_lib_table about?

As a fix, do I need to add another line entry here pointing to my stuff?

Is p_lib_table a list which binds nick-names to file locations and somehow I have lost that binding or Digikey overwrote mine with theirs, when it should have added to the nick-name / file binding list?

It is getting too late to attack this again tonight. I will get back to it soon and I will have a go with the suggestions above and perhaps a bit better understanding.

Thanks for help

The library tables tell kicad where libraries are and under which name (nickname) the libraries should be addressed. (The nickname defines the name used by kicad, the path is the name used by the operating system)

Yes only libraries that are in the lib table are known to kicad. If your library is not in the library table then kicad does not know about it.

Again read Creating a new footprint library with the support of
Library management in KiCad version 5 and Tutorial: How to make a footprint in KiCad 5.1.x (From scratch)?

1 Like

OK.

I am going to give up here and start a new thread
Kicad: Configuration by Convention : model 1

Help me make Model 1.

What do you mean with “model 1”?

why don’t you give up wasting people’s time and just read the tutorials that have been suggested??

1 Like

How about the tutorials are not accurate stating to click buttons or select pull-down menu options that don’t exist at least in version 5.1.5?

I was checking out this thread along with others and reviewing tutorials seeing references to items like clicking “Save footprint to new library” or “Select library as active”, but the tutorial does not say how. Where does either of these buttons or command selections exist? I don’t see either in the File menu as one tutorial references. All I see is a Save button whether it is in the top row, under the File menu, or in the context menu that appears when right-clicking a footprint library in the browser list. Click any of these save buttons, nothing happens. Robin appeared to have the same problem, except he was getting the wrong library. I can’t get any library selected to save the footprint and so it doesn’t save. I have been able to intermittently get a context menu to come up asking me what library to save the footprint. If that happens, I can save the footprint to a library. No issue. Most of the time, however, I get nothing. I don’t so much as get an error. I have tried saving footprints on two different computers with KiCAD 5.1.5 installed finding that trying to select a library to save a footprint is hit and miss. Is there really a way to select a library to save a footprint?

Also, one sentence in the tutorial also states that local verses global footprint libraries allow libraries of the same nickname to co-exist. Yes, the tables allow that, but the Footprint Editor will only list the global library and not the local. So even between local and global library tables, the nickname appears to need to be unique to get full use of a library.

1 Like

So then either download the version used in the tutorial, or apply some basic software-fu.

In the version I’m using it’s called “save as” and I don’t see how this could be any simpler.

But if he’d just READ the provided information he would at least understand how symbols and footprints are organized into files/directories and the role of the library tables.

Demanding that someone start from his messed up installation and understanding rather than a blank slate is just wasting time on both sides.

2 Likes

These phrases only appear in the version 5.0 section of the how to make a new footprint library tutorial (all other tutorials i made do not have these phrases in them)

If you are on version 5.1 then a section about 5.0 is clearly not the place to look for information. (The old section is kept around because 5.0 is still quite often used)

Oh, I know how it can be simpler, gray out and disable the Save button so the user would then be forced to use the Save As and I believe then it just takes the OS file system route to saving the footprint. People are going to be gun shy about using the OS file system to build a library repository. The schematic symbols don’t work that way, right? The multiple symbols are bundled into one library file. Otherwise, I agree with your argument about due diligence and Rene’s tutorial does revile that the individual footprints are their own self-contained item that can be manipulated by the file system. (Of course, try doing that with a Subversion repository.) What led me to this thread and I think the other guy as well is a software bug which I would not blame the user as a training issue.

From what I am understanding the bug to be is that an empty library is an issue that causes a crash. The work around (aside from using the OS file system) was to have the user have a footprint ready to put in a new library immediately on creation so the ‘Save footprint to new library’ helped with the situation. With version 5.1, the error seems to now be trapped (no crash) but there seems to be some difficulty in handling the error (what to do with it). What I have found to work consistently thus far (without using the OS file system and following Rene’s older 5.0 tutorial) is to save a footprint to the new library immediately after naming the footprint before doing anything else with that footprint. The context menu will appear at that point and let the user populate the new library. If importing an existing footprint to a new library, best just to use the OS file system as the context menu may or may not appear.

Version 5.0 could already handle empty libs. But the process for creating new libs was the same as in version 4 so the tutorial is written for the oldest version it applies to. (and version 4 indeed had a problem with empty libs.) I now separated the tutorial parts a bit more and made it even clearer for which versions each of them applies.

2 Likes

Well, if your footprint is still at C:\Users\Robin Hayman\Robins documents\IoTkit\Kicad\Resistor_0.25W.kicad_mod, just move it to a .pretty folder.

Okay, looking at the following web page:
https://docs.kicad.org/5.1.5/en/getting_started_in_kicad/getting_started_in_kicad.html#layout-printed-circuit-boards
I still see a reference to a set active library button with respect to the footprint editor. Notice the URL does show that the tutorial is in reference to version 5.1.5. Rene, am I still not looking in the at the correct documentation? I would appreciate either being pointed to content that is up to date or why I don’t see the button. Fortunately, I will complete my board design today. I am certainly a fan of KiCAD and appreciate the efforts of the contributors.

Ah that is where the confusion comes from. Well we were discussing the FAQ articles of this forum not the official documentation. The official docu is sadly out of date in places. (So it might be better to use the forum FAQ instead. At least at this point in time.)

2 Likes

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.