help-gnucap
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Help-gnucap] Re: using a pipe to make gnucap accept input from other pr


From: Hugo Coolens
Subject: [Help-gnucap] Re: using a pipe to make gnucap accept input from other program
Date: Wed, 10 Jan 2007 10:23:10 +0100
User-agent: Debian Thunderbird 1.0.2 (X11/20061113)

al davis wrote:
On Thursday 04 January 2007 04:35, Hugo Coolens wrote:

In particular .. What does it do, or claim to do?   What
does its output look like?  (maybe include it in your mail)
just how doesn't it work? etc...

makespicefile is just a little bash-script I wrote. It just
outputs a regular spice file. I just regret I  can't use it
with gnucap the way I use it with regular Spice using a pipe:

makespicefile | spice

works but

makespicefile | gnucap

does not work


As I said before, you need to give more information if you want us to help you. Gnucap is not Spice. It is not 100% compatible. Gnucap has some features Spice does not have,
Can you give me some examples of those features?
 and
Spice has some features gnucap does not have. You could have the same problem moving between versions of spice. Maybe you could post your script, some data, and what it does. In your mail, put it in line as plain text, not as an attachment. Attachments really mess up the digest and archives.
Here is the script (it produces cascaded normalized RC-sections)
Save it to a file called makespicefile, chmod 755 makespicefile and try ./makespicefile 2
then you see the inputfile for an rc-filter with two sections
if you execute ./makespicefile 2 |spice you'll see the result immediately. Gnucap however does not accept the standard unix way to handle pipes unfortunately. There I have to use files as in intermediate step:
./makespicefile 2 >input.cir
gnucap -b input.cir

when you start making real large circuits this is not elegant to do and a waste of time and resources. The script can be used to produce real large circuits to compare different spice-versions (accuracy, maximum number of nodes ...)


The script:

#! /bin/bash
#use: makespicefile number_of_sections
echo 'test'
echo 'vin 1 0 ac 1'
for ((i=1; i<$1+1 ; i++))
    do
      echo r$i $i $((i+1)) '1'
      echo c$i $((i+1)) 0  '1'
    done
echo '.print ac' 'v('$i')'
#print-statement _before_ analysis necessary for gnucap
echo '.options numdgt=7'
echo '.ac dec 20 10m 1000 basic'
echo '.end'





reply via email to

[Prev in Thread] Current Thread [Next in Thread]