From: Uwe Hermann Date: Wed, 1 May 2013 01:16:47 +0000 (+0200) Subject: serial-dmm: Add Tecpel DMM-8060 support. X-Git-Tag: dsupstream~12 X-Git-Url: https://sigrok.org/gitaction?a=commitdiff_plain;h=c2fa697afa86a8e6f37bef13acb5b8532714274e;p=libsigrok.git serial-dmm: Add Tecpel DMM-8060 support. --- diff --git a/hardware/serial-dmm/api.c b/hardware/serial-dmm/api.c index b63d3fc9..a2738c68 100644 --- a/hardware/serial-dmm/api.c +++ b/hardware/serial-dmm/api.c @@ -53,6 +53,7 @@ SR_PRIV struct sr_dev_driver pce_pce_dm32_driver_info; SR_PRIV struct sr_dev_driver radioshack_22_168_driver_info; SR_PRIV struct sr_dev_driver radioshack_22_805_driver_info; SR_PRIV struct sr_dev_driver radioshack_22_812_driver_info; +SR_PRIV struct sr_dev_driver tecpel_dmm_8060_ser_driver_info; SR_PRIV struct sr_dev_driver tecpel_dmm_8061_ser_driver_info; SR_PRIV struct sr_dev_driver voltcraft_vc820_ser_driver_info; SR_PRIV struct sr_dev_driver voltcraft_vc840_ser_driver_info; @@ -144,6 +145,14 @@ SR_PRIV struct dmm_info dmms[] = { NULL, &radioshack_22_812_driver_info, receive_data_RADIOSHACK_22_812, }, + { + "Tecpel", "DMM-8060 (UT-D02 cable)", "2400/8n1/rts=0/dtr=1", + 2400, FS9721_PACKET_SIZE, NULL, + sr_fs9721_packet_valid, sr_fs9721_parse, + NULL, + &tecpel_dmm_8060_ser_driver_info, + receive_data_TECPEL_DMM_8060_SER, + }, { "Tecpel", "DMM-8061 (UT-D02 cable)", "2400/8n1/rts=0/dtr=1", 2400, FS9721_PACKET_SIZE, NULL, @@ -522,6 +531,7 @@ DRV(pce_pce_dm32, PCE_PCE_DM32, "pce-pce-dm32", "PCE PCE-DM32") DRV(radioshack_22_168, RADIOSHACK_22_168, "radioshack-22-168", "RadioShack 22-168") DRV(radioshack_22_805, RADIOSHACK_22_805, "radioshack-22-805", "RadioShack 22-805") DRV(radioshack_22_812, RADIOSHACK_22_812, "radioshack-22-812", "RadioShack 22-812") +DRV(tecpel_dmm_8060_ser, TECPEL_DMM_8060_SER, "tecpel-dmm-8060-ser", "Tecpel DMM-8060 (UT-D02 cable)") DRV(tecpel_dmm_8061_ser, TECPEL_DMM_8061_SER, "tecpel-dmm-8061-ser", "Tecpel DMM-8061 (UT-D02 cable)") DRV(voltcraft_vc820_ser, VOLTCRAFT_VC820_SER, "voltcraft-vc820-ser", "Voltcraft VC-820 (UT-D02 cable)") DRV(voltcraft_vc840_ser, VOLTCRAFT_VC840_SER, "voltcraft-vc840-ser", "Voltcraft VC-840 (UT-D02 cable)") diff --git a/hardware/serial-dmm/protocol.c b/hardware/serial-dmm/protocol.c index e2801a38..e573d1d5 100644 --- a/hardware/serial-dmm/protocol.c +++ b/hardware/serial-dmm/protocol.c @@ -170,6 +170,7 @@ RECEIVE_DATA(PCE_PCE_DM32, fs9721) RECEIVE_DATA(RADIOSHACK_22_168, metex14) RECEIVE_DATA(RADIOSHACK_22_805, metex14) RECEIVE_DATA(RADIOSHACK_22_812, rs9lcd) +RECEIVE_DATA(TECPEL_DMM_8060_SER, fs9721) RECEIVE_DATA(TECPEL_DMM_8061_SER, fs9721) RECEIVE_DATA(VOLTCRAFT_VC820_SER, fs9721) RECEIVE_DATA(VOLTCRAFT_VC840_SER, fs9721) diff --git a/hardware/serial-dmm/protocol.h b/hardware/serial-dmm/protocol.h index e7ea038f..aa0c512d 100644 --- a/hardware/serial-dmm/protocol.h +++ b/hardware/serial-dmm/protocol.h @@ -43,6 +43,7 @@ enum { RADIOSHACK_22_168, RADIOSHACK_22_805, RADIOSHACK_22_812, + TECPEL_DMM_8060_SER, TECPEL_DMM_8061_SER, VOLTCRAFT_VC820_SER, VOLTCRAFT_VC840_SER, @@ -50,7 +51,7 @@ enum { UNI_T_UT61E_SER, }; -#define DMM_COUNT 17 +#define DMM_COUNT 18 struct dmm_info { char *vendor; @@ -104,6 +105,7 @@ SR_PRIV int receive_data_PCE_PCE_DM32(int fd, int revents, void *cb_data); SR_PRIV int receive_data_RADIOSHACK_22_168(int fd, int revents, void *cb_data); SR_PRIV int receive_data_RADIOSHACK_22_805(int fd, int revents, void *cb_data); SR_PRIV int receive_data_RADIOSHACK_22_812(int fd, int revents, void *cb_data); +SR_PRIV int receive_data_TECPEL_DMM_8060_SER(int fd, int revents, void *cb_data); SR_PRIV int receive_data_TECPEL_DMM_8061_SER(int fd, int revents, void *cb_data); SR_PRIV int receive_data_VOLTCRAFT_VC820_SER(int fd, int revents, void *cb_data); SR_PRIV int receive_data_VOLTCRAFT_VC840_SER(int fd, int revents, void *cb_data); diff --git a/hwdriver.c b/hwdriver.c index e3116571..995d24fe 100644 --- a/hwdriver.c +++ b/hwdriver.c @@ -158,6 +158,7 @@ extern SR_PRIV struct sr_dev_driver pce_pce_dm32_driver_info; extern SR_PRIV struct sr_dev_driver radioshack_22_168_driver_info; extern SR_PRIV struct sr_dev_driver radioshack_22_805_driver_info; extern SR_PRIV struct sr_dev_driver radioshack_22_812_driver_info; +extern SR_PRIV struct sr_dev_driver tecpel_dmm_8060_ser_driver_info; extern SR_PRIV struct sr_dev_driver tecpel_dmm_8061_ser_driver_info; extern SR_PRIV struct sr_dev_driver voltcraft_vc820_ser_driver_info; extern SR_PRIV struct sr_dev_driver voltcraft_vc840_ser_driver_info; @@ -246,6 +247,7 @@ static struct sr_dev_driver *drivers_list[] = { &radioshack_22_168_driver_info, &radioshack_22_805_driver_info, &radioshack_22_812_driver_info, + &tecpel_dmm_8060_ser_driver_info, &tecpel_dmm_8061_ser_driver_info, &voltcraft_vc820_ser_driver_info, &voltcraft_vc840_ser_driver_info,