LTSpice_RawRead module¶
Classes:
|
This class is used to represent the horizontal axis like on a Transient or DC Sweep Simulation. |
|
Class for storing Traces. |
|
Dummy Trace for bypassing traces while reading |
|
Class for reading LTSpice wave Files. |
|
Class used for storing operation points. |
This section is for testing your code |
|
|
Class used for storing generic traces that report to a given Axis. |
Exceptions:
Custom class for exception handling |
- class LTSpice_RawRead.Axis(name, datatype, datalen, numerical_type='real')[source]¶
Bases:
LTSpice_RawRead.DataSetThis class is used to represent the horizontal axis like on a Transient or DC Sweep Simulation.
Methods:
_set_steps(step_info)get_time_axis([step])get_wave([step])step_offset(step)
- class LTSpice_RawRead.DataSet(name, datatype, datalen, numerical_type='real')[source]¶
Bases:
objectClass for storing Traces.
Methods:
get_len()get_point(n)get_wave()set_pointA(n, value)function to be used on ASCII RAW Files.
set_pointB16(n, value)set_pointB4(n, value)Function that converts a normal trace into float on a Binary storage.
set_pointB8(n, value)Function that converts the variable 0, normally associated with the plot X axis.
- set_pointA(n, value)[source]¶
function to be used on ASCII RAW Files.
- Parameters
n – the point to set
value – the Value of the point being set.
- set_pointB4(n, value)[source]¶
Function that converts a normal trace into float on a Binary storage. This codification uses 4 bytes. The codification is done as follows:
.
7
6
5
4
3
2
1
0
Byte3
SGM
SGE
E6
E5
E4
E3
E2
E1
SGM - Signal of Mantissa: 0 - Positive 1 - Negative
Byte2
E0
M22
M21
M20
M19
M18
M17
M16
SGE - Signal of Exponent: 0 - Positive 1 - Negative
Byte1
M15
M14
M13
M12
M11
M10
M9
M8
E[6:0] - Exponent
Byte0
M7
M6
M5
M4
M3
M2
M1
M0
M[22:0] - Mantissa.
- set_pointB8(n, value)[source]¶
Function that converts the variable 0, normally associated with the plot X axis. The codification is done as follows:
.
7
6
5
4
3
2
1
0
Byte7
SGM
SGE
E9
E8
E7
E6
E5
E4
SGM - Signal of Mantissa: 0 - Positive 1 - Negative
Byte6
E3
E2
E1
E0
M51
M50
M49
M48
SGE - Signal of Exponent: 0 - Positive 1 - Negative
Byte5
M47
M46
M45
M44
M43
M42
M41
M40
E[9:0] - Exponent
Byte4
M39
M38
M37
M36
M35
M34
M33
M32
M[51:0] - Mantissa.
Byte3
M31
M30
M29
M28
M27
M26
M25
M24
Byte2
M23
M22
M21
M20
M19
M18
M17
M16
Byte1
M15
M14
M13
M12
M11
M10
M9
M8
Byte0
M7
M6
M5
M4
M3
M2
M1
M0
- class LTSpice_RawRead.DummyTrace(name, datatype)[source]¶
Bases:
objectDummy Trace for bypassing traces while reading
Methods:
set_pointA(n, value)set_pointB16(n, value)set_pointB4(n, value)set_pointB8(n, value)
- exception LTSpice_RawRead.LTSPiceReadException[source]¶
Bases:
ExceptionCustom class for exception handling
- class LTSpice_RawRead.LTSpiceRawRead(raw_filename, traces_to_read='*', **kwargs)[source]¶
Bases:
objectClass for reading LTSpice wave Files. It can read all types of Files. If stepped data is detected, it will also try to read the corresponding LOG file so to retrieve the stepped data.
Methods:
_load_step_information(filename)get_raw_property([property_name])Get a property.
get_steps(**kwargs)get_time_axis([step])This funcion is to workaround on a LTSpice issue when using 2nd Order compression, where some values have a negative value
get_trace(trace_ref)Retrieves the trace with the name given.
Attributes:
- get_time_axis(step=0)[source]¶
This funcion is to workaround on a LTSpice issue when using 2nd Order compression, where some values have a negative value
- header_lines = ['Title', 'Date', 'Plotname', 'Output', 'Flags', 'No. Variables', 'No. Points', 'Offset', 'Command', 'Variables', 'Backannotation']¶
- class LTSpice_RawRead.Op(name, datatype, datalen, axis, numerical_type='real')[source]¶
Bases:
LTSpice_RawRead.TraceClass used for storing operation points.
- LTSpice_RawRead.RawRead¶
This section is for testing your code
alias of
LTSpice_RawRead.LTSpiceRawReadMethods:_load_step_information(filename)get_raw_property([property_name])Get a property.
get_steps(**kwargs)get_time_axis([step])This funcion is to workaround on a LTSpice issue when using 2nd Order compression, where some values have a negative value
get_trace(trace_ref)Retrieves the trace with the name given.
get_trace_names()Attributes:
header_lines