BeSpiceWaveParserLimitedEdition
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
Variables
003_example_wp_py_obj_calculator_basics.py File Reference

This file contains an example for the use of the BeSpice Wave python module access functions. More...

Variables

tuple 003_example_wp_py_obj_calculator_basics.af_wp_module = af_waveform_path.import_module()
 
tuple 003_example_wp_py_obj_calculator_basics.af_wp_obj = af_waveform_path.get_parser_object()
 
string 003_example_wp_py_obj_calculator_basics.script_path = ""
 Call help(af_waveform_path.get_module_name()) to read the builtin help. More...
 
string 003_example_wp_py_obj_calculator_basics.file_name = "../example/fourbitadder.spi3"
 Define the path to the example waveform file. More...
 
tuple 003_example_wp_py_obj_calculator_basics.return_code = af_wp_obj.readFile(file_name)
 Read the waveform file. More...
 
tuple 003_example_wp_py_obj_calculator_basics.all_sections = af_wp_obj.getSections()
 This functionallows to check if the returned result is a retun code. More...
 
list 003_example_wp_py_obj_calculator_basics.af_wp_section_obj = all_sections[0]
 here we use the just 1st section
 
tuple 003_example_wp_py_obj_calculator_basics.all_curves = af_wp_section_obj.getCurves()
 we pick the first 2 curves. More...
 
tuple 003_example_wp_py_obj_calculator_basics.curve_obj_0 = af_wp_module.curve()
 
tuple 003_example_wp_py_obj_calculator_basics.curve_obj_1 = af_wp_module.curve()
 
tuple 003_example_wp_py_obj_calculator_basics.flag_common_sweep_variable = curve_obj.findProperty("prop_variable_sweep_variable")
 
string 003_example_wp_py_obj_calculator_basics.calculator_expression = "new_curve_name = {0} + {1}"
 we have 2 valid curves, we will perform some operations on them More...
 
tuple 003_example_wp_py_obj_calculator_basics.result_curve_obj = af_wp_obj.calculatorEvaluate(calculator_expression)
 
tuple 003_example_wp_py_obj_calculator_basics.scalar_result = af_wp_obj.calculatorEvaluate(calculator_expression)
 

Detailed Description

This file contains an example for the use of the BeSpice Wave python module access functions.

The used functions allow to parse spice simulation results and to retrieve the contained data.

The comments in the example code give more explanations on the performed API function calls.

If a waveform file is passed as 1st argument, the specified file will be read instead of the included example.