On 5 June 2016 at 14:55, 'Eckhardt Ulrich' via linux-sunxi
<[email protected]> wrote:
>
>
> Am Sonntag, 5. Juni 2016 13:45:59 UTC+2 schrieb Michal Suchanek:

> I have checked this with an oscilloscope (a cheap logic analyser is ordered
> so that I could attach a better picture of the output of all pins hopefully
> next week). I have written a small test program (attached to this message)
> which sends repeatedly 4 bytes over the SPI bus using the ioctl.  But on my
> oscilloscope I could see only activities on the CS lines, but no change of
> the CLK and MOSI outputs.

Ok, so you checked with reasonable reliability that no data is
actually transferred.

Now to check that no data transfer is programmed

 - cherry pick from linus master
47284e3e0f3c427c93f8583549b6c938e8a18015 spi: sun4i: allow transfers
to set transmission speed
 - cherry pick from https://github.com/hramrach/linux-sunxi.git branch
sunxi-spi-dma cb90b922caa6ac07c1425d726ea19709ee5284f4 spi: sunxi: fix
transfer timeout

The latter adds a debug print in if(!timeout) so move the if below the
debug print.

In your test program change speed to 5kHz (5000) and change the ioctl
to set the speed - iirc it should be SPI_IOC_WR_MAX_SPEED_HZ

Then you should get a debug print on console every time your test
program sends a message. If not something went wrong.

HTH

Michal

-- 
You received this message because you are subscribed to the Google Groups 
"linux-sunxi" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/d/optout.

Reply via email to