Hello,
I have created a schematic symbol in LTSpice from a circuit. I've stored the original spice list in a folder in the LTSpice directory in Documents.
When I create a circuit, I can call up my schematic symbol and place it into the main schematic i.e. its shows up in the LTspice 'Select Component' tab.
However, when I try to run the sim, I get the following error
'Missing Schematic(s) of the hierarchy: myfilename'
then
'Trouble Generating Netlist . . .etc'
So, I think what's happening is that the symbol is not finding the associated schematic. Where should I save it? I'd like to be able to use the part cross all my directories etc.
I have 'The LTSPICE IV Simulator' book by Gilles Brocard, pages 345 to 352, and followed it as best I can but its not really clear on this point.
Thank you
I have created a schematic symbol in LTSpice from a circuit. I've stored the original spice list in a folder in the LTSpice directory in Documents.
When I create a circuit, I can call up my schematic symbol and place it into the main schematic i.e. its shows up in the LTspice 'Select Component' tab.
However, when I try to run the sim, I get the following error
'Missing Schematic(s) of the hierarchy: myfilename'
then
'Trouble Generating Netlist . . .etc'
So, I think what's happening is that the symbol is not finding the associated schematic. Where should I save it? I'd like to be able to use the part cross all my directories etc.
I have 'The LTSPICE IV Simulator' book by Gilles Brocard, pages 345 to 352, and followed it as best I can but its not really clear on this point.
Thank you
ok - I think Ive cracked it.
1. Create the part. Replace PSU and input output pins with ports as applicable, incl. the GND
2. Label the input output ports and note carefully the order
3. Open the net list view
4. Right click and open in the netlist editor
5. edit the first line of the netlist '.subckt <name> port1 port2 . . . portn
6. move to the end of the file and delete .backannotate
7. replace end with ends <name>
8. return to the top of the file and highlight .subckt <name> port1 port2 . . . portn
9. Right click
10. diologue box will ask if you want to automatically create a symbol for the part,, click yes
11. symbol will open, you can edit it by moving pins around etc to yoursatisfaction.
12. When finished click save
13. Symbol and its associated circuit will be saved in . . . Documents/LTspiveXII/lib/sym/AutoGenerated
14. You can leave it there and when you want it, look for it in the AutoGenerated folder found by looking under the top directlor tab in the component placement dialog box or
15. you can copy it and place it in the main component placement folder (where you have transistor, current source etc symbols etc) which is what I have done
Seems to be working ok
1. Create the part. Replace PSU and input output pins with ports as applicable, incl. the GND
2. Label the input output ports and note carefully the order
3. Open the net list view
4. Right click and open in the netlist editor
5. edit the first line of the netlist '.subckt <name> port1 port2 . . . portn
6. move to the end of the file and delete .backannotate
7. replace end with ends <name>
8. return to the top of the file and highlight .subckt <name> port1 port2 . . . portn
9. Right click
10. diologue box will ask if you want to automatically create a symbol for the part,, click yes
11. symbol will open, you can edit it by moving pins around etc to yoursatisfaction.
12. When finished click save
13. Symbol and its associated circuit will be saved in . . . Documents/LTspiveXII/lib/sym/AutoGenerated
14. You can leave it there and when you want it, look for it in the AutoGenerated folder found by looking under the top directlor tab in the component placement dialog box or
15. you can copy it and place it in the main component placement folder (where you have transistor, current source etc symbols etc) which is what I have done
Seems to be working ok
Last edited:
It's not easy is it 🙂 and when you want to do it again you've forgotten.
This was for a sub circuit which is very similar:
Installing and using LTspice IV (now including LTXVII). From beginner to advanced.
This was for a sub circuit which is very similar:
Installing and using LTspice IV (now including LTXVII). From beginner to advanced.
Ahh - I see our steps are very similar - mine probably not as accurate as yours though I'll admit!
🙂
🙂
I find that once I nail something in LT that I have to write it down or else I'll forget when I need it again.
Lol, I've got the big blue book as well 🙂
Lol, I've got the big blue book as well 🙂
Lol, I've got the big blue book as well
This is also helpful:
Undocumented LTspice - LTwiki-Wiki for LTspice
- Home
- Design & Build
- Software Tools
- Creating Own Parts in LTspice