1#include "../../eeschema/sim/kibis/kibis.h"
2#include <wx/textfile.h>
9 KIBIS* k4 =
new KIBIS(
"ibis_lan8670_1_2_1v3.ibs" );
13 std::cout <<
"Component: " << comp.
m_name << std::endl;
17 std::cout <<
"--Pin: " <<
pin.m_pinNumber <<
" " <<
pin.m_signalName << std::endl;
25 std::cout <<
"pin1 name: " << pin1->
m_signalName << std::endl;
26 std::cout <<
"pin2 name: " << pin2->
m_signalName << std::endl;
27 std::cout <<
"pin1 model length: " << pin1->
m_models.size()<< std::endl;
28 std::cout <<
"pin2 model length: " << pin2->
m_models.size()<< std::endl;
29 std::string* tmp1 =
new std::string();
30 std::string* tmp2 =
new std::string();
31 std::string* tmp3 =
new std::string();
32 std::string* tmp4 =
new std::string();
41 std::cout <<
"WAVEFORM TYPE IN QA: " << wave->
GetType() << std::endl;
42 std::cout << pin2->
m_models.at(0)->m_name << std::endl;
51 std::cout <<
"Model used for driver: " << model1->
m_name << std::endl;
54 wxTextFile file(
"output.sp" );
63 file.AddLine( *tmp1 );
64 file.AddLine( *tmp2 );
65 file.AddLine( *tmp3 );
66 file.AddLine( *tmp4 );
69 simul +=
"x1 0 OUT_1 OUT_2 driver_typ \n";
70 simul +=
"R1 OUT_1 COM 25\n";
71 simul +=
"R2 OUT_2 COM 25\n";
72 simul +=
"V1 COM 0 1.25\n";
73 simul +=
".tran 0.1n 1000n \n";
74 simul +=
".control run \n";
76 simul +=
"plot v(OUT_1) v(OUT_2)\n";
82 file.AddLine( simul );
87 std::cout <<
"Done" << std::endl;
std::vector< KIBIS_PIN > m_pins
std::string m_name
Name of the component.
KIBIS_PIN * GetPin(const std::string &aPinNumber)
Get a pin by its number ( 1, 2, A1, A2, ... )
KIBIS_WAVEFORM * m_waveform
bool writeSpiceDiffDriver(std::string &aDest, const std::string &aName, KIBIS_MODEL &aModel, const KIBIS_PARAMETER &aParam)
bool writeSpiceDevice(std::string &aDest, const std::string &aName, KIBIS_MODEL &aModel, const KIBIS_PARAMETER &aParam)
std::vector< KIBIS_MODEL * > m_models
std::string m_signalName
Name of the pin Examples : "VCC", "GPIOA", "CLK", etc...
std::vector< KIBIS_COMPONENT > m_components