Memory Allocate
R2026bAllocate memory for new variable
Libraries:
C2000 Microcontroller Blockset /
Memory Operations
Description
The Memory Allocate block, on C2xxx processors, directs the TI compiler to allocate a memory location for a new variable. Block parameters specify the variable name, the alignment of the variable in memory, the data type of the variable, and other features that fully define the memory required.
The block does not verify whether the parameter settings for the variable are valid, such as checking the variable name, data type, or section. You must check that the parameters settings are valid.
You do not connect the Memory Allocation block to other blocks in a model.
Parameters
Programmatic Use: Add Block
To add the block programmatically, use the add_block function with one of these library block paths as the source.
"c2000lib/Memory Operations/Memory Allocate"
Example: add_block("c2000lib/Memory Operations/Memory Allocate","myModel/myBlock",MakeNameUnique="on")
Version History
Introduced in R2011a
See Also
Memory Copy (Embedded Coder)