PLECS 3.0 Online Help |
plecsedit(’cmd’, ’parameter1’, ’parameter2’, ...)
where cmd is one of the following commands: get, set, thermal, export, version, hostid.
The command
plecsedit(’get’, ’componentPath’)
plecsedit(’get’, ’componentPath’, ’parameter’)
returns the value of parameter of the PLECS component indicated by the componentPath as a string. If parameter is omitted a cell array with all available parameters is returned.
plecsedit(’set’, ’componentPath’, ’parameter’, ’value’)
sets the value of parameter of the PLECS component indicated by the componentPath to value.
plecsedit(’thermal’, ’import’, valVon, valEon, valEoff)
plecsedit(’thermal’, ’import’, valVon, valEon, valEoff, ...
valCauer)
imports the on-state voltage drop valVon, the switching losses valEon, valEoff and the cauer chain elements valCauer into the thermal editor. The parameter valVon has to be a struct with two index vectors i, T and an output matrix v. The parameters valEon and valEoff have to be structs with three index vectors v, i, T and an output array E. The optional argument valCauer has to be a struct with two array elements, C and R. The command can be used to import thermal descriptions as used in PLECS 1.x into the thermal library of PLECS 2.x.
plecsedit(’thermal’, ’export’, ’filename’)
reads the thermal data sheet from filename and returns a struct with the fields Von, Eon, Eoff, CauerChain and Comment containing the respective data from the thermal data sheet. The parameter filename has to be an absolute filename to the data sheet including the .xml extension.
plecsedit(’thermal’, ’export’, ’filename’, ’modelName’)
reads the thermal data sheet from filename and returns a struct with the fields Von, Eon, Eoff, CauerChain and Comment containing the respective data from the thermal data sheet. The parameter filename has to be a relative filename to the data sheet without the .xml extension.
plecsedit(’export’, ’modelName’)
plecsedit(’export’, ’modelName’, hideSchematics)
plecsedit(’export’, ’modelName’, hideSchematics, ’filename’)
exports the model modelName for the PLECS Viewer. By setting the optional argument hideSchematics to true all PLECS circuits are marked as non-viewable. If argument filename is given it is used as the exported model's filename, otherwise you are prompted for a filename.
The command
plecsedit(’version’)
returns the PLECS version information as a string and
plecsedit(’hostid’)
returns a struct with hostid and MATLAB license information.
Some examples for using the command line interface:
plecsedit(’get’, ’mdl/Circuit1’)
returns the parameters of Circuit1 in the simulink model mdl.
plecsedit(’get’, ’mdl/Circuit1’, ’Name’)
returns the name of Circuit1.
plecsedit(’get’, ’mdl/Circuit1’, ’CircuitModel’)
returns the circuit simulation method of Circuit1.
plecsedit(’get’, ’mdl/Circuit1/R1’)
returns the parameters of component R1 in circuit Circuit1.
plecsedit(’set’, ’mdl/Circuit1/R1’, ’R’, ’2’)
sets the resistance of component R1 in circuit Circuit1 to 2.
plecsedit(’export’, ’mdl’, true, ’exported.mdl’)
exports the model mdl to the model file exported.mdl which can be opened with the PLECS Viewer. The contents of all PLECS schematics are hidden.
data =
plecsedit(’thermal’, ’export’, ’Infineon/SDP04S60’, ...
’plSMPS_CCM’)
assigns the thermal description from library element Infineon/SDP04S60 in model plSMPS_CCM to the variable data in the MATLAB workspace.