Ability to add 3d models to the symbols instead of to the footprints

Hello,

I have been busy lately with custom footprints/symbols/3dmodels. One of the things I loath a bit, are the extra steps you sometimes have to do. I want to do more with less work.

Current problem
When I pick a schematic symbol coming from either my custom lib or the kicad lib, I want that both footprint as well as 3D model paths are already configured correctly. This can be done but it requires some work.

I have an example which illustrate my issue. I often use tactile switches in both 6mm and 12mm footprint.

afbeelding

To work faster, I copy/pasted this symbol to my own custom library several times and why several times? Because I prefer to couple the footprints to the symbols. So you can skip the step of manually picking footprints.

But than… I often use a 12mm tactile with a cap. The footprint already exists in the default library. So if I am not interrested in the 3D model, I can just use that footprint from the default lib and be done with that. But no 3D models in 2023 is just :smiling_face_with_tear:

Current Fix
If you want to have a 3D model perse (which we obviously all want :stuck_out_tongue: ).You google for a step file, download it and store it somewhere on your system.

To add the 3D model to your board designs. You can do two things, you can configure the 3D model inside PCBnew itself. If you have many switches you also need to copy/past the altered footprint and manually do the annonation to quickly give every switch the correct 3D model.

But if you start a new project and want to use that same switch many times, you must repeat this step for every project. But doing the same grunt work in 2023 is just :smiling_face_with_tear:

afbeelding

So what do you do? In order to prevent repetive work you do the ‘other thing’. You can copy/paste the existing footprint to your custom libary in order to set the 3D model paths correctly. You must do this once for every symbol for which you want a 3D model. This is what I am currently doing. I do consider this as ‘grunt work’ but it is grunt work you do just one time per thing.

If you have done all that. You can just pick your ‘12mm-tactile-with-cap’ symbol in the schematic and already have the correct footprint as well as 3D model configured correctly. Ain’t that a blast?

My feature request :

(provided that it is possible to begin with)

What if you can already configure the 3D model path (and the often needed positioning offsets) within the symbol editor itself? This would eliminate the need to also copy/paste new footprints for every symbol. You can just use the already existing footprint of the default library.

Every time that you want to add a new component, you can copy paste an existing symbol to your custom lib. Than you can correctly couple an already existing footprint, add the vendor component and lastly couple and configure a 3D model. No more need to also create a new footprint just because you

Kind regards :coffee:

Bas

I understand where you are coming from, and for your workflow it may seem logical . . . but, from the logic of the symbol and footprint relationship I don’t think it makes sense.

The 3D model is a physical thing with pin spacing and other dimensions in real physical units, it makes sense to link this to the footprint which also has holes and pads to match the physical pin spacing and maybe a silkscreen representation of other physical attributes shown in the 3D model . . . the schematic symbol has none of this.

How would you position the 3D model in relation to the symbol so that it is the correct position relative to the PCB footprint ?

I did that work one time not for thing but for ever.
Before designing my first KiCad PCB in 2017 I have done my footprint library with each footprint having 3D model associated then I have done my symbol library with each symbol having footprint associated to it.
Now when I place symbol at schematic I have footprint and 3D model associated with it.
I have never even seen how footprint association at schematic looks like.
Of course if I want to use new element I have to add it to my library first.

1 Like

I understand what you are saying.

the schematic symbol has none of this.

I agree but I have a but: you do can add a footprint to a symbol’s properties. (In fact I think that most of us do this when making a custom symbol) So there is already some physical information to be found within a Kicad schematic. It just exists out of a path to some physical footprint right?

As I see it. A footprint is a physical property or attribute of a symbol. Therefor you can consider 3D models in a similar manner

You have a symbol:
afbeelding

The symbol has properties, one being a path to the footprint

That property points to this thing, da footprint.
afbeelding

And than we have a 3D model somewhere

And perhaps another supplementing 3D model?
afbeelding

You have to configure the path to these models somewhere right? Currently we do this in either PCBnew or in the footprint editor.

Does it really matter where we configure the path? whether we do it in PCBnew or do it in a symbol’s property box.

For those footprints of which I think I wont be using again or not often I still do it manually. In PCBnew I set the properties of these barely used footprints by hand.

How would you position the 3D model in relation to the symbol so that it is the correct position relative to the PCB footprint ?

What I would do:

Follow this workflow.

You add a symbol or you create a symbol in the symbol editor.

Than you add a footprint by clicking the library icon behind the footprint line inside the symbol property box.

This opens up the footprint library browser. There you search for your footprint within the default kicad libs.

