I want compare 32bit reg with rom 1024x32 .
best way for this search?
vhdl code
Sounds like you want a content-addressable memory (CAM).
The basic idea is that a CAM can be searched for values (32-bit word) to get keys (addresses). It does this by having a list of valid addresses per 32-bit word stored in some local memory.
Check out this application note by Xilinx for a more technical description.
Related
I am writing a driver for a DDS(AD9959, analog devices) chip in python. Some of the modes written in the datasheet require writing the register bits as do not care. What is the correct way to implement the same? I tried to use 'x', but the bits are not being written on the chip.
The term "don't care" does not mean some special value for a bit. A bit can only be 0 or 1.
When reading it means that you can ignore the value. Commonly you mask it away.
When writing it means that you are free to choose any value. Most developers write a 0.
I want to get image values and then process this image with my fpga board. But I couldn't import the values of image. I searched block rom usage about it but couldn't find any tutorial or something. How can I import image values? Board is Zynq-7000/verilog/xilinx. Thanks.
You'll need to dump raw bytes from the image, in whatever way you will find convenient, and use some third-party tools (like this one) to create COE file that you will use with the core generator for memory initialization.
It seems Xilinx tools doesn't support COE file creation on its own, even from existing binary data.
Is it possible to do a simple page-walk translation to a Kernel-space VA, from a driver code that I write? I'm trying to use virt_to_phys(), but the translation doesn't look correct to me. Is there any other API that can do that?
virt_to_phys() is the correct path. Why it doesn't seem correct to you?
Take a look at this documentation that explain all the three view of a memory address and how to convert among them.
I don't know if any one have experience in programming in BASIC language. I am reading a manual regarding a device which used enhanced BASIC language. I have no experience at all. The statement is like
OUTPUT 621 USING "#, K, 1024(W)";
I wonder what's the using statement is for? what's '#', 'K' and 1024(W) really mean? Sorry that the manual is so old and some of the pages lost and I can't even tell more information from the context.
In BASIC, USING statement was typically used for output formatting. So you can read that as "Output number 621 using formatting "#, K, 1024(W)"
What that formatting means, I think that's totally dependent on the BASIC dialect, though. You have to consult it's reference manual. # means "number", for sure, and the rest probably specifies how that number should be formatted.
Example of PRINT USING in TrueBasic manual (PDF, found by google).
As a totally wild guess, it could mean, use suffix K after dividing by 1024 and rounding as specified by (W). If this is so, then number 621 is probably number of bytes, and output is wanted in kilobytes.
It looks to me like this is a statement to write output to some type of external storage, any of the myriad types of tapes and disks that existed 35 or 40 years ago. Before things became more standardized with the advent of operating systems like CP/M and MS-DOS, there were hundreds (I'm guessing at the number) of companies building and marketing computers with their own proprietary operating systems. Each one would have its own commands and syntax for reading and writing to peripherals (as any storage outside the RAM was called in those days).
621 probably is the code for the particular tape drive, disk pack or floppy disk that they wanted to write output to. K is probably just a parameter for an option of some sort. I'm pretty sure that 1024(W) refers to the length in bytes to be allocated on the disk or tape for each instance that is written, and I'm even more certain that (W) means to access the device in write-only mode.
Good day,
I am working on a Stratix III FPGA which contains M9K block memories, the contents of which are conveniently initialised to zero on power-on. This suits my application very well.
Is there a way to reset the contents back to zero without power-cycling/reflashing/etc the FPGA? There seems to be no such option in the megawizard plugin manager, and I would like to avoid wasting a bunch of logic which just goes and sequentially writes zero to every address...
I have looked around and there is no reference to such a mechanism, but I thought I'd ask just in case someone knew a handy trick :] By the way I'm working in VHDL but I should be able to translate any Verilog.
Datasheet (does not contain the answer!) : http://www.altera.com/literature/hb/stx3/stx3_siii51004.pdf
Thanks in advance,
- Thomas
PS: This be my first post here, so if I've violated any etiquette please let me know :)
Sorry, the conventional ways to do that are:
to re-configure the fpga (you could trigger that from within your hardware if you don;t mind the whole thing "disappearing" while it reconfigures)
explicitly write zeros in (as you already suggested)
At the wackier end of the solution space, I guess you could also wire something up to the JTAG port if you already have a microcontroller either in the FPGA or outside - you might be able to overwrite the RAM contents that way too.