File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -268,6 +268,17 @@ impl<T: ErrorType + ?Sized> ErrorType for &mut T {
268
268
pub trait AddressMode : private:: Sealed + ' static { }
269
269
270
270
/// 7-bit address mode type.
271
+ ///
272
+ /// Note that 7-bit addresses defined by drivers should be specified in **right-aligned** form,
273
+ /// e.g. in the range `0x00..=0x7F`.
274
+ ///
275
+ /// For example, a device that has the seven bit address of `0b011_0010`, and therefore is addressed on the wire using:
276
+ ///
277
+ /// * `0b0110010_0` or `0x64` for *writes*
278
+ /// * `0b0110010_1` or `0x65` for *reads*
279
+ ///
280
+ /// Should be specified as `0b0011_0010` or `0x32`, NOT `0x64` or `0x65`. Care should be taken by both HAL and driver
281
+ /// crate writers to use this scheme consistently.
271
282
pub type SevenBitAddress = u8 ;
272
283
273
284
/// 10-bit address mode type.
You can’t perform that action at this time.
0 commit comments