]> sigrok.org Git - libsigrok.git/blobdiff - libsigrok-internal.h
es519xx: restore correct packet size
[libsigrok.git] / libsigrok-internal.h
index 51780c2dc9e7b3f975f9ee3994e64f0a090432ab..4b557bbc11e04c99cd6ef6e546c182c39d160345 100644 (file)
@@ -200,7 +200,11 @@ SR_PRIV int sr_es51922_parse(const uint8_t *buf, float *floatval,
 
 /*--- hardware/common/dmm/es519xx.c -----------------------------------------*/
 
-#define ES519XX_11B_PACKET_SIZE (2 * 11)
+/**
+ * All 11-byte es519xx chips repeat each block twice for each conversion cycle
+ * so always read 2 blocks at a time.
+ */
+#define ES519XX_11B_PACKET_SIZE (11 * 2)
 #define ES519XX_14B_PACKET_SIZE 14
 
 struct es519xx_info {
@@ -221,7 +225,7 @@ SR_PRIV gboolean sr_es519xx_2400_11b_packet_valid(const uint8_t *buf);
 SR_PRIV int sr_es519xx_2400_11b_parse(const uint8_t *buf, float *floatval,
                struct sr_datafeed_analog *analog, void *info);
 SR_PRIV gboolean sr_es519xx_19200_11b_5digits_packet_valid(const uint8_t *buf);
-SR_PRIV int sr_es519xx_19200_11b_5difits_parse(const uint8_t *buf,
+SR_PRIV int sr_es519xx_19200_11b_5digits_parse(const uint8_t *buf,
                float *floatval, struct sr_datafeed_analog *analog, void *info);
 SR_PRIV gboolean sr_es519xx_19200_11b_clamp_packet_valid(const uint8_t *buf);
 SR_PRIV int sr_es519xx_19200_11b_clamp_parse(const uint8_t *buf,