Main Content


Returns decimation value of File Log block based on block path



fileLogDecimation = getFileLogDecimation(app_object,block_path) returns the value of decimation for the specified File Log block. You can use this function to get the decimation setting of a particular File Log block or to verify the changed decimation after using the setFileLogDecimation function.


collapse all

Use the getFileLogDecimation function to get the decimation setting for a File Log block that you specify by using a block paths from a real-time application object.

Get the block paths for File Log blocks in the real-time application.

myApp = slrealtime.Application('slrt_ex_osc');
myFileLogBlocks = getAllFileLogBlocks(my_App)
myFileLogBlocks =

  2×1 cell array

    {["slrt_ex_osc/File Log"]}
    {["slrt_ex_osc/File Log"]}

Get the decimation value for a selected File Log block.

myDecimation = getFileLogDecimation(myApp,"slrt_ex_osc/File Log")
myDecimation =



Input Arguments

collapse all

Provides access to methods that manipulate the real-time application files.

The block_path values can be:

  • Empty character vector ('') or empty string scalar ("") for base or model workspace variables

  • Character vector or string scalar string for block path to parameters in the top model

  • Cell array of character vectors or string scalars for model block arguments

Example: '', 'Gain1', {'top/model','sub/model'}

Output Arguments

collapse all

The returned fileLogDecimation is the decimation value of the selected File Log block.

Version History

Introduced in R2022a