From within this menu you can already press alt - 3 and examine if there is a 3d model.

From here I want to be able to right click on the footprint, the RJ12 in this case. And than open the footprint properties with the 3D model tab (or just the 3D model tab).

Than from within the 3D model tab I want to set the path and offsets correct and save it. The kicad libs are write protected because they are overwritten when you upgrade kicad anyways. I would therefor save the 3d model path and offset information as symbol properties in the kicad_sch. Or in the case of of creating a custom symbol, I would store it in the my personal custom symbol library.

Than when I create my board file and hit the update button
afbeelding
The 3d model paths and offsets should be copied to the appropiate footprints.

By doing it like this, you can store the 3d info within a symbol. And you can just copy/paste the symbol in eeschematic which will also result in copying the 3d information.

As kicad is now, you can copy/past a symbol, pick a footprint and set a 3d model in pcbnew, but copying the symbol will not result in copying the 3D information.

If 3d info can be stored within the schematic we can just copy symbol and automatically copy the 3d info without the need of creating a new footprint.

Kind regards,

Bas

You’re actually doing yourself a disfavour by writing a wall of text. Concision should be strived for.

At first I thought you wanted to store the 3D model path in the symbol. That would be wrong. A 3d model is not an attribute of a symbol. Symbols are not physical, despite what some users think.

But what you want is to change tthe GUI so that the 3D model path can be accessed from the symbol editor, most probably via the footprint editor. If you save the custom symbol with the footprint appropriately filled in, then you will get the associated 3d model when you reuse that symbol.

So your title is a little misleading, you really want the “Ability to edit 3d models paths (indirectly) from the symbol editor”

1 Like

Don’t you simply need to adjust your workflow ?

  • Open up the footprint library browser, find your footprint within the default kicad libs.
  • Examine if there is a 3d model.
  • Open the footprint properties with the 3D model tab (or just the 3D model tab).
  • From the 3D model tab set the path and offsets correct and save it.

then . . .

  • You add a symbol or you create a symbol in the symbol editor.
  • Than you add a footprint (already defined above) by clicking the library icon behind the footprint line inside the symbol property box.

Me, personally, I prefer to not increase library files sizes more than it is really needed.
I use many elements in SOT23 (NPN, PNP, digital transistors (NPN with resistors), double diodes (BAV99, BAV70, BAW56), some PMOS, and NMOS and even some LDOs). I have SOT23 3D model path only in one place in my libraries (with SOT23 footprint). I don’t understand your arguments to have it may be 20 times in my libraries. And the same with all elements that many of them uses the same footprint.

I thought it would be a nice backward compatible addition to what we already have. I only vent my idea because I believe it would be a further improvement of our already great Kicad.

A 3d model is not an attribute of a symbol. Symbols are not physical, despite what some users think.

I get that. But I am essentially just talking about a path + some offsets as attributes/properties. I mean a symbol already has a path to a footprint (which may not yet have a 3d model), than why not add a 2nd path for a matching 3D model while you are at it as well? It is not that strange, is it? The end result would be the exact same, a footprint with a path to a custom 3d model.

don’t understand your arguments to have it may be 20 times in my libraries.

I was talking specifically about those footprints which do not (yet) have 3D models. So I was not talking about those basic things like a SOT23. 12mm tactile switch and RJ12 connector are just 2 of the examples which have no 3D models.

My current list of custom 3d models
afbeelding

A single footprint can ultimately be used with more than one 3D model.

This single symbol…
afbeelding

…can be used with more 3D models than there are footprints. If you want to make separate symbols for every length of 6mm tactiles, you are going to have an equal amount of footprints. What I proposed would eliminate the need for all those footprints.

Don’t you simply need to adjust your workflow ?

Yes I do. Can’t afford to be tired right? :wink: :joy:

Open up the footprint library browser, find your footprint within the default kicad libs.
Examine if there is a 3d model.
Open the footprint properties with the 3D model tab (or just the 3D model tab).
From the 3D model tab set the path and offsets correct and save it.

The logic in this workflow seems sound to me. As is now, this seems to be the best/fasted workflow… for me that is.

Kind regards :coffee:

Bas

1 Like

Only for some symbols is the footprint closely tied to the component, such as the tactile switches you used as an example. For others like generic devices even if you put a default footprint in the field it’s likely to get changed so there is no bypassing the footprint assignment step.

But of course if you have a specific component you want to use then you could create a specific symbol for it and then assign it a default footprint saving you a bit of time.

Because the 3d model is dependent on the footprint even if one were to accept another attribute in the symbol it could get out of step with the footprint field.

