SPI always returns 0xFF
So we have a custom board from which we want to read a pressure sensor slave information via SPI.
And a similar exercise we have done with the NUCLEO board as well. NUCLEO756Z.
On the Nucleo the code run for a short while and then after half an hour it just starts returning 0xFF and also after reprogramming the device just get the same outputs.
So in all the code works perfectly for half an hour and then kaput.
I cant seem to understand what the problem is here since we are just sending 2 bytes and receiving 22 bytes nothing more complicated than that. I am scratching my head for over a week but cant get around this issue. Has anyone encountered such an issue.
I have also tried separate HAL receive transmits but to no avail after that.
HAL_GPIO_WritePin (CS_ND210_GPIO_Port, CS_ND210_Pin, GPIO_PIN_RESET);
SPI_RES = HAL_SPI_Transmit (&hspi5, sent, 2, 100);
SPI_RES = HAL_SPI_Receive (&hspi5, recv[2], 20, 100);
HAL_Delay(1);
HAL_GPIO_WritePin (CS_ND210_GPIO_Port, CS_ND210_Pin, GPIO_PIN_SET);
HAL_Delay(5);
