unix_setup.txt 09/03/2005 David MacQuigg ============================= Setup to Run HSpice at U of A ============================= Unix Setup ---------- Add the following line to the .cshrc file in your home directory: alias hsp 'source ~edatools/setups/scripts/setupHSPICE.csh' Then, when you want to use HSpice, just type the alias hsp. This will automatically set up your path and environment variables. Note: This is a very simple script, with no cleanup of previous settings. So put it *after* any possibly conflicting settings in .cshrc, and use it once from a fresh shell. Restart the shell if you need a fresh or altered setup. Example Session with HSpice & AvanWaves --------------------------------------- To run HSpice, cd to the directory where you have your project files, then run commands like the following: macquigg@quad:~/HSpice/proj/nmos1> ls makefile nmos1.sp ### Note 1 macquigg@quad:~/HSpice/proj/nmos1> hspice nmos1.sp > nmos1.out >info: ***** hspice job concluded real 1.0 user 0.4 sys 0.1 macquigg@quad:~/HSpice/proj/nmos1> ls makefile nmos1.out nmos1.sp nmos1.st0 nmos1.sw0 ### Note 2 macquigg@quad:~/HSpice/proj/nmos1> awaves & ### Note 3 < many lines of license and system info > macquigg@quad:~/HSpice/proj/nmos1> ls makefile nmos1.out nmos1.sp nmos1.st0 nmos1.sw0 macquigg@quad:~/HSpice/proj/nmos1> make clean rm -f *.out *.st0 *.lis *.sw0 *.ac0 *.ic0 *.pa0 *.tr0 macquigg@quad:~/HSpice/proj/nmos1> ls makefile nmos1.sp [Note 1] You can get a copy of the makefile with: > cp ~edatools/setups/hspice/makefile . [Note 2] Numerous output files are created, depending on commands in the .sp spice input file. [Note 3] This is the AvanWaves waveform viewer. You must have an X-window client running to see the output plots. More Unix Tips ============== The ECE department uses tcsh as the default shell. The best reference on tcsh is "Using csh & tcsh", Paul DuBois, O'Reilly, 1995. Appendix B is an excellent 16-page Quick Reference. Forced Over-write ----------------- If you are doing repeated edit-simulate cycles, you can skip the 'make clean' step by using >! to *force* an over-write of the output file. Alternatively, you can comment out the 'set noclobber' line in your .cshrc file. > hspice nmos1.sp >! nmos1.out Aliases ------- Use aliases everywhere to save typing. For the above command, define: macquigg@quad:~> alias hs 'hspice \!^.sp >! \!^.out' Now the command is just: > hs nmos1 TroubleShooting =============== Startup problems ---------------- If you see something like the following when you try to start HSpice, HSPICE errors -------------- Can't find the permit file for hspice (permit.hsp) in /usr2/meta, /usr/meta, /meta, /usr/local/lib, /usr/local/bin, /etc, or /home/ramv. you probably have some conflicts with other tools in your .cshrc file. Make sure you have a fresh copy of .cshrc, with nothing added but the hsp alias above. Start a fresh shell before you run HSpice, to make sure you haven't accumulated some garbage in your Unix or shell environment. The standard .cshrc for the ECE Department can be copied to your account with: cp /home/skel/skeletonfiles/.cshrc /home/USERNAME/ You can also get a copy with edatool aliases already added from: cp /home/edatools/.cshrc /home/USERNAME/