L6474 only answers SPI command by sending the command back after 1 Byte delay
I'm controlling a L6474PD Stepper motor driver withan STM32F338 mcu. It is not a demo PCB but PCB made for our targeted product.
I manage to control the motor with PWM and DIR pins, and send Disable and Enable SPI Commands that work ( basically all commands not requiering feedback ar ok).
However , trying to send a GetParam or GetStatus command over the MOSI line only returns the sent bytes over the MISO.
I first thougth that it was a short between the 2 lines, but the strange thing is that the feed back comes with 1 byte delay (check with the Scope), which means the drivers acts like it saves the received command, and send it back on the next incoming byte over SPI bus.
For example if i send
D0h, 00h, 00h ( Get Status + 2 x Nops)
in the RX buffer I receive
00h, D0h, 00h
as answer , and that for evey byte sent.
i tried to send
D0h, 55h, 00h ( Get Status + Random byte + NOP )
i received
00h, D0h, 55h
As i said , the signals and the 1 byte delay are also visble on the scope
For convenience, i used the HAL library ( no DMA, no IT ) HAL_SPI_TransmitReceive, 1,2 Mbps, Pol High, 2 Edge, 8 bits MSB, and soft CS, TI mode disabled as in the L6474 examples available for IHM01A1 boards, CS stays LOW for the whole 1, 2 , 3 or 4 bytes length of a command and is hgih otherwise
As this behaviour is not expected and quite strange, i was wondering if anybody already had such case.
Thanks
