From: Markus Siegert Date: Mon, 11 Apr 2016 19:54:10 +0000 (+0200) Subject: hantek-6xxx: Use power of 2 usb packet sizes X-Git-Tag: libsigrok-0.5.0~498 X-Git-Url: https://sigrok.org/gitweb/?a=commitdiff_plain;h=050eb3b32d96a7c0a54dee9ae249514eff937d21;hp=1079324f9e76c4775395e5baaf916f37d4785278;p=libsigrok.git hantek-6xxx: Use power of 2 usb packet sizes Using non power of 2 sizes causes the driver to not work on OS X. Depending on the usb transfer mode the buffer sizes will map perfectly to the underlying transport protocol. --- diff --git a/src/hardware/hantek-6xxx/protocol.h b/src/hardware/hantek-6xxx/protocol.h index 6e87079c..c798a184 100644 --- a/src/hardware/hantek-6xxx/protocol.h +++ b/src/hardware/hantek-6xxx/protocol.h @@ -57,9 +57,9 @@ #define VDIV_MULTIPLIER 10 /* Weird flushing needed for filtering glitch away. */ -#define FLUSH_PACKET_SIZE 2600 +#define FLUSH_PACKET_SIZE 1024 -#define MIN_PACKET_SIZE 600 +#define MIN_PACKET_SIZE 512 #define MAX_PACKET_SIZE (12 * 1024 * 1024) #define HANTEK_EP_IN 0x86