]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/mic-985xx/api.c
Consistently use the "Sysclk" spelling everywhere.
[libsigrok.git] / src / hardware / mic-985xx / api.c
index 3af30a2add2c45945719ba34837de3f476e0fead..9e33f0ad83f2e2cd35aa89d6e131691d4d4104c3 100644 (file)
@@ -116,19 +116,16 @@ static GSList *scan(GSList *options, int idx)
        if (!conn)
                return NULL;
 
-       if (serialcomm) {
-               /* Use the provided comm specs. */
+       if (serialcomm)
                devices = mic_scan(conn, serialcomm, idx);
-       } else {
-               /* Try the default. */
+       else
                devices = mic_scan(conn, mic_devs[idx].conn, idx);
-       }
 
        return devices;
 }
 
-static int config_set(uint32_t key, GVariant *data, const struct sr_dev_inst *sdi,
-               const struct sr_channel_group *cg)
+static int config_set(uint32_t key, GVariant *data,
+       const struct sr_dev_inst *sdi, const struct sr_channel_group *cg)
 {
        struct dev_context *devc;
 
@@ -139,8 +136,8 @@ static int config_set(uint32_t key, GVariant *data, const struct sr_dev_inst *sd
        return sr_sw_limits_config_set(&devc->limits, key, data);
 }
 
-static int config_list(uint32_t key, GVariant **data, const struct sr_dev_inst *sdi,
-               const struct sr_channel_group *cg, int idx)
+static int config_list(uint32_t key, GVariant **data,
+       const struct sr_dev_inst *sdi, const struct sr_channel_group *cg, int idx)
 {
        /*
         * We can't use the ternary operator here! The result would contain
@@ -166,7 +163,6 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi, int idx)
        sr_sw_limits_acquisition_start(&devc->limits);
        std_session_send_df_header(sdi);
 
-       /* Poll every 100ms, or whenever some data comes in. */
        serial = sdi->conn;
        serial_source_add(sdi->session, serial, G_IO_IN, 100,
                      mic_devs[idx].receive_data, (void *)sdi);