i have created a tool to calculate analog filter component values with active and lumped topologies. I plan to have multiple file formats than can be emitted, one of them should be a KiCAD schematic. Since i have never used the ngSpice functionallity i thought i ask here some basics and may get a kickstart.
The first question i have is on the frequency domain of ngspice:
Is it at the moment possible to do a analysis in the frequency domain? I think i remember @holger answering to somebody else that it isn’t or at least only partially at the moment. If so what would be a good method of implementing a solution that has place holders that will be much likely to be used in future versions of KiCAD. Is there a good reference on what would be needed to accomplish my goal?
Second is on the Symbol and the underlying simulation model. In LTspice i can just take a universal OPamp and be done. In KiCAD i am not aware of a unbound OPamp or a universal/ideal model that i can pick and insert in the schematic. Does something exist or is there a workaround? If there isn’t what would be the most robust way to implement this? Can i create it an commit it to the official libraries? Maybe you @Rene_Poschl can give me an estimate on how much time it would take me to do this, if at all?
What i do in LTspice looks like this:
Above is nothing special, random picked values to show the principle. The example is a second order filter with a Sallen Key topology, to build higher order filters i’ll cascade multiple entities of this behind each other using a yet to be written script connecting everything and setting the component values right in each stage. I’d be happy about general thoughts on how to implement this in a robust manner, also constructive feedback is always welcome (though in this case there might not be much to be feed back.) as well as any resources that you think might be helpfull and relevant here.