Good afternoon.
Is it possible to write more than one graphic symbol and more than one footprint for a component to the component database? If so, what is the syntax of the cell in the database, I can’t find this information anywhere in the documentation.
For example, there is some kind of LM317 type component in the TO-220 case, then I would like to assign to it in the database the possibility of choosing an alternative footprint in the form of a vertically standing, horizontally lying option, with spaced terminals in a scatter or in one line.
In Cadence CIS, this is implemented by simply comma-separated enumeration of the necessary symbols and footprints in the corresponding database fields, maybe there is a similar syntax in KiCad?
What is a “component”? Not intended to be a stupid question…
We have two possibilities that I can think of:
- Have different symbols, each one for an LM317 in a different footprint.
- Assign the footprint at the schematic level.
Once you know that you want a TO-220, in the schematic design you can choose whichever footprint you want based upon thermal and mechanical constraints. I do not use Cadence but I do not understand what you are missing. Or maybe I am missing what you do not understand. Or something…
You can define a footprint filter field in the .kicad_dbl file. If you provide a filter field eg TO220 from your database, KiCad will match footprints against it. When I’m back in front of KiCad I’ll share a snippet of my database showing this.
This is a snippet from my .kicad_dbl - the last section of ‘properties’ is the relevant section.
Most of my components have a specific footprint associated but where I want to allow a selection, you can define a ‘Footprint_Filter’ in the same way that the KiCad libraries do.
{
"name": "Voltage Regulators",
"table": "REGULATORS",
"key": "part_id",
"symbols": "Symbols",
"footprints": "Footprints",
"fields": [
{
"column": "Description",
"name": "Description",
"visible_on_add": false,
"visible_in_chooser": false,
"show_name": true
},
{
"column": "Datasheet",
"name": "Datasheet",
"visible_on_add": false,
"visible_in_chooser": true,
"show_name": false
},
{
"column": "Name",
"name": "MPN",
"visible_on_add": false,
"visible_in_chooser": true,
"show_name": true
},
{
"column": "Voltage",
"name": "Voltage",
"visible_on_add": true,
"visible_in_chooser": true,
"show_name": false
},
{
"column": "Manufacturer",
"name": "Manufacturer",
"visible_on_add": false,
"visible_in_chooser": true,
"show_name": false
},
{
"column": "Case_Package",
"name": "Case/Package",
"visible_on_add": false,
"visible_in_chooser": false,
"show_name": false
},
{
"column": "Stock",
"name": "Stock",
"visible_on_add": false,
"visible_in_chooser": true
},
{
"column": "part_id",
"name": "ID",
"visible_on_add": false,
"visible_in_chooser": true
}
],
"properties": {
"description": "Description",
"footprint_filters": "footprint_filters",
"keywords": "Keywords",
"exclude_from_bom": "exclude_from_bom",
"exclude_from_board": "exclude_from_board"
}
},
This is how the table looks in an SQL viewer where you can se the value of the footprint and the Footprint_Filters.
And this is how it works in the selection dialogue - showing the alternative footprints available in the drop down menu.
I am pulling the data from a mySQL database running Partkeepr. I have a number of Views that I have created that aggregate the parameters - it’s a sort of a poor mans EPR system.
Also, remember to restart kiCad each time you make any edits to the .kicad_dbl file.
I wanted to say that I would like to implement a similar functionality for selecting a graphic display of a symbol and a footprint from a drop-down list.
Thanks, I’ll try to implement a similar option.
For PCB items (Footprints) is possible.
For schematic items (Symbols) is currently not possible, there is an open Feature request on GL, but i don’t see a lot of interest both in the user-base nor between the developers in bringing it in any time soon.
Anyway, there are posts in the forum with some workarounds for this; none in my opinion are really clean solutions but, holding your nose, it can be put to good use.
Yes, it worked with footprints, but not with symbols, as you write. By the way, in order to select the necessary footprints, it was not necessary to use the footprint_filters field, it is enough to set a mask in the main footprint field, for example, LVT_Resistor_SMD:R*