dmm = (struct dmm_info *)di;
- conn = NULL;
+ conn = dmm->conn;
serialcomm = dmm->serialcomm;
for (l = options; l; l = l->next) {
src = l->data;
sdi->conn = serial;
sdi->priv = devc;
dmm->channel_count = 1;
+ if (dmm->packet_parse == sr_brymen_bm86x_parse)
+ dmm->channel_count = BRYMEN_BM86X_DISPLAY_COUNT;
if (dmm->packet_parse == sr_eev121gw_3displays_parse) {
dmm->channel_count = EEV121GW_DISPLAY_COUNT;
dmm->channel_formats = eev121gw_channel_formats;
return SR_OK;
}
-#define DMM(ID, CHIPSET, VENDOR, MODEL, SERIALCOMM, PACKETSIZE, TIMEOUT, \
- DELAY, REQUEST, VALID, PARSE, DETAILS) \
+#define DMM_CONN(ID, CHIPSET, VENDOR, MODEL, \
+ CONN, SERIALCOMM, PACKETSIZE, TIMEOUT, DELAY, \
+ REQUEST, VALID, PARSE, DETAILS) \
&((struct dmm_info) { \
{ \
.name = ID, \
.dev_acquisition_stop = std_serial_dev_acquisition_stop, \
.context = NULL, \
}, \
- VENDOR, MODEL, SERIALCOMM, PACKETSIZE, TIMEOUT, DELAY, \
+ VENDOR, MODEL, CONN, SERIALCOMM, PACKETSIZE, TIMEOUT, DELAY, \
REQUEST, 1, NULL, VALID, PARSE, DETAILS, sizeof(struct CHIPSET##_info) \
}).di
+#define DMM(ID, CHIPSET, VENDOR, MODEL, SERIALCOMM, PACKETSIZE, TIMEOUT, \
+ DELAY, REQUEST, VALID, PARSE, DETAILS) \
+ DMM_CONN(ID, CHIPSET, VENDOR, MODEL, NULL, SERIALCOMM, PACKETSIZE, \
+ TIMEOUT, DELAY, REQUEST, VALID, PARSE, DETAILS)
+
SR_REGISTER_DEV_DRIVER_LIST(serial_dmm_drivers,
/*
* The items are sorted by chipset first and then model name.
NULL
),
/* }}} */
+ /* bm86x based meters {{{ */
+ DMM_CONN(
+ "brymen-bm86x", brymen_bm86x, "Brymen", "BM86x",
+ "hid/bu86x", NULL, BRYMEN_BM86X_PACKET_SIZE, 1500, 500,
+ sr_brymen_bm86x_packet_request,
+ sr_brymen_bm86x_packet_valid, sr_brymen_bm86x_parse,
+ NULL
+ ),
+ /* }}} */
/* dtm0660 based meters {{{ */
DMM(
"peaktech-3415", dtm0660,