- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello all!
I am trying to write some data to an external 16-bit MRAM memory. This MRAM memory has a tristate data bus, so in my SOPC system, the CPU connects to an Avalon-MM Tristate Bridge, that connects to the MRAM controlelr. The CPU, a NIOS-II/f, performs write requests with 32-bit words, but only the 16 LSBs of these words are written to the MRAM, the Tristate Bridge does not seem to be capable of performing two 16-bit write requests from a 32-bit write request. Is there a way to properly write 32-bit words to a 16-bit tristate data bus device using the Avalon-MM Tristate Bridge? Many thanks, Florian B.Link Copied
4 Replies
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
This seems odd. The problem is most likely between your tristate bridge and MRAM controller. Did you write the MRAM controller? What data width did you use? Did you include byte enables?
Jake- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hello Jake,
Thanks for trying to help me. I did not write the MRAM controller, it just consists of an Avalon-MM interface with fixed wait states. Here are the settings for this interface: add_interface mram avalon_tristate end set_interface_property mram activeCSThroughReadLatency false set_interface_property mram bridgesToMaster "" set_interface_property mram holdTime 0 set_interface_property mram isMemoryDevice true set_interface_property mram isNonVolatileStorage false set_interface_property mram maximumPendingReadTransactions 0 set_interface_property mram printableDevice false set_interface_property mram readLatency 0 set_interface_property mram readWaitStates 3 set_interface_property mram readWaitTime 3 set_interface_property mram setupTime 1 set_interface_property mram timingUnits Cycles set_interface_property mram writeWaitStates 3 set_interface_property mram writeWaitTime 3 set_interface_property mram ENABLED true add_interface_port mram mram_oe_n read_n Input 1 add_interface_port mram mram_we_n write_n Input 1 add_interface_port mram mram_be_n byteenable_n Input 2 add_interface_port mram mram_address address Input 20 add_interface_port mram mram_data data Bidir 16 add_interface_port mram mram_cs_n chipselect_n Input 1 To answer your questions: yes I included byte enables, and the data width at the MRAM interface is 16 bits. I will check the signal waveforms at the tristate side to check if the 32-bit words are properly written to the tristate bridge. I will let you know if something comes out. Regards, Florian B.- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Sorry, I made some mistakes in my first post. Actually, when the CPU performs a 32-bit write request, two 16-bit write requests are performed by the tristate bridge. The issue occurs when a custom component performs a 32-bit write request to the MRAM. In this case, only one 16-bit write request is performed by the tristate bridge.
Do you know why?- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
After using the RTL viewer of my project, I can see that at the input of my tristate bridge, the slave writedata bus is only 16 bits wide.
Between my 32-bit NIOS cpu and the tristate bridge, the 32-bit data bus to 16-bit data bus conversion is made by a "cpu_data_master_arbitrator", but the "write" request signal is not processed by this arbitrator. In the same manner, between my custom master component, called "scope_controller", and the tristate, the 32-bit data bus to 16-bit data bus conversion is made by a "scope_controller_m1_arbitrator", which does not process the "write" request signal also. Therefore, my guess is that the master component connected to the tristate has to handle the write/read features regarding the data bus width of the slave component. Do you agree with this statement?
Reply
Topic Options
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page