True, BUT, it would require a need for all those symbols.
End result : gain nothing.

Realistically, for all the 3D switch variations, you need an equal number of footprints and another equal number of symbols, each symbol requiring a different description.
OR for all the 3D switch variations, you need an equal number of footprints which are already described (distance between pins etc.) and one symbol or many symbols each again with a different description.
The difference is surfing the symbols or surfing the footprints

Totally off topic, but the representative symbol for the switches displayed should be a push button.

That is indeed the general idea. When you pick a symbol you don’t just pick the symbol but you also pick… everything else.

If I need something like a resistor I sometimes still take a default symbol and than couple a default footprint but…
… if I recall correctly, Piotr over here uses unique symbols for different resistor values and packages.

Imagine if you want to add a 6mm tactile switch which is 12mm high to your schematic. The fastest possible method would be to press ‘a’ (add symbol), type a logical named string such as tactile_6x6x12 and hit enter. And than ofcourse, footprint as well as 3d models all would be good.

In my proposed workflow you would indeed require a unique symbol for every height, but as it is now you need a footprint for every height. And that footprint is solely needed to handle the correct 3D model. You are correct in that not much is gained, but I believe the workflow would be slightly faster.

Bas

With your system the same is required.

For either system you need a symbol and a footprint for each 3D image.

If you wish to include as many 3D models as you are able into this CAD, I really cannot see either method benefiting over the other.

With your system the same is required

With ‘my system’, the symbol itself would contain the path to a 3D model. Therefor all tactiles with different heights could use one and the same footprint, while the 3d model has been relocated to the symbol. That is the idea I am venting.

Same here. I don’t like the idea that we all must surf to snapeda or grabcad and all download the exact same things for all our projects and spend too much time with copying existing footprints and symbols just because we want a fancy 3D model. I mean… I cannot be the only person who wants 3D models for his RJ12 connector or 12mm tactiles right?

I still think that Kicad libs should become writeable and that an upgrade cannot accidently delete all one’s modifications. Think about it. Kicad has both symbol and footprint for an RJ12 connector. But just because I want a 3D model I have to copy the footprint as well as a the symbol to my own library and only because I cannot let the existing write-protected footprint point to a newly added 3D model.

A different addition I would do, is to let users install the default libraries by hand so they remain unaffected by a kicad upgrade.

Those things we download from snapeda or grabcad or whatever other site can’t they just be added to the default libraries or would the developers get in problems because of licences and such??

Regards,

Bas

I’m sure previous posters have said the same or similar, but attaching the 3D model to the symbol instead of to the footprint is counterproductive in many other cases.
For example as simple a component as a resistor has a generic symbol, but you can have THT vertical, THT horizontal, various length variations and sizes depending on power rating, and all kinds of different sizes of SMD resistors, each with their own footprint. Depending on which footprint you choose, the 3D models will be different too.
The same can be said for transistors, integrated circuits in different packages etc.
This would clash badly with the model you are suggesting, where the 3D model would be attached to the symbol.

(I could imagine a model though, where there are several different 3D-models attached to the footprint and you can choose which one will be the active one for each instance, and several footprints attached to a symbol by default in the library.)

1 Like

I don’t know about licences, but I do know many are not suitable for Kicad. eg.wrong pin placement, incomplete graphics.

It is still a symbol and a footprint for every 3D.

But they would no longer receive the Kicad upgrades which include new symbols and footprints that are drawn and tested to work on Kicad.

Personally, I don’t use Kicad standard symbols and footprints. I’ll either modify, to my requirements, a symbol or footprint from a Kicad library, or, I will build my own symbols and footprints. I find it is quicker and easier to create my own stuff rather than surfing for something then checking accuracy.

@hmk I believe you are not feeling me.

I am not talking about the basic stuff which already have 3d models like every last resistor. That is not my point.

I am talking about default footprints which have no 3D models and the payne around it to correct this. Like I said the 12mm tactile switch does not have a 3d model. If you use that 12mm footprint alot and don’t want to continously keep setting paths to a 3d model and also fix potential offsets per switch, you will be eventually forced to create a copy of that footprint to in private lib.

If however you would have the option of already setting a 3d model path within the symbol properties you do not have to copy the footprint to your private lib.

This is a normal kicad workflow for many users (I imagine it is?)

1). You just insert any default button symbol of choise like this one in eeSchematic
2). Than you can set the footprint path in the property box. (this is what I prefer to do it here)
3). During step 2 you can verivy if there is a 3D model present already.

