I'm confused with the address mapping used in your Stellar architecture. after reading all the documentation I'm left with a couple questions. We are going through the code as well but hopefully you can answer this directly.
I'm using the example FPGA firmware for the PC720 with the FMC110 and trying to touch registers in the IF Host Star. My CID_PACKAGE file has the following
constant cid_registers :cid_register_type(0 to nb_cid_registers-1):=(
-- REG0 : constellationid<<16|nbrstar
x"01330009",
-- REG1 : software build code
x"53AAFE2F",
-- REG2 : firmware build code
x"00000000",
-- REG3 : VersionHI<<8|VersionLO
x"00000100",
-- REG4..6 : star 'sip_cid' {BaseAddress, EndAddress, StarId<<16|StarVersion}
x"00002000",
x"000023FF",
x"00010100",
<<SNIP>>
-- REG19..21 : star 'sip_xx720_4l_host_if' {BaseAddress, EndAddress, StarId<<16|StarVersion}
x"00012404",
x"00012413",
x"00BE0100",
<<SNIP>>
According to the documentation for the HOST IF STAR you list several register maps but the explanation of how to get to each is a bit nebulous. On page 7 of the SD190 xx720 Host IF Star document I see the Host IF PCI Express register map that includes register offsets 0x000 (RST) downto to 0x043(Cmd2Pci_msb). It then go on to say later about "global address maps" in which 0x000 is test1 and 0x001 is test 1, etc.
Question 1) When i read registers 0 using the linux command "4fm_read_sysreg PC720 0 0", I get the test1 value (xbeefdeaf) using your windows tool I get the same answer. I then read 0x2000 which is the cid_star offset (from the CID_PACKAGE file) and get x"01330009" which is the first register in the CID star (initalized from the sip_cid file). So far so good, the problem is when i attempt to read the first register of the IF star, using the offset 0x12404 I get a timeout from both linux and windows. Based on the address map in the sip_cid shouldn't this give me the first register in the IF star, which based on the table (page 7) in the documents should be the RST register?
Question 2) The register map in the IF star document indicates that the STAR has 67 registers but the CID_PACKAGE file indicates that the star starts at 0x12404 and ends and 0x12413 (15 addresses). How can this be?
Question 3) The IF star document goes further to show another address map (stellar IP local address map) for the I2C but does not indicate where that would be mapped into the PCI space. How does one read say offset 3 into that space?
Question 4) Please explain the difference between the 4fm_read_anyreg, 4fm_read_creg, and 4fm_read_sysreg commands. The documentation is a little lacking on those as well.
Ultimatly I'm trying to write C code to read specific registers inside a star. It would appear that by adding them to the CID_PACKAGE file I should be able to then talk directly into the modules with a read and write command using the offset from the CID_PACKAGE package as the base and then indexing internally to get to addresses within the star itself.
Thanks,
Chris