|
Message
From: Mark McDougall<markm@v...>
Date: Wed Dec 7 00:44:33 CET 2005
Subject: [pci] how to use the PCI bridge IP core ?
Robert Lluís Garcia wrote:> On the board side I have the following VHDL code to talk to the wishbone > bus. > wbm_err_i <= '0'; -- no error > wbm_rty_i <= '0'; -- no retry > wbm_ack_i <= wbm_stb_o; --instantaneous acknowledgment > wbm_dat_i <= "00000000000000000000000000001000"; -- data returned
Looks OK to me so far... (I'd use wbm_dat_i <= X"0008"; tho')
> Now, the data read by the C program is not what I would expect. I would > expect to read always the value in wbm_dat_i but it is not like that so > something is wrong.
What data are you getting back? Is it consistent? Constant or random?
I haven't used /dev/mem to access PCI space before as I've only accessed PCI space in a linux driver, so I can't vouch for your code but it looks OK.
If you want to eliminate your code from the equation just to verify the firmware, create a DOS boot floppy and put a copy of CDBG on it. It has a simple CLI for twiddling PCI resources - you'll be up and running in a matter of minutes - invaluable!
<http://www.probo.com/cdbg.htm>
Regards,
-- Mark McDougall, Software Engineer Virtual Logic Pty Ltd, <http://www.vl.com.au> 21-25 King St, Rockdale, 2216 Ph: +612-9599-3255 Fax: +612-9599-3266
|
 |