00001 /*************************************************************************** 00002 * Copyright (C) 2005 by David Saxton * 00003 * david@bluehaze.org * 00004 * * 00005 * This program is free software; you can redistribute it and/or modify * 00006 * it under the terms of the GNU General Public License as published by * 00007 * the Free Software Foundation; either version 2 of the License, or * 00008 * (at your option) any later version. * 00009 ***************************************************************************/ 00010 00011 #ifndef PICCOMPONENTPIN_H 00012 #define PICCOMPONENTPIN_H 00013 00014 #include "config.h" 00015 #ifndef NO_GPSIM 00016 00017 #include "logic.h" 00018 #include "gpsim/stimuli.h" 00019 00020 #include <qstring.h> 00021 00026 class PICComponentPin : public CallbackClass, public stimulus 00027 { 00028 public: 00029 PICComponentPin( PICComponent * picComponent, PicPin picPin ); 00030 ~PICComponentPin(); 00034 void attach( IOPIN * iopin ); 00040 virtual void set_nodeVoltage( double v ); 00044 void logicCallback( bool state ); 00049 void resetOutput(); 00050 00051 virtual double get_Vth(); 00052 00053 protected: 00054 // Conductance of pin in different configurations 00055 double m_gOutHigh; 00056 double m_gOutLow; 00057 00058 PicPin m_picPin; 00059 IOPIN * m_pIOPIN; 00060 LogicOut * m_pLogicOut; 00061 LogicIn * m_pLogicIn; 00062 PICComponent * m_pPICComponent; 00063 Stimulus_Node * m_pStimulusNode; 00064 const QString m_id; 00065 }; 00066 00067 #endif 00068 #endif
1.5.1