]> sigrok.org Git - libsigrok.git/commitdiff
gmc-mh-1x-2x: Cosmetic fixes for Metrahit 25S.
authorMatthias Heidbrink <redacted>
Sat, 8 Mar 2014 09:50:21 +0000 (10:50 +0100)
committerMatthias Heidbrink <redacted>
Sat, 8 Mar 2014 09:50:21 +0000 (10:50 +0100)
hardware/gmc-mh-1x-2x/protocol.c

index a5d7784b1a2a037c0ce81b57c5516f0c9d2d7544..dd3889395a6cd563b69fef3bce24f2c0419f4948 100644 (file)
@@ -480,8 +480,19 @@ static void decode_ctmv_2x(uint8_t ctmv, struct dev_context *devc)
                devc->unit = SR_UNIT_UNITLESS;
                devc->mqflags |= SR_MQFLAG_AC;
                break;
+       case 0x1f: /* 11111 Undocumented: 25S in stopwatch mode.
+                       The value is voltage, not time, so treat it such. */
+               devc->mq = SR_MQ_VOLTAGE;
+               devc->unit = SR_UNIT_VOLT;
+               devc->mqflags |= SR_MQFLAG_DC;
+               break;
+       case 0x20: /* 100000 Undocumented: 25S in event count mode.
+               Value is 0 anyway. */
+               devc->mq = SR_MQ_VOLTAGE;
+               devc->unit = SR_UNIT_UNITLESS;
+               break;
        default:
-               sr_err("decode_ctmv_2x(%d, ...): Unknown ctmv!");
+               sr_err("decode_ctmv_2x(%d, ...): Unknown ctmv!", ctmv);
                break;
        }
 }