FPGA Central - World's 1st FPGA / CPLD Portal

FPGA Central

World's 1st FPGA Portal

 

Go Back   FPGA Groups > NewsGroup > Verilog

Verilog comp.lang.verilog newsgroup / usenet

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 07-24-2003, 09:39 PM
Jim Wu
Guest
 
Posts: n/a
Default Re: Loading data into memory from a file


"John Vinyard" <[email protected]> wrote in message
news:[email protected]
> I have a memory model in verilog made with an array of registers. I'm
> trying to load data into it from a file in simulation, specifically using
> MTI's Modelsim 5.7 SE. Trial and error with the $readmemh command is not
> working. Any help you could give would be greatly appreciated.
>
> reg [Data_Width-1:0] memory[65535:0];
>
> Right now, I would settle for some way to execute a script from a file,
> something like:
>
> memory[0] = 36'hfeedfacea;
> memory[1]...


The data file has to be in the format that readmemh understands if you want
to use the function.

@addr_in_hex data_in_hex

The address part is optional

Jim
[email protected]




Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Re: Loading data into memory from a file Kevin Neilson Verilog 0 07-24-2003 09:12 PM


All times are GMT +1. The time now is 03:40 AM.


Powered by vBulletin® Version 3.8.0
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0
Copyright 2008 @ FPGA Central. All rights reserved