Noob here. Looking for a way to create library components that contain attributes, like MFR, MPN, Description, all that sort of stuff that you want on the BOM. I see how to add them in the schematic, but not in the library. I want to create new parts that have all of these attributes already assigned so I don’t have to do it every time I make a schematic.
Thanks
dan
Open the Part Library Editor and click on the button with the capital ‘T’. That will open the Field Properties window. You can add any fields and their default values there.
Ummmm . . . . have you looked for an answer on the Forum? This was the topic of a few recent threads. Bring up the “Search” facility and seed it with, e.g., “MPN”, or “Fields” or “Adding custom fields”. See if it turns up threads such as:
Standard symbol field names initiative ,
or Order codes in components ,
or even try the EESchema Manual at …/KiCad/share/doc/kicad/help/en/eeschema.html#component-fields
Dale
Bingo! Thank you! That’s exactly what I wanted.
My next question is going to be about importing attributes, in order to build a library with similar items. For example, I like to build a library that is nothing but ceramic capacitors. So I would make a “prototype” part with all of the fields I want, like:
Value
MFR
MPN
Description
Vmax
Dielectric Type
Size
And then I’d like to be able to use a spreadsheet or other external list to build a gazillion parts by copying the part and filling in these attributes as it goes.
Pads can do this, Orcad can’t.
Can KiCad?
Search for “KiField”
And yeah, I did search the forum. I don’t know exactly what search terms I used but I didn’t find the articles that dchisholm listed. That would have answered my question so thanks. I just wanted to say that I did try to find the answer first. And I tried the HELP file also but didn’t find it. Problem is every program uses different terms, so I am searching for “attributes” (Mentor Graphics) but here it’s called a “field property”.
Thanks for the replies!
You might also like to take a look at KicadLibCreator (https://github.com/pioupus/kicadLibCreator)
By supplying a mpn this application does an Octopart lookup and will create a consistently formatted library with all your fields populated.
Thanks John, sounds perfect. I have downloaded the files, but there doesn’t seem to be any installation instructions. Do you know how to install and/or run this thing?
Also it says I need a api key from Octopart, with a link. I went there and registered but their HELP comes up with zilch if I search for api key. Do you know what’s going on there?
Thanks
Ah, found the api key and got one. Still don’t know how to install or run it though. Thanks.
It looks like you need to build it from source with QtCreator.
The easiest solution is as @bobc says, download QTCreator from qt.io. There is a freeware download if your can work within the constraints of the LGPL v3 (or GPL v2/v3) license. I think, for this project in any context, this is OK as it is an open source desktop app where the product itself is not being distributed (just the libraries generated). Don’t shoot my head though off if I am reading this wrong - I am not a commercial developer/lawyer so I have not done the due diligence that you might need to do to check this!
The first setup run asks for some paths to your libraries and the Octopart API key. You need to think very carefully about how you want your descriptors to look but there is a lot of flexibility using the %octo.nicenum% formatting.
I have always run it from within QTCreator - I have not had much luck trying to compile and run it freestanding but it does produce internally consistent libraries. Together with KiField - you can produce some coherent atomic libraries - and even sort out the odd Octopart error. It would be nice if you could run a batch run on it but the output needs a little checking - if only because although highly reliable not all the Octopart data is 100% complete (e.g. in one range of capacitors I ran through this, the dielectric was identified in most but missing in a couple of random values). I hasten to add, this is an issue with Octopart - not this app.
Thanks David - far as I can tell, KiField doesn’t allow adding parts to a library. It only allows editing the fields. Is that correct as far as you know? Thanks.
You have to have Python, then you have to install “easy_install”. ANd I had to add a path to my Python directory, and to Python/scripts (maybe not needed?).
Once easy_install is installed, you install KiField as
$ easy_install kifield
I don’t remember about the “$”, it was giving me trouble but I did get it installed.
KiField does do what it says, it exports the KiCad lib into a file that you can edit, then allows you to import it back to the KiCad lib file. But as I say, it appears that you can’t add parts. You can only edit (including adding / deleting) fields.
Here is what I am going to try next.
Based on looking at the lib file, I can see how each component is formatted. In my case I am adding a bunch of resistors, so same format and same fields.
I am going to try a mail-merge from a spreadsheet with all of the values and fields for the parts that I want to add, to build a new lib file.
This is how I do it with Pads (Mentor Graphics). I’ll let you know if it works. If it does, I won’t need KiField.
The mail merge works. It’s not what you would call elegant, but it will populate the .lib file with a jillion of the same thing if you want it to.
It would be nice if it was easier, but like I say I’ve perfected this method with Pads so it’s not too bad. If anyone has questions about doing this let me know and I will share the step-by-step scooby.
KiCAD will get there eventually… just look at @c4757p request for feedback on the new component (symbol) picker.
Personally I wrote python scripts to generate libs for resistors and other small stuff that comes in hundreds.
One question - what’s?
Mail Merge? Using Word, lets you take a document (library file) and modify specific parts (fields) and print them all out. Same way you’d generate a form letter with different names. I use that, and a spreadsheet with the component details, to generate a new library file.
ha, ‘form letter’ I would have understood