From 0d30170de0ba1a9e294d5f29864c4f94e9269243 Mon Sep 17 00:00:00 2001 From: Paul Dino Jones Date: Thu, 11 Jun 2026 18:28:21 -0400 Subject: [PATCH] Set buffer size to 64 bytes for simnet pedals. Send 0 for frequency and amplitude when no effect is playing --- src/monocoque/devices/usb/simnetpedals.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/monocoque/devices/usb/simnetpedals.c b/src/monocoque/devices/usb/simnetpedals.c index 0879211..0e104a1 100644 --- a/src/monocoque/devices/usb/simnetpedals.c +++ b/src/monocoque/devices/usb/simnetpedals.c @@ -8,7 +8,7 @@ #include "../../helper/confighelper.h" #include "../slog/slog.h" -#define SIMNETPEDALS_BUFSIZE 9 +#define SIMNETPEDALS_BUFSIZE 64 //Byte[0] : 0x01 (fixed) = Report ID //Byte[1] : 0x00 (fixed) @@ -39,8 +39,11 @@ int simnetpedals_update(USBGenericHapticDevice* usbhapticdevice, int effecttype, { motormultiple = 2; } - bytes[3 + (motormultiple * 2)] = usbhapticdevice->frequency; - bytes[4 + (motormultiple * 2)] = usbhapticdevice->amplitude; + if(play > 0) + { + bytes[3 + (motormultiple * 2)] = usbhapticdevice->frequency; + bytes[4 + (motormultiple * 2)] = usbhapticdevice->amplitude; + } if (usbhapticdevice->handle)