00001 /*************************************************************************** 00002 * Copyright (C) 2003 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 EC555_H 00012 #define EC555_H 00013 00014 #include "component.h" 00015 00016 #include <qstringlist.h> 00017 00022 class EC555 : public Component 00023 { 00024 public: 00025 EC555( ICNDocument *icnDocument, bool newItem, const char *id = 0 ); 00026 ~EC555(); 00027 00028 virtual bool canFlip() const { return true; } 00029 static Item* construct( ItemDocument *itemDocument, bool newItem, const char *id ); 00030 static LibraryItem *libraryItem(); 00031 00032 virtual void stepNonLogic(); 00033 virtual bool doesStepNonLogic() const { return true; } 00034 00035 private: 00036 Pin * ground; 00037 Pin * trigger; 00038 Pin * output; 00039 Pin * reset; 00040 Pin * control; 00041 Pin * threshold; 00042 Pin * discharge; 00043 Pin * vcc; 00044 00045 Resistance *m_r1; 00046 Resistance *m_r23; 00047 Resistance *m_po_sink; 00048 Resistance *m_po_source; 00049 Resistance *m_r_discharge; 00050 00051 bool old_com1; 00052 bool old_com2; 00053 bool old_q; 00054 }; 00055 00056 #endif
1.5.1