Read Memory
- Updated2023-02-17
- 3 minute(s) read
Read Memory
Reads from memory available on the FPGA target.
If you implement the memory item using block memory or look-up tables, you can read data only from the clock domain in which the memory is written. In these implementations, optimize your code by using only one writer node and one reader node for each memory item. To read and write in a separate clock domain, use FIFOs or registers.
Inputs/Outputs

reference in
Reference to the memory item.

address
Memory address to read from.
The valid address range depends on the requested number of elements you specify when creating the input memory item. For example, if you specify a requested number of elements of 65536, the valid address range is 0–65535. If address exceeds the address range, this node returns an error.

error in
Error conditions that occur before this node runs.
The node responds to this input according to standard error behavior.
Default value: No error

reference out
Reference to the memory item.

data
Data retrieved from the specified address of the memory item.

error out
Error information.
The node produces this output according to standard error behavior.
Programming Patterns
Configuring Memory for Read and Write Access
On the Item tab, use the Memory interfaces option to configure the interface (A or B) that this node reads from. Depending on the read/write access you configured when creating the memory using the Create Memory node, select an appropriate interface using the following guidelines:
- If the memory has both read and write access, select Read A.
- If the memory is read-only, which means dual-port read access, select Read A or Read B.
Related Information
- Create Memory
Creates a locally scoped memory item.