Memory Map Definition

This MotoHawk™ block defines a map of Memory Regions within a Memory Resource. Each region is then configured using the Memory Region Definition block.

Block ID

Memory Map Definition




A Memory Resource is divided into a number of Memory Regions as selected by the Number of Regions parameter. When the number of regions is decreased, regions are removed from the end of the list and the configuration is deleted unless Cancel is pressed and the block mask is re-opened.

A table is used to enter each Region name, number of blocks (# Blocks) and an optional Comment. On entering a number of blocks, the size in bytes is shown in the adjacent # Bytes Result column. Be aware that the blocks within a Memory Resource may vary in size. For example a FLASH device may have several 16K blocks, followed by a number of 256K blocks.

Below the table is a status bar. This bar is shown in  green  when the selected blocks can fit in memory. In this mode it shows the total number of bytes available, bytes used and blocks unallocated. When too many blocks are allocated, the bar becomes  red  and shows number of blocks over-allocated.

Each Memory Region needs to have a behaviour attached that controls how the memory is accessed. This is configured using a separate Memory Region Definition block.

NOTE: When porting between targets, the memory resource may have different block sizes, overall size or not exist. Therefore the resultant region sizes may change. On changing target the user should always check for correct allocation.

Block Mask ExampleBlock Mask Example

Block Parameters

Parameter Field Values Comments/Description
Name Single quote enclosed alpha-numeric text A unique, C-legal name that defines the Map.
Memory Resource Drop down Selects the memory remory resource that is to be divided into regions.
Number of Regions Integer numeric Specifies the number of regions that are to be defined. Note the original region settings will be lost if the number is reduced and then increased.
Table of Regions Excel style rows of Region Name, Number of Blocks, Bytes Result and Comment Defines the region name, size and comment. There is one row per region.