mirror of
https://github.com/4yn/slidershim.git
synced 2024-11-12 00:40:49 +01:00
fix hid regression on yubideck
This commit is contained in:
parent
0b75d1c62e
commit
e285bdb999
@ -211,11 +211,12 @@ impl HidJob {
|
|||||||
0x02, // Need to confirm
|
0x02, // Need to confirm
|
||||||
*disable_air,
|
*disable_air,
|
||||||
|buf, input| {
|
|buf, input| {
|
||||||
if buf.len != 45 {
|
if buf.len != 45 && buf.len != 46 {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
input.ground.copy_from_slice(&buf.data[2..34]);
|
input.ground.copy_from_slice(&buf.data[2..34]);
|
||||||
|
input.flip_vert();
|
||||||
for i in 0..6 {
|
for i in 0..6 {
|
||||||
input.air[i ^ 1] = (buf.data[0] >> i) & 1;
|
input.air[i ^ 1] = (buf.data[0] >> i) & 1;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user