]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/arachnid-labs-re-load-pro/api.c
ols: add feature to support >256K memory
[libsigrok.git] / src / hardware / arachnid-labs-re-load-pro / api.c
index 5cef7758314bda6cc5f56702e326874a5dbf5753..d6f95723d83ec9b7603cf4234f34ff1d144c0e8d 100644 (file)
@@ -247,12 +247,8 @@ static int config_get(uint32_t key, GVariant **data,
                *data = g_variant_new_boolean(devc->otp_active);
                break;
        case SR_CONF_UNDER_VOLTAGE_CONDITION:
-               if (reloadpro_get_under_voltage_threshold(sdi, &fvalue) == SR_OK) {
-                       if (fvalue == .0)
-                               *data = g_variant_new_boolean(FALSE);
-                       else
-                               *data = g_variant_new_boolean(TRUE);
-               }
+               if (reloadpro_get_under_voltage_threshold(sdi, &fvalue) == SR_OK)
+                       *data = g_variant_new_boolean(fvalue != 0.0);
                break;
        case SR_CONF_UNDER_VOLTAGE_CONDITION_ACTIVE:
                *data = g_variant_new_boolean(devc->uvc_active);
@@ -351,7 +347,6 @@ static int dev_acquisition_stop(struct sr_dev_inst *sdi)
        g_mutex_clear(&devc->acquisition_mutex);
 
        return ret;
-
 }
 
 static struct sr_dev_driver arachnid_labs_re_load_pro_driver_info = {