You need to use EasyEDA editor to create some projects before publishing
Better user visibility & editing of spice .model & .subckt
2024 1
andyfierman 10 years ago
Sorry, this is a long post and may be hard to follow. It is related to: `https://easyeda.com/bbs_view_5.htm` # The Problem It has to be easy for users to: i) find the part they want and ii) for simulation, to be able to view and, if required, to edit the spice .model / .subckt for that part (*See note at end*); or iii) change to a different spice .model / .subckt. **Novices / newbies** need to be able to just put down a part with a spice .model / .subckt already assigned so they don't have to worry about it. EasyEDA is very close to being able to do that already just by the **Find Libraries...** button. It is not quite there yet because there are some parts in the libraries that do not have working spice models and of course some parts have no .model / .subckt. For example, the EasyEDA library contains several versions of the 2N5484 NJFET. The 2N5484 drops into a schematic and simulates OK. The 2N5484/PS drops into a schematic but fails to simulate with the error: `Error on line 7 : jq1 vbattery_1 jq1_3 vout 2n5484/ps` `Unable to find definition of model 2n5484 - default assumed` `unknown parameter (/)` `Model issue on line 10 : .model 2n5484/ps njf+ vto=-1.2796e+000+ beta=1.71347e-00 ...` `Unknown model type / - ignored` This will be meaningless to most novices. There seems to be no way in **Find Libraries...** or **Super Menu > Miscellaneous > Edit Symbol** or **Preview Symbol > Edit ** then **Super Menu > Miscellaneous > Edit Subckt** to view the .model / .subckt associated to the device. They *can* view the netlist and see the .model / .subckt in there: `.MODEL 2N5484/PS NJF+ VTO = -1.2796E+000+ BETA = 1.71347E-003+ LAMBDA = 1.93292E-002+ RD = 4.41873E+000+ RS = 4.41873E+000+ IS = 1.25479E-016+ CGS = 2.25000E-012+ CGD = 2.34000E-012+ PB = 1.14141E+000+ FC = 5.00000E-001` but to a newbie who does not know spice syntax, this will not help them. In this particular example the problem is because there are two errors in the .model statement. One is that the name of the model has a `/` in it. This breaks the syntax. The second problem is that the model as it is passed to ngspice from EasyEDA is something like this: `.MODEL 2N5484/PS NJF+ VTO = -1.2796E+000+ BETA = 1.71347E-003+ LAMBDA = 1.93292E-002+ RD = ` `4.41873E+000+ RS = 4.41873E+000+ IS = 1.25479E-016+ CGS = 2.25000E-012+ CGD = 2.34000E-012+ ` `PB = 1.14141E+000+ FC = 5.00000E-001` whereas it is written to wrap over several lines exactly like this (with the `/` replaced by `_`): `.MODEL 2N5484_PS NJF` `+ VTO = -1.2796E+000` `+ BETA = 1.71347E-003` `+ LAMBDA = 1.93292E-002` `+ RD = 4.41873E+000` `+ RS = 4.41873E+000` `+ IS = 1.25479E-016` `+ CGS = 2.25000E-012` `+ CGD = 2.34000E-012` `+ PB = 1.14141E+000` `+ FC = 5.00000E-001` where the `+` character is a continuation character and not a mathematical operator. **More experienced users**, although they can see the .model / .subckt in the netlist, cannot edit it to correct these mistakes. **Advanced users** will want to see the model: i) to check where it came from ii) to fix some of the things that may be broken iii) to edit the syntax to make it work in ngspice instead of PSpice or Hspice and so on iv) to replace it with a different manufacturer's - or even their own - .model / .subckt **Note that there may be some .model / .subckt that we may not want to show to everyone** simply because they could be copied straight into rival software (always a risk with plain text spice .model / .subckt). For example, EasyEDA appears to have very few opamp and comparator macromodel .subckts. Even opamp and comparator macromodel .subckts that are available from the vendors are not always good. They may not model how they behave as the power supply comes up, many do not model supply and even output load currents and almost none correctly model what happens if the input or outputs go above / below rails. Opamp models from some of the other online tools are very basic. All of these things may be OK for experienced users but the novice expects a model to behave like a real device. This is something that is very clear from the forums in CL. For opamps and comparators, I have been developing an opamp / comparator macromodel that has all these features. It can be given a set of simple parameters straight out of the device datasheet so we can supply models for almost any opamp or comparator! It is very much like the UniversalOpamp2 model in LTspice. However, the subcct for this macromodel could be copied straight into a rival tool, so we *may* want to keep that hidden from users. **Questions? Just Ask!**
Comments
dillon 10 years ago
I have the same idea with you. But we don't have time do it right now. accept.
Reply
Login or Register to add a comment
goToTop
你现在访问的是EasyEDA海外版,建议访问速度更快的国内版 https://lceda.cn(需要重新注册)
如果需要转移工程请在个人中心 - 工程 - 工程高级设置 - 下载工程,下载后在https://lceda.cn/editor 打开保存即可。
有问题联系QQ 3001956291 不再提醒
svg-battery svg-battery-wifi svg-books svg-more svg-paste svg-pencil svg-plant svg-ruler svg-share svg-user svg-logo-cn svg-double-arrow -mockplus- -mockplus- -mockplus- -mockplus- -mockplus- -mockplus- -mockplus- -mockplus-@1x -mockplus-

Cookie Notice

Our website uses essential cookies to help us ensure that it is working as expected, and uses optional analytics cookies to offer you a better browsing experience. To find out more, read our Cookie Notice