SPI Read Function of STM8S
There are flags that you must wait on, flags that will indicate when SPI transmission is done or a byte has been received. Try this:

while (SPI_GetFlagStatus(SPI_FLAG_TXE) == RESET); // wait for any previous data to be sent; checks if the Transmit Register is empty
SPI_SendData(NRF905_CMD_NOP);
while (SPI_GetFlagStatus(SPI_FLAG_RXNE) == RESET);  // wait for a byte to come in; checks if the Receive register is not empty
((uint8_t*)data)[i] = SPI_ReceiveData();