Continue to Site

Welcome to EDAboard.com

Welcome to our site! EDAboard.com is an international Electronics Discussion Forum focused on EDA software, circuits, schematics, books, theory, papers, asic, pld, 8051, DSP, Network, RF, Analog Design, PCB, Service Manuals... and a whole lot more! To participate you need to register. Registration is free. Click here to register now.

name puzzling in a SPICE code snippet

Status
Not open for further replies.

ruwan2

Member level 5
Member level 5
Joined
Nov 29, 2011
Messages
90
Helped
0
Reputation
0
Reaction score
0
Trophy points
1,286
Visit site
Activity points
2,141
Hi,

I am new to SPICE. I do not understand the last comment part (inside /* and */). Can you get its conclusion:

XRC1 will contain a 100K resistor named R2_XRC1, connected between nets B and XRC1_Z

and

XRC2 will contain a 10P capacitor named C3_XRC1, connected between nets B and A !


I also do not see R2_XRC1 besides in the comment. It is an inferenced name: XRC1 part, R2 connect to its pin?


Thanks,





.SUBCKT RCNET X Y \ RVAL CVAL WN INST NODE VALUE
R1 X Y RVAL
INST Y NODE VALUE
C1 Y 0 CVAL
C2 Z 0 CVAL
M1 X Y Z 0 MOSN W= WN L=2U
.ENDS RCNET
/* subcircuit RCNET has two pins, X and Y, and six parameters, RVAL, CVAL, WN, NODE and VALUE. RVAL, CVAL, WN and VALUE will receive numeric values at call time, but INST will be an instance name, and NODE a node name...
*/
// in circuit.nsx:
XRC1 A B \ 100K 10P 15U R2 Z 100K RCNET
XRC2 B C \ 125K 9.7P 27U C3 X 10P RCNET
/* XRC1 will contain a 100K resistor named R2_XRC1, connected between nets B and XRC1_Z, while XRC2 will contain a 10P capacitor named C3_XRC1, connected between nets B and A !
*/
 

XRC1 will contain a 100K resistor named R2_XRC1, connected between nets B and XRC1_Z

and

XRC2 will contain a 10P capacitor named C3_XRC1, connected between nets B and A

Instead of the above, I think the comment should say:

XRC1 will contain a 100k resistor named R2_XRC1, connected between nets XRC1_Y and XRC1_Z

and

XRC2 will contain a 10p capacitor named C3_XRC2, connected between nets B = XRC2_Y and C = XRC2_X
 
  • Like
Reactions: ruwan2

    ruwan2

    Points: 2
    Helpful Answer Positive Rating
Status
Not open for further replies.

Part and Inventory Search

Welcome to EDABoard.com

Sponsor

Back
Top