📄 swmask.c
字号:
/**********Copyright 1990 Regents of the University of California. All rights reserved.Author: 1987 Thomas L. Quarles**********//* *//* * This routine gives access to the internal model parameter * of voltage controlled SWitch */#include "spice.h"#include <stdio.h>#include "cktdefs.h"#include "devdefs.h"#include "ifsim.h"#include "swdefs.h"#include "sperror.h"#include "suffix.h"/* ARGSUSED */intSWmAsk(ckt,inModel,which,value) CKTcircuit *ckt; GENmodel *inModel; int which; IFvalue *value;{ SWmodel *model = (SWmodel *)inModel; switch(which) { case SW_MOD_RON: value->rValue = model->SWonResistance; return (OK); case SW_MOD_ROFF: value->rValue = model->SWoffResistance; return (OK); case SW_MOD_VTH: value->rValue = model->SWvThreshold; return (OK); case SW_MOD_VHYS: value->rValue = model->SWvHysteresis; return (OK); case SW_MOD_GON: value->rValue = model->SWonConduct; return (OK); case SW_MOD_GOFF: value->rValue = model->SWoffConduct; return (OK); default: return (E_BADPARM); } /* NOTREACHED */}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -