mirror of
https://github.com/ferrous-systems/embedded-trainings-2020.git
synced 2025-01-24 14:58:09 +00:00
re review. point to usb spec for wvalue etc
This commit is contained in:
parent
4bd350c948
commit
f2cc43b55f
1 changed files with 3 additions and 1 deletions
|
@ -65,7 +65,9 @@ impl Request {
|
|||
|
||||
if bmrequesttype == 0b00000000 && brequest == SET_ADDRESS {
|
||||
// Set the device address for all future accesses.
|
||||
// Needed to successfully init when using Apple devices.
|
||||
// (Needed to successfully init when conected to Apple devices)
|
||||
// Section 9.4.6 Set Address of the USB specification explains which values for wvalue,
|
||||
// windex and wlength are valid.
|
||||
if wvalue < 128 && windex == 0 && wlength == 0 {
|
||||
Ok(Request::SetAddress {
|
||||
address: NonZeroU8::new(wvalue as u8),
|
||||
|
|
Loading…
Reference in a new issue