From: Aurelien Jacobs Date: Sat, 11 Jun 2016 23:48:15 +0000 (+0200) Subject: agilent-dmm: add support for Keysight branded meters X-Git-Tag: libsigrok-0.5.0~291 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=9ae544b6ce98097f9610a0adab8aa14da0d259c9;p=libsigrok.git agilent-dmm: add support for Keysight branded meters --- diff --git a/src/hardware/agilent-dmm/api.c b/src/hardware/agilent-dmm/api.c index 27da6b93..27e84292 100644 --- a/src/hardware/agilent-dmm/api.c +++ b/src/hardware/agilent-dmm/api.c @@ -117,14 +117,15 @@ static GSList *scan(struct sr_dev_driver *di, GSList *options) return NULL; tokens = g_strsplit(buf, ",", 4); - if (!strcmp("Agilent Technologies", tokens[0]) + if ((!strcmp("Agilent Technologies", tokens[0]) || + !strcmp("Keysight Technologies", tokens[0])) && tokens[1] && tokens[2] && tokens[3]) { for (i = 0; supported_agdmm[i].model; i++) { if (strcmp(supported_agdmm[i].modelname, tokens[1])) continue; sdi = g_malloc0(sizeof(struct sr_dev_inst)); sdi->status = SR_ST_INACTIVE; - sdi->vendor = g_strdup("Agilent"); + sdi->vendor = g_strdup(tokens[0][0] == 'A' ? "Agilent" : "Keysight"); sdi->model = g_strdup(tokens[1]); sdi->version = g_strdup(tokens[3]); devc = g_malloc0(sizeof(struct dev_context));