Menu

#41 pipe mode?

v1.0 (example)
open
nobody
None
5
2019-07-21
2019-07-19
Samir Sabri
No

Hello

I am very new to ngSpice, I tried to refer to the manual, but I did not find an example of using ngspice in pipe mode, can some one please show a simple example here for a minimal circuit?

Related

Support Requests: #41

Discussion

  • Holger Vogt

    Holger Vogt - 2019-07-21

    In the pipe mode option (-p) ngspice reads from an input pipe. The input file sent via the pipe may contain any of the commands described in chapt. 17.5 of the manual. Ngspice executes the commands immediately and then exits. A simple example is given below. The program cat writes to the pipe, ngspice reads it.

    The command file is:

    *pipe-circuit.cir
    source circuit.cir
    tran 10u 2m
    write pcir.raw all
    

    The test circuit is

    * Circuit.cir
    V1 n0 0 SIN(0 10 1kHz)
    C1 n1 n0 3.3nF
    R1 0 n1 1k
    .end
    

    The command for starting ngspice is:

    $ cat pipe-circuit.cir | ngspice -p
    
     

    Last edit: Holger Vogt 2019-07-22
    • Samir Sabri

      Samir Sabri - 2019-07-22

      Thanks Holger, that’s exactly what I was looking for.

      On Sun, Jul 21, 2019 at 1:42 PM Holger Vogt h_vogt@users.sourceforge.net
      wrote:

      In the pipe mode option (-p) ngspice reads from an input pie. The input
      file may contain any of the commands described in chapt. 17.5 of the
      manual. It executes the commands immediately and then exits. A simple
      example is given below. The prgram cat writes to the pipe, ngspice reads it.

      The command file is:

      *pipe-circuit.cir
      source circuit.cir
      tran 10u 2m
      write pcir.raw all

      The test circuit is

      • Circuit.cir
        V1 n0 0 SIN(0 10 1kHz)
        C1 n1 n0 3.3nF
        R1 0 n1 1k
        .end

      The command for starting ngspice is:

      $ cat pipe-circuit.cir | ngspice -p


      Status: open
      Group: v1.0 (example)
      Created: Fri Jul 19, 2019 12:25 PM UTC by Samir Sabri
      Last Updated: Fri Jul 19, 2019 12:25 PM UTC
      Owner: nobody

      Hello

      I am very new to ngSpice, I tried to refer to the manual, but I did not
      find an example of using ngspice in pipe mode, can some one please show a
      simple example here for a minimal circuit?


      Sent from sourceforge.net because you indicated interest in
      https://sourceforge.net/p/ngspice/support-requests/41/

      To unsubscribe from further messages, please visit
      https://sourceforge.net/auth/subscriptions/

      --

      Kind Regards,

      Samir Sabri
      Software Architect& Developer
      www.dcaclab.com
      Jordan-Middle East

       

      Related

      Support Requests: #41


Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.