aboutsummaryrefslogtreecommitdiffstats
path: root/source
diff options
context:
space:
mode:
authorMarti Bolivar <mbolivar@leaflabs.com>2011-08-29 19:45:55 -0400
committerMarti Bolivar <mbolivar@leaflabs.com>2011-08-29 19:45:55 -0400
commit2b793551da411dfc0534322b9b7c1b03766fca6e (patch)
treee165301abb98dcd454ce0db62d868d219e140cde /source
parent08ecbba662402382fb5558ee7832f23dcf83d445 (diff)
downloadlibrambutan-2b793551da411dfc0534322b9b7c1b03766fca6e.tar.gz
librambutan-2b793551da411dfc0534322b9b7c1b03766fca6e.zip
hardwarespi: Add docs on SPI modes.
Diffstat (limited to 'source')
-rw-r--r--source/lang/api/hardwarespi.rst4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/lang/api/hardwarespi.rst b/source/lang/api/hardwarespi.rst
index 3e71fb6..f90fc07 100644
--- a/source/lang/api/hardwarespi.rst
+++ b/source/lang/api/hardwarespi.rst
@@ -57,6 +57,10 @@ The speed at which the SPI port communicates is configured using a
.. note:: Due to hardware issues, you can't use the frequency
``SPI_140_625KHz`` with SPI port 1.
+The "mode" value determines the clock phase and polarity, like so:
+
+.. doxygenenum:: spi_mode
+
You'll need to determine the correct values for ``frequency``,
``bitOrder``, and ``mode`` yourself, by consulting the datasheet for
the device you're communicating with. Continuing our example from