diff options
author | Marti Bolivar <mbolivar@leaflabs.com> | 2011-08-29 19:45:55 -0400 |
---|---|---|
committer | Marti Bolivar <mbolivar@leaflabs.com> | 2011-08-29 19:45:55 -0400 |
commit | 2b793551da411dfc0534322b9b7c1b03766fca6e (patch) | |
tree | e165301abb98dcd454ce0db62d868d219e140cde | |
parent | 08ecbba662402382fb5558ee7832f23dcf83d445 (diff) | |
download | librambutan-2b793551da411dfc0534322b9b7c1b03766fca6e.tar.gz librambutan-2b793551da411dfc0534322b9b7c1b03766fca6e.zip |
hardwarespi: Add docs on SPI modes.
-rw-r--r-- | source/lang/api/hardwarespi.rst | 4 |
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 |