Read and Write bytes to external SPI MRAM (SAMV71)

Go To Last Post
2 posts / 0 new
Author
Message
#1
  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Hello All,

 

I am trying to interface with an MR25H40DF MRAM chip over SPI using my SAMv71 dev board. I simply need to write data and read it back to do single event upset testing. I've connected the CS to PD25-NPCS1 and the SPCK, MISO, MOSI to PD22, PD20, PD21 respectively. 

 

The issue I'm having is there are zero example programs on how to write and read data to an external spi memory, only an example about doing it to a second dev board.

 

Is there any example code out there I can use to be able to do this?

 

Best regards

  • 1
  • 2
  • 3
  • 4
  • 5
Total votes: 0

Have you used SPI before, on any other MCU besides the SAMV71?

 

Are you familiar with terms like CPOL, CPHA, dummy bits, dummy bytes, slave registers , host/client, master/slave etc? Using SPI to communicate with a second dev board (the second board being configured as the slave device) is almost identical to communicate with an MRAM, or an FRAM, or a NOR flash, or an RTC etc.

 

There is huge amounts of example code for SPI in general all over the internet, but to help us help you - what is the problem you're having?