File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -12,8 +12,14 @@ pub trait Transfer<W: 'static> {
1212 where
1313 Self : ' a ;
1414
15- /// Writes `words` to the slave from the `write` buffer. Puts the words returned in the `read` buffer.
16- /// This method uses separate `write` and `read` buffers.
15+ /// Writes and reads simultaneously. `write` is written to the slave on MOSI and
16+ /// words received on MISO are stored in `read`.
17+ ///
18+ /// It is allowed for `read` and `write` to have different lengths, even zero length.
19+ /// The transfer runs for `max(read.len(), write.len())` words. If `read` is shorter,
20+ /// incoming words after `read` has been filled will be discarded. If `write` is shorter,
21+ /// the value of words sent in MOSI after all `write` has been sent is implementation defined,
22+ /// typically `0x00`, `0xFF`, or configurable.
1723 fn transfer < ' a > ( & ' a mut self , write : & ' a [ W ] , read : & ' a mut [ W ] ) -> Self :: TransferFuture < ' a > ;
1824}
1925
You can’t perform that action at this time.
0 commit comments