cktnames.c

来自「支持数字元件仿真的SPICE插件」· C语言 代码 · 共 42 行

C
42
字号
/* * Copyright (c) 1988 Thomas L. Quarles */    /*     *CKTnames(ckt)     *  output information on all circuit nodes/equations     *     */#include "prefix.h"#include <stdio.h>#include "CKTdefs.h"#include "IFsim.h"#ifndef CMS#include "IFerrmsgs.h"#else  /* CMS */#include "IFerrmsg.h"#endif /* CMS */#include "util.h"#include "suffix.h"RCSID("CKTnames.c $Revision: 1.1 $ on $Date: 91/04/02 12:07:53 $")intCKTnames(ckt,numNames,nameList)    register CKTcircuit *ckt;    int *numNames;    register IFuid **nameList;{    register CKTnode *here;    register int i;    *numNames = ckt->CKTmaxEqNum-1;    *nameList = (IFuid *)MALLOC(*numNames * sizeof(IFuid ));    if ((*nameList) == (IFuid *)NULL) return(E_NOMEM);    i=0;    for (here = ckt->CKTnodes->next; here; here = here->next)  {        *((*nameList)+i++) = here->name;    }    return(OK);}

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?