File tree 1 file changed +9
-7
lines changed
1 file changed +9
-7
lines changed Original file line number Diff line number Diff line change @@ -136,26 +136,28 @@ pub trait Filter {
136
136
137
137
/// Applies a mask to the filter.
138
138
///
139
+ /// A filter matches when: `<ReceiveID> & Mask == FilterID & Mask`
140
+ ///
139
141
/// # Example
140
142
///
141
- /// Filter ID : 0b100110111
142
- /// Mask: 0b000001111
143
+ /// FilterID : 0b100110111
144
+ /// Mask: 0b000001111
143
145
///
144
- /// Receive ID : 0b100110011
145
- /// \----> Not accepted (bit 3 did not match)
146
+ /// ReceiveID : 0b100110011
147
+ /// \----> Not accepted (3rd bit did not match)
146
148
///
147
- /// Receive ID : 0b000000111 -> accepted
149
+ /// ReceiveID : 0b000000111 -> accepted
148
150
fn with_mask ( & mut self , mask : u32 ) -> & mut Self ;
149
151
150
152
/// Makes the filter acccept both data and remote frames.
151
153
///
152
- /// Sets the RTR bit in the filter mask.
154
+ /// Clears the RTR bit in the filter mask.
153
155
/// Only available for filters with `RtrFilterBehavior::Configurable`.
154
156
fn allow_remote ( & mut self ) -> & mut Self ;
155
157
156
158
/// Makes the filter acccept remote frames only.
157
159
///
158
- /// Sets the RTR bit in the filter and clears it in the mask (if available).
160
+ /// Sets the RTR bit in both the filter and the mask (if available).
159
161
/// Only available for filters with `RtrFilterBehavior::Configurable` or
160
162
/// `RtrFilterBehavior::ConfigurableEitherDataOrRemote`.
161
163
fn remote_only ( & mut self ) -> & mut Self ;
You can’t perform that action at this time.
0 commit comments