SPI not working with MISO connected to 3V and 0V
I am trying to code SPI functionality to connect with an external 16-bit ADC. The STM32 only receives data from the ADC, so only a MISO and SCLK line, along with a Conversion/CS line is required. I am currently using the 32F072BDISCOVERY board to test my code. Unfortunately, I do not have access to the ADC yet, so to perform simple testing to see if my SPI code is working, I figured I could set the MISO line to ground to receive all 0s or to 3V to receive all 1s. However, no matter what I connect the MISO line to, I only receive 1s.
To make things simple, I set the SPI peripheral data size on the STM32 to 8 bits.
Here is my code. Super simple so I don't know what could be going wrong here.
uint8_t spi_value[1];
HAL_SPI_Receive(&hspi1, spi_value,1,1000);
I am reading out the value over UART and checking it in the live variables section in the debugger. It always is 255, which is the equivalent of all 1s.