But now you find out, that the 3d model of your switch is lacking. This is where my new idea may be employed.

4). set path to 3D model.

Doing step 4 will lead to step 5

5). set the offsets

From this moment, when you copy paste the symbol, you also copy the 3d model properties. And this is what my idea is about. You can also copy paste this symbol to other projects

(though it would be logical to make a unique symbol in your private lib for this particular 12mm tactile with round green cap)

Back to the normal workflow. Your symbol now has: correct footprint, 3d model, datasheet link and vendor part number. Now you can copy paste the symbol as many times as you want

6). multiply

And when your schematic is finished and you press the update button in PCBnew than you can see all your 3D models.

Besides using your own custom libaries, this would be by far the quickest method to configure 3d models. You don’t need to do difficult in PCBnew (query: can we push properties of one footprint to an other like you can do with pads in the footprint editor? that would also kinda solve this entire problem :see_no_evil:), you don’t have to add new symbols and you don’t have to add new footprints to your own libs. (you still should do that, to increase your workflow even further, but this is matter of taste)

It is still a symbol and a footprint for every 3D.

Having 3D model paths in the symbol, would eliminate the need for having unique footprints. Than you can just use a default footprint without a 3d model (the 12mm tactile)

You do, you would have to to do so manually. But my point is that it is undesirable that such an update would delete or overide any user made change or addition. That is the real problem. Perhaps an update tool which may add new things but does not change old things could work? idk.

If I could choose between having my hand forced into creating my own symbols and footprints or the ability to add or correct 3d model paths to a few footprint, I would choose the latter, why? less labour.

I personally find it a payne that I have to do so much trouble because I am unable to simply just fix a missing 3d model of a default footprint. I really think this should be changed one way or another.

Regards,

Bas

etc.

I doubt that is normal.

My method:

1/ (If I don’t have a symbol, find or make one and place it in a personal library first)
Then place the symbol from my personal library on the schematic.

2/ (If I don’t have a footprint, find or make one and place it in a personal library first)
Then assign that footprint to the symbol.

3/ (If I don’t have a 3D model, find or make one and place it in a personal library first)
Then assign that 3D model to that footprint.

So, forever more, I have a footprint with a 3D image assigned. I do not have to check anything. That footprint, with that name, in that personal library, has the correct 3D image assigned to it.

If I want a different (yellow) button 3D image, I copy the footprint, rename it 12PByel instead of 12PBgrn., find and place that yellow 3D image in a personal library and associate it with the 12PByel footprint.
Now, and forever more 12PByel has the correct 3D image associated with it, just as 12PBgrn has.

This is probably how most use Kicad.
This is the whole purpose of Personal Libraries and the assignment method currently used… to make the workflow easier.
When this system becomes too unwieldy, it is usually time to move onto Data Based Libraries.

1 Like

Why not? you do the exact same. We are litterly describing the exact same 3 steps.

We both start with placing symbols
We both immediately search for matching footprints (provided the symbol does not have one yet)
And if needed (in the event of a ‘new’ footprint) we also check if that footprint has a 3d model or not.

And if we miss anything, than we add it our libraries. I do that too, but I also try to use the default libaries before adding things to my own if that saves me labour.

There is a big difference.
I think it was @RaptorUK who first mentioned this.

In the case of Resistors, capacitors, inductors and electrolytics, I have one symbol and many footprints with attached 3Ds. You have many symbols with attached 3Ds and many footprints.

In the case of transistors and ICs, I have a few symbols with many footprints and 3Ds. You have many symbols with 3Ds and many footprints.

And having the 3Ds in the footprints would eliminate the need for having unique symbols.

And all the other push button footprints and associated 3Ds?

You end up with just as many footprints and 3Ds but instead of one symbol, you may have 20, compared to the current Kicad method.

This is not a real problem.
Once you have found the symbol or footprint you wish to modify, 4 mouse clicks and a short scroll (5 seconds total maybe) is all it takes to place that item into a personal library after which you may do as you wish with that item without fear of Kicad upgrades interfering.

How long would it take every month or so to manually place upgrades into Kicad libraries while checking to make sure none of those upgrades would affect symbols and footprints you have modified???

I could see how this might be attractive if you use the exact same parts over and over. I would not find it helpful, actually I would find it a hinderance.

Your simple case was a switch. Mine would be a connector. In most cases I have connectors on the schematic with vastly different physical characteristics, so there would have to be different symbols for each physical configuration.

Though I might consider such a relationship for 0805 resistors and capacitors. The effort to add them to the schematic → PBC is so small I personally would not consider it.