KiCad PCB EDA Suite
Loading...
Searching...
No Matches
ibis_parser.h
Go to the documentation of this file.
1/*
2 * This program source code file is part of KiCad, a free EDA CAD application.
3 *
4 * Copyright (C) 2022 Fabien Corona f.corona<at>laposte.net
5 * Copyright The KiCad Developers, see AUTHORS.txt for contributors.
6 *
7 * Redistribution and use in source and binary forms, with or without modification,
8 * are permitted provided that the following conditions are met:
9 *
10 * 1. Redistributions of source code must retain the above copyright notice,
11 * this list of conditions and the following disclaimer.
12 *
13 * 2. Redistributions in binary form must reproduce the above copyright notice,
14 * this list of conditions and the following disclaimer in the documentation
15 * and/or other materials provided with the distribution.
16 *
17 * 3. Neither the name of the copyright holder nor the names of its contributors may be used
18 * to endorse or promote products derived from this software without specific
19 * prior written permission.
20 *
21 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS
22 * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
23 * AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
24 * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
26 * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
28 * OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
29 * POSSIBILITY OF SUCH DAMAGE.
30 */
31
32
33#ifndef IBIS_PARSER_H
34#define IBIS_PARSER_H
35
36#define NAN_NA "1"
37#define NAN_INVALID "0"
38
39#define IBIS_MAX_VERSION 7.0 // Up to v7.0, IBIS is fully backward compatible
40#define IBIS_MAX_LINE_LENGTH 2048 // official limit is 1024
41
42#include <wx/string.h>
43#include <reporter.h>
45#include <iostream>
46#include <fstream>
47#include <vector>
48#include <map>
49#include <math.h>
50#include <cstring>
51
52
54{
55public:
56 IBIS_BASE( REPORTER* aReporter )
57 {
58 m_Reporter = aReporter;
59 };
60
68 void Report( const std::string& aMsg, SEVERITY aSeverity = RPT_SEVERITY_INFO ) const
69 {
70 if( m_Reporter )
71 m_Reporter->Report( aMsg, aSeverity );
72 };
73
74public:
76
77protected:
83 static std::string doubleToString( double aNumber );
84};
85
86
87class IBIS_INPUT : public IBIS_BASE
88{
89public:
90 IBIS_INPUT( REPORTER* aReporter ) :
91 IBIS_BASE( aReporter )
92 {};
93
98 bool virtual Check() { return false; };
99};
100
101
103{
104 TYP = 0,
107};
108
109
111{
112 // All matrices are supposed to be symmetrical, only upper right triangle is given
114 BANDED, // Give the main diagonal + [bandwidth] elements on the right
115 SPARSE, // Only give non-zero values.
116 FULL, // Give the whole upper triangle.
117};
118
119
121{
122public:
123 IBIS_MATRIX( REPORTER* aReporter ) :
124 IBIS_INPUT( aReporter )
125 {};
126
127 virtual ~IBIS_MATRIX(){};
128
130 int m_rows = -1;
131 int m_cols = -1;
132 std::vector<double> m_data;
133
134 bool Check() override;
135};
136
137
139{
140public:
141 IBIS_SECTION( REPORTER* aReporter ) :
142 IBIS_INPUT( aReporter )
143 {};
144};
145
146
148{
149public:
150 IbisHeader( REPORTER* aReporter ) :
151 IBIS_SECTION( aReporter )
152 {};
153
154 double m_ibisVersion = -1;
155 double m_fileRevision = -1;
156 std::string m_fileName;
157 std::string m_source;
158 std::string m_date;
159 std::string m_notes;
160 std::string m_disclaimer;
161 std::string m_copyright;
162
163 bool Check() override;
164};
165
166
168{
169public:
170 TypMinMaxValue( REPORTER* aReporter ) :
171 IBIS_INPUT( aReporter )
172 {};
173
174 double value[3] = { nan( NAN_NA ), nan( NAN_NA ), nan( NAN_NA ) };
175
176 bool isNA() const;
177
178 bool Check() override;
179
180 void Add( const TypMinMaxValue& aValue );
181};
182
183
185{
186public:
188 IBIS_INPUT( aReporter ),
189 m_Rpkg( aReporter ),
190 m_Lpkg( aReporter ),
191 m_Cpkg( aReporter )
192 {};
193
197
198 bool Check() override;
199};
200
201
203{
204public:
206 IBIS_INPUT( aReporter )
207 {};
208
210 {};
211
212 std::string m_pinName;
213 std::string m_signalName;
214 std::string m_modelName;
215 double m_Rpin = nan( NAN_NA );
216 double m_Lpin = nan( NAN_NA );
217 double m_Cpin = nan( NAN_NA );
218
219 int m_Rcol = 0;
220 int m_Lcol = 0;
221 int m_Ccol = 0;
222
223 bool Check() override;
224
225 bool m_dummy = false;
226};
227
228
230{
231public:
233 IBIS_INPUT( aReporter )
234 {};
235
237 {};
238
239 std::string m_pinName;
240 std::string m_PDref;
241 std::string m_PUref;
242 std::string m_GNDClampRef;
243 std::string m_POWERClampRef;
244 std::string m_extRef;
245};
246
247
249{
250public:
252 IBIS_INPUT( aReporter ),
253 tdelay( aReporter )
254 {};
255
257 {};
258
259 std::string pinA;
260 std::string pinB;
261 double Vdiff = 0.2; // ignored for input
262 TypMinMaxValue tdelay = 0; // ignored for outputs
263};
264
265
267{
268public:
269 IbisDiffPin( REPORTER* aReporter ) :
270 IBIS_INPUT( aReporter )
271 {};
272
273 std::vector<IbisDiffPinEntry> m_entries;
274};
275
277{
278public:
279 IbisComponent( REPORTER* aReporter ) :
280 IBIS_INPUT( aReporter ),
281 m_package( aReporter ),
282 m_diffPin( aReporter )
283 {};
284
286 {};
287
288 std::string m_name = "";
289 std::string m_manufacturer = "";
291 std::vector<IbisComponentPin> m_pins;
292 std::vector<IbisComponentPinMapping> m_pinMappings;
293 std::string m_packageModel;
294 std::string m_busLabel;
295 std::string m_dieSupplyPads;
297
298 bool Check() override;
299};
300
301
303{
304public:
305 std::string m_modelName;
307};
308
309
311{
312public:
314 IBIS_INPUT( aReporter )
315 {};
316
318 {};
319
320 std::string m_name;
321 std::vector<IbisModelSelectorEntry> m_models;
322
323 bool Check() override;
324};
325
326
328{
329public:
330 IVtableEntry( REPORTER* aReporter ) :
331 IBIS_INPUT( aReporter ),
332 I( aReporter )
333 {};
334
336 {};
337
338 double V = 0;
340};
341
342
343class IVtable : public IBIS_INPUT
344{
345public:
346 IVtable( REPORTER* aReporter ) :
347 IBIS_INPUT( aReporter )
348 {};
349
350 std::vector<IVtableEntry> m_entries;
351
352 bool Check() override;
353
362 double InterpolatedI( double aV, IBIS_CORNER aCorner ) const;
363
377 std::string Spice( int aN, const std::string& aPort1, const std::string& aPort2, bool aNegateI,
378 const std::string& aModelName, IBIS_CORNER aCorner ) const;
379
380private:
381};
382
384{
385public:
386 VTtableEntry( REPORTER* aReporter ) :
387 IBIS_INPUT( aReporter ),
388 V( aReporter )
389 {};
390
392 {};
393
394 double t = 0;
396};
397
398
399class VTtable : public IBIS_INPUT
400{
401public:
402 VTtable( REPORTER* aReporter ) :
403 IBIS_INPUT( aReporter )
404 {};
405
406 std::vector<VTtableEntry> m_entries;
407};
408
409/*
410Model_type must be one of the following:
411Input, Output, I/O, 3-state, Open_drain, I/O_open_drain, Open_sink, I/O_open_sink,
412Open_source, I/O_open_source, Input_ECL, Output_ECL, I/O_ECL, 3-state_ECL, Terminator,
413Series, and Series_switch.
414*/
415
437
444
445
446class dvdt
447{
448public:
449 double m_dv = 1;
450 double m_dt = 1;
451};
452
453
455{
456public:
457 dvdtTypMinMax( REPORTER* aReporter ) : IBIS_INPUT( aReporter ){};
459
460 bool Check() override;
461};
462
463
464class IbisRamp : public IBIS_INPUT
465{
466public:
467 IbisRamp( REPORTER* aReporter ) :
468 IBIS_INPUT( aReporter ),
469 m_falling( aReporter ),
470 m_rising( aReporter )
471 {};
472
475 double m_Rload = 50; // The R_load subparameter is optional if the default 50 ohm load is used
476
477 bool Check() override;
478};
479
480
486
487
489{
490public:
491 IbisWaveform( REPORTER* aReporter ) :
492 IBIS_INPUT( aReporter ),
493 m_table( aReporter )
494 {};
495
498 double m_R_dut = 0;
499 double m_C_dut = 0;
500 double m_L_dut = 0;
501 double m_R_fixture = 0;
502 double m_C_fixture = 0;
503 double m_L_fixture = 0;
504 double m_V_fixture = 0;
505 double m_V_fixture_min = 0;
506 double m_V_fixture_max = 0;
507};
508
509
516
517
524
525
527{
528public:
530 m_name( name ),
531 m_mode( mode )
532 {};
533
534 std::string m_name;
536};
537
538
540{
541public:
542 IbisModel( REPORTER* aReporter ) :
543 IBIS_INPUT( aReporter ),
544 m_C_comp( aReporter ),
545 m_C_comp_gnd_clamp( aReporter ),
546 m_C_comp_power_clamp( aReporter ),
547 m_C_comp_pullup( aReporter ),
548 m_C_comp_pulldown( aReporter ),
549 m_voltageRange( aReporter ),
550 m_temperatureRange( aReporter ),
551 m_pullupReference( aReporter ),
552 m_pulldownReference( aReporter ),
553 m_GNDClampReference( aReporter ),
554 m_POWERClampReference( aReporter ),
555 m_Rgnd( aReporter ),
556 m_Rpower( aReporter ),
557 m_Rac( aReporter ),
558 m_Cac( aReporter ),
559 m_GNDClamp( aReporter ),
560 m_POWERClamp( aReporter ),
561 m_pullup( aReporter ),
562 m_pulldown( aReporter ),
563 m_ISSO_PU( aReporter ),
564 m_ISSO_PD( aReporter ),
565 m_compositeCurrent( aReporter ),
566 m_ramp( aReporter )
567 {};
568
569 virtual ~IbisModel()
570 {};
571
572 std::string m_name;
574 /* The Polarity, Enable, Vinl, Vinh, Vmeas, Cref, Rref, and Vref subparameters are optional. */
575 /* the default values of Vinl = 0.8 V and Vinh = 2.0 V are assumed. */
576 double m_vinl = 0.8;
577 double m_vinh = 2;
578 double m_vref = 0;
579 double m_rref = 0;
580 double m_cref = 0;
581 double m_vmeas = 0;
584 // End of optional subparameters
585
608 std::vector<IbisWaveform*> m_risingWaveforms;
609 std::vector<IbisWaveform*> m_fallingWaveforms;
611
612 std::vector<IbisSubmodelMode> m_submodels;
613
614 bool Check() override;
615};
616
617
625
626
628{
629public:
630 IbisSubmodel( REPORTER* aReporter ) :
631 IBIS_INPUT( aReporter ),
632 m_VtriggerR( aReporter ),
633 m_VtriggerF( aReporter ),
634 m_offDelay( aReporter ),
635 m_pullup( aReporter ),
636 m_pulldown( aReporter ),
637 m_GNDClamp( aReporter ),
638 m_POWERClamp( aReporter ),
639 m_GNDPulse( aReporter ),
640 m_POWERPulse( aReporter ),
641 m_ramp( aReporter )
642 {};
643
645 {};
646
647 std::string m_name;
659 std::vector<IbisWaveform*> m_risingWaveforms;
660 std::vector<IbisWaveform*> m_fallingWaveforms;
661
662 bool Check() override;
663};
664
665
667{
668public:
670 IBIS_INPUT( aReporter )
671 {};
672
674 {};
675
676 std::string m_name;
677 std::string m_manufacturer;
678 std::string m_OEM;
679 std::string m_description;
681 std::map<std::string, int> m_pins;
682
683 std::shared_ptr<IBIS_MATRIX> m_resistanceMatrix;
684 std::shared_ptr<IBIS_MATRIX> m_capacitanceMatrix;
685 std::shared_ptr<IBIS_MATRIX> m_inductanceMatrix;
686
687 bool Check() override;
688};
689
690
691class IbisFile : public IBIS_INPUT
692{
693public:
694 IbisFile( REPORTER* aReporter ) :
695 IBIS_INPUT( aReporter ),
696 m_header( aReporter )
697 {};
698
699 virtual ~IbisFile()
700 {};
701
703 std::vector<IbisComponent> m_components;
704 std::vector<IbisModelSelector> m_modelSelectors;
705 std::vector<IbisModel> m_models;
706 std::vector<IbisPackageModel> m_packageModels;
707 std::map<std::string, IbisSubmodel> m_submodels;
708};
709
710
735
748
749
750class IbisParser : public IBIS_INPUT
751{
752public:
753 IbisParser( REPORTER* aReporter ) :
754 IBIS_INPUT( aReporter ),
755 m_ibisFile( aReporter )
756 {};
757
758 bool m_parrot = true; // Write back all lines.
759
761 char m_commentChar = '|';
762 std::vector<char> m_buffer;
765 int m_lineIndex = 0;
767
774 std::shared_ptr<IBIS_MATRIX> m_currentMatrix = nullptr;
780
788 bool ParseFile( const std::string& aFileName );
789
790private:
791 std::string* m_continuingString = nullptr;
792
801 bool compareIbisWord( const std::string& a, const std::string& b );
802
808 bool parseHeader( std::string& aKeyword );
809
815 bool parseComponent( std::string& aKeyword );
816
822 bool parseModelSelector( std::string& aKeyword );
823
829 bool parseModel( std::string& aKeyword );
830
836 bool parseSubmodel( std::string& aKeyword );
837
843 bool parsePackageModel( std::string& aKeyword );
844
850 bool parsePackageModelModelData( std::string& aKeyword );
851
857 bool parseAlgorithmicModel( std::string& aKeyword );
858
866 bool parseDouble( double& aDest, std::string& aStr, bool aAllowModifiers = false );
867
874 bool parseDvdt( dvdt& aDest, std::string& aStr );
875
880 bool onNewLine(); // Gets rid of comments ( except on a comment character change command...)
881
886 bool getNextLine();
887
889 void printLine();
890
891 void skipWhitespaces();
892 bool checkEndofLine(); // To be used when there cannot be any character left on the line
894 std::string getKeyword();
895
896 bool readInt( int& aDest );
897 bool readDouble( double& aDest );
898 bool readWord( std::string& aDest );
899 bool readDvdt( dvdt& aDest );
900 bool readMatrixPinIndex( int& aDest );
901 bool readMatrixType( std::shared_ptr<IBIS_MATRIX>& aDest );
902 bool readMatrixBandwidth();
903 bool readMatrixRow();
905 bool readMatrixSparse();
906 bool readMatrixData();
907 bool readRampdvdt( dvdtTypMinMax& aDest );
908 bool readRamp();
909 bool readModelSpec();
910 bool readSubmodelSpec();
913 bool readAddSubmodel();
914 bool readWaveform( IbisWaveform* aDest, IBIS_WAVEFORM_TYPE aType );
915 bool readString( std::string& aDest );
916 bool storeString( std::string& aDest, bool aMultiline );
917 bool readTableLine( std::vector<std::string>& aDest );
918
919 bool readNumericSubparam( const std::string& aSubparam, double& aDest );
920 bool readIVtableEntry( IVtable& aTable );
921 bool readVTtableEntry( VTtable& aTable );
922 bool readTypMinMaxValue( TypMinMaxValue& aDest );
923 bool readTypMinMaxValueSubparam( const std::string& aSubparam, TypMinMaxValue& aDest );
924 //bool ReadDieSupplyPads();
925
926 bool readPackage();
927 bool readPin();
928 bool readPinMapping();
929 bool readDiffPin();
930 bool readModelSelector();
931 bool readModel();
932 bool readSubmodel();
934
936 bool changeCommentChar();
937 bool changeContext( std::string& aKeyword );
938
941};
942
943#endif
const char * name
Store all of the related component information found in a netlist.
void Report(const std::string &aMsg, SEVERITY aSeverity=RPT_SEVERITY_INFO) const
Print a message.
Definition ibis_parser.h:68
IBIS_BASE(REPORTER *aReporter)
Definition ibis_parser.h:56
REPORTER * m_Reporter
Definition ibis_parser.h:75
static std::string doubleToString(double aNumber)
Convert a double to string using scientific notation.
virtual bool Check()
Check if the data held by the object is valid.
Definition ibis_parser.h:98
IBIS_INPUT(REPORTER *aReporter)
Definition ibis_parser.h:90
IBIS_MATRIX_TYPE m_type
std::vector< double > m_data
IBIS_MATRIX(REPORTER *aReporter)
bool Check() override
Check if the data held by the object is valid.
virtual ~IBIS_MATRIX()
IBIS_SECTION(REPORTER *aReporter)
IVtableEntry(REPORTER *aReporter)
TypMinMaxValue I
virtual ~IVtableEntry()
bool Check() override
Check if the data held by the object is valid.
double InterpolatedI(double aV, IBIS_CORNER aCorner) const
Interpolate the IV table.
std::string Spice(int aN, const std::string &aPort1, const std::string &aPort2, bool aNegateI, const std::string &aModelName, IBIS_CORNER aCorner) const
Interpolate the IV table.
std::vector< IVtableEntry > m_entries
IVtable(REPORTER *aReporter)
bool Check() override
Check if the data held by the object is valid.
TypMinMaxValue m_Cpkg
TypMinMaxValue m_Lpkg
IbisComponentPackage(REPORTER *aReporter)
TypMinMaxValue m_Rpkg
IbisComponentPinMapping(REPORTER *aReporter)
virtual ~IbisComponentPinMapping()
std::string m_POWERClampRef
bool Check() override
Check if the data held by the object is valid.
virtual ~IbisComponentPin()
std::string m_signalName
std::string m_pinName
std::string m_modelName
IbisComponentPin(REPORTER *aReporter)
std::string m_manufacturer
std::string m_packageModel
std::vector< IbisComponentPinMapping > m_pinMappings
IbisComponentPackage m_package
std::string m_busLabel
std::string m_dieSupplyPads
bool Check() override
Check if the data held by the object is valid.
IbisDiffPin m_diffPin
virtual ~IbisComponent()
IbisComponent(REPORTER *aReporter)
std::string m_name
std::vector< IbisComponentPin > m_pins
IbisDiffPinEntry(REPORTER *aReporter)
std::string pinB
virtual ~IbisDiffPinEntry()
TypMinMaxValue tdelay
std::string pinA
IbisDiffPin(REPORTER *aReporter)
std::vector< IbisDiffPinEntry > m_entries
virtual ~IbisFile()
std::vector< IbisComponent > m_components
IbisHeader m_header
std::map< std::string, IbisSubmodel > m_submodels
std::vector< IbisPackageModel > m_packageModels
std::vector< IbisModel > m_models
IbisFile(REPORTER *aReporter)
std::vector< IbisModelSelector > m_modelSelectors
bool Check() override
Check if the data held by the object is valid.
std::string m_fileName
std::string m_copyright
std::string m_notes
double m_ibisVersion
IbisHeader(REPORTER *aReporter)
std::string m_date
std::string m_source
double m_fileRevision
std::string m_disclaimer
std::string m_modelDescription
virtual ~IbisModelSelector()
bool Check() override
Check if the data held by the object is valid.
std::string m_name
std::vector< IbisModelSelectorEntry > m_models
IbisModelSelector(REPORTER *aReporter)
TypMinMaxValue m_C_comp_pullup
virtual ~IbisModel()
TypMinMaxValue m_C_comp_power_clamp
IBIS_MODEL_TYPE m_type
double m_cref
IVtable m_pullup
TypMinMaxValue m_Cac
IVtable m_ISSO_PU
TypMinMaxValue m_pullupReference
TypMinMaxValue m_C_comp_pulldown
TypMinMaxValue m_C_comp_gnd_clamp
double m_vmeas
IVtable m_pulldown
bool Check() override
Check if the data held by the object is valid.
TypMinMaxValue m_Rac
std::vector< IbisSubmodelMode > m_submodels
std::vector< IbisWaveform * > m_risingWaveforms
IVtable m_POWERClamp
TypMinMaxValue m_Rgnd
TypMinMaxValue m_POWERClampReference
IbisModel(REPORTER *aReporter)
IVtable m_GNDClamp
IbisRamp m_ramp
IVtable m_ISSO_PD
IVtable m_compositeCurrent
IBIS_MODEL_POLARITY m_polarity
TypMinMaxValue m_C_comp
double m_rref
IBIS_MODEL_ENABLE m_enable
TypMinMaxValue m_temperatureRange
std::vector< IbisWaveform * > m_fallingWaveforms
TypMinMaxValue m_pulldownReference
double m_vref
TypMinMaxValue m_GNDClampReference
double m_vinh
double m_vinl
TypMinMaxValue m_voltageRange
TypMinMaxValue m_Rpower
std::string m_name
std::map< std::string, int > m_pins
std::shared_ptr< IBIS_MATRIX > m_resistanceMatrix
IbisPackageModel(REPORTER *aReporter)
std::string m_OEM
std::shared_ptr< IBIS_MATRIX > m_inductanceMatrix
virtual ~IbisPackageModel()
bool Check() override
Check if the data held by the object is valid.
std::string m_description
std::string m_name
std::shared_ptr< IBIS_MATRIX > m_capacitanceMatrix
std::string m_manufacturer
bool parseSubmodel(std::string &aKeyword)
Parse a single keyword in the submodel context.
std::vector< char > m_buffer
char m_commentChar
long m_lineCounter
bool readAlgorithmicModel()
bool readMatrixBandedOrFull()
IBIS_PARSER_CONTINUE m_continue
bool readSubmodelSpec()
bool readModelSpec()
bool changeCommentChar()
Ibis can change the character used for comments.
bool getNextLine()
Load the next line.
bool parseComponent(std::string &aKeyword)
Parse a single keyword in the component context.
bool parseModel(std::string &aKeyword)
Parse a single keyword in the model context.
VTtable * m_currentVTtable
bool readMatrixBandwidth()
bool readMatrixRow()
bool parsePackageModelModelData(std::string &aKeyword)
Parse a single keyword in the package model model data context.
bool isLineEmptyFromCursor()
void printLine()
Print the current line.
bool readModelSelector()
bool changeContext(std::string &aKeyword)
std::string getKeyword()
int m_currentMatrixCol
bool parseDouble(double &aDest, std::string &aStr, bool aAllowModifiers=false)
Parse a double according to the ibis standard.
bool onNewLine()
Parse the current line.
bool readWord(std::string &aDest)
bool readTypMinMaxValue(TypMinMaxValue &aDest)
bool compareIbisWord(const std::string &a, const std::string &b)
compare two strings without being case sensitive
bool readDvdt(dvdt &aDest)
int m_currentMatrixRow
IbisComponent * m_currentComponent
std::shared_ptr< IBIS_MATRIX > m_currentMatrix
IbisSubmodel * m_currentSubmodel
bool readMatrixSparse()
bool ParseFile(const std::string &aFileName)
Parse a file.
bool readMatrixType(std::shared_ptr< IBIS_MATRIX > &aDest)
std::string * m_continuingString
IbisModel * m_currentModel
IbisParser(REPORTER *aReporter)
bool parseDvdt(dvdt &aDest, std::string &aStr)
Parse a dV/dt value according to the ibis standard.
IbisPackageModel * m_currentPackageModel
bool readDouble(double &aDest)
bool readSubmodel()
IbisModelSelector * m_currentModelSelector
bool checkEndofLine()
bool parsePackageModel(std::string &aKeyword)
Parse a single keyword in the package model context.
bool readString(std::string &aDest)
bool readPinMapping()
bool readTypMinMaxValueSubparam(const std::string &aSubparam, TypMinMaxValue &aDest)
bool parseAlgorithmicModel(std::string &aKeyword)
Parse a single keyword in the algorithmic model context.
bool readNumericSubparam(const std::string &aSubparam, double &aDest)
bool readMatrixPinIndex(int &aDest)
bool readInt(int &aDest)
bool readPackage()
int m_bufferIndex
IBIS_PARSER_CONTEXT m_context
IbisFile m_ibisFile
IVtable * m_currentIVtable
bool readIVtableEntry(IVtable &aTable)
bool readVTtableEntry(VTtable &aTable)
bool parseModelSelector(std::string &aKeyword)
Parse a single keyword in the model selector context.
bool readDiffPin()
bool readReceiverThresholds()
bool readAddSubmodel()
void skipWhitespaces()
bool storeString(std::string &aDest, bool aMultiline)
bool readPackageModelPins()
bool readRampdvdt(dvdtTypMinMax &aDest)
bool readTableLine(std::vector< std::string > &aDest)
bool readMatrixData()
bool parseHeader(std::string &aKeyword)
Parse a single keyword in the header context.
bool readWaveform(IbisWaveform *aDest, IBIS_WAVEFORM_TYPE aType)
IbisWaveform * m_currentWaveform
dvdtTypMinMax m_rising
IbisRamp(REPORTER *aReporter)
bool Check() override
Check if the data held by the object is valid.
double m_Rload
dvdtTypMinMax m_falling
IBIS_SUBMODEL_MODE m_mode
IbisSubmodelMode(std::string name, IBIS_SUBMODEL_MODE mode)
std::string m_name
IVtable m_POWERPulse
IVtable m_pulldown
std::vector< IbisWaveform * > m_fallingWaveforms
TypMinMaxValue m_VtriggerR
IVtable m_POWERClamp
std::vector< IbisWaveform * > m_risingWaveforms
bool Check() override
Check if the data held by the object is valid.
IbisSubmodel(REPORTER *aReporter)
IBIS_SUBMODEL_TYPE m_type
IVtable m_GNDClamp
IVtable m_GNDPulse
std::string m_name
virtual ~IbisSubmodel()
IVtable m_pullup
TypMinMaxValue m_offDelay
IbisRamp m_ramp
TypMinMaxValue m_VtriggerF
double m_L_fixture
double m_V_fixture
VTtable m_table
double m_V_fixture_min
IBIS_WAVEFORM_TYPE m_type
double m_V_fixture_max
double m_R_fixture
IbisWaveform(REPORTER *aReporter)
double m_C_fixture
A pure virtual class used to derive REPORTER objects from.
Definition reporter.h:73
TypMinMaxValue(REPORTER *aReporter)
bool Check() override
Check if the data held by the object is valid.
double value[3]
bool isNA() const
void Add(const TypMinMaxValue &aValue)
virtual ~VTtableEntry()
TypMinMaxValue V
VTtableEntry(REPORTER *aReporter)
VTtable(REPORTER *aReporter)
std::vector< VTtableEntry > m_entries
bool Check() override
Check if the data held by the object is valid.
dvdtTypMinMax(REPORTER *aReporter)
double m_dv
double m_dt
@ NONE
Definition eda_shape.h:69
IBIS_SUBMODEL_TYPE
IBIS_MODEL_TYPE
IBIS_MODEL_POLARITY
#define NAN_NA
Definition ibis_parser.h:36
IBIS_PARSER_CONTEXT
IBIS_MATRIX_TYPE
IBIS_CORNER
@ TYP
@ MIN
@ MAX
IBIS_PARSER_CONTINUE
IBIS_SUBMODEL_MODE
IBIS_WAVEFORM_TYPE
IBIS_MODEL_ENABLE
SEVERITY
@ RPT_SEVERITY_INFO