From 2fa46bf62f62041154d7f831ffb4ae91ac249e03 Mon Sep 17 00:00:00 2001 From: Denis Date: Wed, 29 Nov 2023 18:20:19 +0100 Subject: [PATCH] is this the right byte? --- virt_ds5.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/virt_ds5.c b/virt_ds5.c index 4d14714..21cd78b 100644 --- a/virt_ds5.c +++ b/virt_ds5.c @@ -400,8 +400,8 @@ static int send_data(int fd, logic_t *const logic) { (gs.l3 ? 0x40 : 0x00) | (gs.r3 ? 0x80 : 0x00); - buf[10] = (gs.center ? 0x01 : 0x00); - buf[11] = (gs.lfn ? 0x10 : 0x00) | (gs.rfn ? 0x20 : 0x00); + buf[10] = (gs.lfn ? 0x10 : 0x00) | (gs.rfn ? 0x20 : 0x00) | (gs.center ? 0x01 : 0x00); + //buf[11] = ; //buf[12] = 0x20; // [12] battery level | this is called sensor_temparature in the kernel driver but is never used... memcpy(&buf[16], &g_x, sizeof(int16_t));