GenericWrapperBlock Block

The block GenericWrapperBlock, available in the palette of the WrapperCodeGenerator library, is used to create new Wrapper blocks.

The block GenericWrapperBlock, available in the palette of the WrapperCodeGenerator library, is used to create new Wrapper blocks. The block parameters define the number of inputs and outputs, and their types. Two parameters, OML structures, params and sysparams, define block code snippets to be placed in main.c. The params structure contains specific code snippets for the block to be inserted in main.c before and after calling the body functions. The sysparams structure contains more global code snippets, such as for adding "Include" statements.



The following is an example of parameters of the GenericWrapperBlock used to define an input block.

This block is placed inside a super block. The OML structures params and sysparams can be defined in the context of the super block, and the super block is masked, providing only the relevant parameters in its mask. The resulting block is called a wrapper block and can be placed in the target library.