Tools¶
tools ¶
Provides some tools that could be used almost out of the box
translate_lustre ¶
Translates a lustre file into intrepyd syntax
inttype is 'int32' by default, as it always was; 'int' encodes lustre int as unbounded integers, its actual semantics, which is often much easier for the engines too
translate_simulink ¶
translate_simulink(infilename, outmodule='encoding', realtype='float', variables=None, scripts=None, mats=None, callbacks=True)
Translates a Simulink model, a .mdl or a .slx file, into intrepyd syntax
The circuit of the module has the root Inport and Outport blocks of the model as inputs and outputs, and as targets its Assertion blocks, reached when an assertion fails, and the errors that would stop a simulation of its Stateflow charts (a division by zero, a state inconsistency, a conversion out of range). realtype is 'float' (single and double as floats, exactly) or 'real' (as reals, which is not exact). The MATLAB workspace the model refers to is filled by the callbacks of the model, unless callbacks is False, then by the MAT files in mats, the MATLAB scripts in scripts, and the variables, a dictionary of MATLAB expressions. Raises intrepyd.simulink.SimulinkError, listing the blocks that cannot be translated, if the model cannot be. Needs the Simulink front-end library, see intrepyd.simulink.
translate_iec61131 ¶
Translates a ST iec61131 file into intrepyd syntax
simulate ¶
Simulates the design using default values for inputs or by taking input values from an existing simulation file