Wait up to 25 ms for each packet echo
With a 10 ms wait an occasional glitch remained; the keyboard is likely sometimes slower to echo, so the next packet still arrived too early. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
0b2a90ba94
commit
668cfd76b2
2 files changed
+2
-2
No files matched your search
@@ -21,7 +21,7 @@ The device settings have a "Key test" option (column or row sweep) to check the
|
|||||||
- The keyboard falls back to its own effect when frames stop, so colours must be streamed.
|
- The keyboard falls back to its own effect when frames stop, so colours must be streamed.
|
||||||
The plugin only sends packets whose colours changed, plus a full frame every 500 ms.
|
The plugin only sends packets whose colours changed, plus a full frame every 500 ms.
|
||||||
- The keyboard echoes every colour packet's header back as an input report. The plugin waits
|
- The keyboard echoes every colour packet's header back as an input report. The plugin waits
|
||||||
for that echo (up to 10 ms) before the next packet, as OpenRGB's EVision driver does.
|
for that echo (up to 25 ms) before the next packet, as OpenRGB's EVision driver does.
|
||||||
- OpenRGB supports this keyboard (`EVision Keyboard 320F:502A`) but only through the saved
|
- OpenRGB supports this keyboard (`EVision Keyboard 320F:502A`) but only through the saved
|
||||||
custom-colour command (`0x11` between begin `0x01` / end `0x02`), not a live mode.
|
custom-colour command (`0x11` between begin `0x01` / end `0x02`), not a live mode.
|
||||||
|
|
||||||
|
|||||||
@@ -163,7 +163,7 @@ function writeRGBPackage(RGBData) {
|
|||||||
|
|
||||||
// The keyboard echoes each packet back; wait for it (as OpenRGB does) so the next
|
// The keyboard echoes each packet back; wait for it (as OpenRGB does) so the next
|
||||||
// packet doesn't arrive while it's still processing this one
|
// packet doesn't arrive while it's still processing this one
|
||||||
device.read([0x04], 64, 10);
|
device.read([0x04], 64, 25);
|
||||||
|
|
||||||
// device.pause() rounds up to the Windows timer tick (up to ~15 ms), so only pause when asked
|
// device.pause() rounds up to the Windows timer tick (up to ~15 ms), so only pause when asked
|
||||||
if (lowFPS) { device.pause(3); }
|
if (lowFPS) { device.pause(3); }
|
||||||
|
|||||||
Reference in new issue
Block a user