STM32F1 SPI Simpleton Implementation Fail
Hi Bernard,
I’ve been looking in some C- language courses however DIY since by guidance doesn’t come free. Anyway, I changed pData to &pData and the SPI is effectively outputting TheDataItself. I know it’s wrong still by design since the compiler only allocated one byte and I would not be able to send 16 bits. The bummer is I need to send out 18 bits to external DACs. The nuissence is that the HAL library does many things out of protocol where I want to program straightforward not being interested in readability, portability or scalability. The Z80 way as you like. As like ’ SPI2->DR = 0xAA;’ instead of ‘HAL_SPI_Transmit(&hspi2, 0xAA, cnt, 10);’ which does too many things and wastes MIPS. ’ SPI2->DR = 0xAA’ works and so does ‘SPI2->DR = variable’. I’ll take your advice.