This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MIBSPI GetData no read

Other Parts Discussed in Thread: HALCOGEN

Good morning, I am trying to communicate data between a Hercules and an ESP-PSRAM64 SPI RAM, for this I have carried out two tests.


The first test was using the normal SPI communication and it was successful, I can write and read data.

the second is to use the MIBSPI communication, I have managed to send the data and also receive data, the latter I can check with my logic analyzer, the problem is that in the internal registers of the microcontroller I have not read anything.

Here you can see that the slave is responding successfully to the master

In the program I do not have any value that the slave sends

These are the configurations of the Halcogen, I am using transfer group 3, to read the data sent by the slave

Could you help me to know the correct configuration.
attached project

RM57_MIBSPI.rar

My best Regards

  • Hi Martin,

    I started working on your issue and i will get back to you soon with an update.

    --

    Thanks & Regards,

    Jagadish.

  • thx very much!

    I'm waiting for your response

    Regards

  • Hi Martin,

    I understood the root cause for your issue 

    If we observe your code you are sending data on TG0(4 buffers) and TG1(50 buffers), but you are trying to read the data from TG3(which is start from 59th buffer).

    The MibSPI will work like this, whenever you send some data using Tx buffers of TG0 on MOSI the parallel corresponding data received on MISO will be stored in Rx buffers of TG0, similarly whenever you send some data using Tx buffers of TG1 on MOSI line then the parallel corresponding received data on MISO line will be stored into the Rx buffers of TG1. In your code you didn't send any data on TG3 but you are trying to read the data on TG3, because of that you read all zeros.

    I enabled one loop back test on your code and verified the received buffers in MibSPIRAM3

    You can see that the data is received till the buffer 53(from 0 it is total of 54 buffers), which is the sum of sizes of TG0 and TG1

    So there is no data after 54th buffer because we didn't send any data using TG2 and TG3.

    --

    Thanks & Regards,

    Jagadish.

  • thx very much!, this solve my problem

    Regards From Peru