spi: Add SPI transfer function that pass in RX/TX
authorKurt Eckhardt <kurte@rockisland.com>
Sat, 18 Oct 2014 16:25:19 +0000 (09:25 -0700)
committerBrendan Le Foll <brendan@fridu.org>
Sun, 19 Oct 2014 08:00:57 +0000 (09:00 +0100)
commit2a11e31052521c25f0f1c75e472465e73fc3c906
treead8d658f0eb9c4316af2cf16b794c36694634464
parent54deb0179627022dfc4a0293dd9126beeed9dfb0
spi: Add SPI transfer function that pass in RX/TX

When using SPI, I prefer to not have to do malloc/free functions for each
transfer, so why not have a transfer function that you can pass in both
buffers.  With my ILI9341 TFT display code that gave some perf wins, also more
of a win, you can pass in NULL for recv buffer and the underlying device driver
does not have to copy the data.

Signed-off-by: Kurt Eckhardt <kurte@rockisland.com>
Signed-off-by: Brendan Le Foll <brendan.le.foll@intel.com>
api/mraa/spi.h
api/mraa/spi.hpp
examples/c++/Spi-pot.cpp
src/spi/spi.c