Generating code for monitored signals, Generating code for monitored signals -3 – National Instruments AutoCode NI MATRIX User Manual

Page 230

Advertising
background image

Chapter 9

Global Scope Signals and Parameterless Procedures

© National Instruments Corporation

9-3

AutoCode Reference

memory address, and that string is accessible through template tokens
during code generation.

Note

Be careful when selecting only a partial subset of block outputs as Global Scope

when generating vectorized code. NI recommends that if you intend for some of the block’s
output to be global, you make them all global so as to preserve loops within the generated
code.

Generating Code for Monitored Signals

The only difference between the code when using Global Scope signals
will be the declarations of the variables used for the local block outputs.
AutoCode provides the following set of TPL tokens to allow you to
customize the declaration of these variables. Since monitored signals are
not intended to be shared between subsystems, the global variables used to
represent monitored signals are grouped by subsystem. For more
information about these tokens, refer to the Template Programming
Language User Guide
.

The default template uses the following tokens to declare the variables. The
visibility of the global variable declarations must include the subsystem for
which they are intended.

gtype_nmembers_i

gtype_b

gtype_members_ls

gtype_members_size_li

gtype_members_typ_pfix_ls

gtype_members_typ_li

gtype_members_memaddr_ls

gtype_blk_list_li

gtype_blk_channel_list_li

Note

You must write template code to customize the declarations of these variables.

That includes usage of the Memory Address string, as this is target/compiler specific
information.

Advertising