Hi, here [1] is an updated version of the patch and some other featues for the HMC804x series and PPS in general:
- Over-current protection / fuse delay feature for PPS - OCP delay support for R&S HMC8043 - Support for R&S HMC8042 Best regards Marc [1] https://gitlab.zapb.de/zapb/libsigrok/-/commits/pps_hmc804x On Sun, 2023-04-16 at 10:53 +0200, Marc Schink wrote: > From 8f36c47d427ec073bbb6ccde02a584061a9a9406 Mon Sep 17 00:00:00 > 2001 > From: Marc Schink <d...@zapb.de> > Date: Wed, 12 Apr 2023 07:13:55 +0200 > Subject: [PATCH] scpi-pps: Add support for R&S HMC8042 > > Signed-off-by: Marc Schink <d...@zapb.de> > --- > src/hardware/scpi-pps/profiles.c | 33 ++++++++++++++++++++++++++---- > -- > 1 file changed, 27 insertions(+), 6 deletions(-) > > diff --git a/src/hardware/scpi-pps/profiles.c b/src/hardware/scpi- > pps/profiles.c > index e947f744..b8101520 100644 > --- a/src/hardware/scpi-pps/profiles.c > +++ b/src/hardware/scpi-pps/profiles.c > @@ -1206,13 +1206,13 @@ static const struct scpi_command > philips_pm2800_cmd[] = { > ALL_ZERO > }; > > -static const uint32_t rs_hmc8043_devopts[] = { > +static const uint32_t rs_hmc804x_devopts[] = { > SR_CONF_CONTINUOUS, > SR_CONF_LIMIT_SAMPLES | SR_CONF_GET | SR_CONF_SET, > SR_CONF_LIMIT_MSEC | SR_CONF_GET | SR_CONF_SET, > }; > > -static const uint32_t rs_hmc8043_devopts_cg[] = { > +static const uint32_t rs_hmc804x_devopts_cg[] = { > SR_CONF_OVER_VOLTAGE_PROTECTION_ENABLED | SR_CONF_GET | > SR_CONF_SET, > SR_CONF_OVER_VOLTAGE_PROTECTION_ACTIVE | SR_CONF_GET, > SR_CONF_OVER_VOLTAGE_PROTECTION_THRESHOLD | SR_CONF_GET | > SR_CONF_SET, > @@ -1223,6 +1223,15 @@ static const uint32_t rs_hmc8043_devopts_cg[] > = > { > SR_CONF_ENABLED | SR_CONF_GET | SR_CONF_SET, > }; > > +static const struct channel_spec rs_hmc8042_ch[] = { > + { "1", { 0, 32.050, 0.001, 3, 4 }, { 0.001, 5, 0.001, 3, 4 }, > { 0, 0, 0, 0, 4 }, FREQ_DC_ONLY, NO_OVP_LIMITS, NO_OCP_LIMITS }, > + { "2", { 0, 32.050, 0.001, 3, 4 }, { 0.001, 5, 0.001, 3, 4 }, > { 0, 0, 0, 0, 4 }, FREQ_DC_ONLY, NO_OVP_LIMITS, NO_OCP_LIMITS }, > +}; > + > +static const struct channel_group_spec rs_hmc8042_cg[] = { > + { "1", CH_IDX(0), PPS_OVP, SR_MQFLAG_DC }, > + { "2", CH_IDX(1), PPS_OVP, SR_MQFLAG_DC }, > +}; > static const struct channel_spec rs_hmc8043_ch[] = { > { "1", { 0, 32.050, 0.001, 3, 4 }, { 0.001, 3, 0.001, 3, 4 }, > { 0, 0, 0, 0, 4 }, FREQ_DC_ONLY, NO_OVP_LIMITS, NO_OCP_LIMITS }, > { "2", { 0, 32.050, 0.001, 3, 4 }, { 0.001, 3, 0.001, 3, 4 }, > { 0, 0, 0, 0, 4 }, FREQ_DC_ONLY, NO_OVP_LIMITS, NO_OCP_LIMITS }, > @@ -1235,7 +1244,7 @@ static const struct channel_group_spec > rs_hmc8043_cg[] = { > { "3", CH_IDX(2), PPS_OVP, SR_MQFLAG_DC }, > }; > > -static const struct scpi_command rs_hmc8043_cmd[] = { > +static const struct scpi_command rs_hmc804x_cmd[] = { > { SCPI_CMD_SELECT_CHANNEL, "INST:NSEL %s" }, > { SCPI_CMD_GET_MEAS_VOLTAGE, "MEAS:VOLT?" }, > { SCPI_CMD_GET_MEAS_CURRENT, "MEAS:CURR?" }, > @@ -1695,13 +1704,25 @@ SR_PRIV const struct scpi_pps pps_profiles[] > = > { > .update_status = NULL, > }, > > + /* Rohde & Schwarz HMC8042 */ > + { "Rohde&Schwarz", "HMC8042", SCPI_DIALECT_UNKNOWN, 0, > + ARRAY_AND_SIZE(rs_hmc804x_devopts), > + ARRAY_AND_SIZE(rs_hmc804x_devopts_cg), > + ARRAY_AND_SIZE(rs_hmc8042_ch), > + ARRAY_AND_SIZE(rs_hmc8042_cg), > + rs_hmc804x_cmd, > + .probe_channels = NULL, > + .init_acquisition = NULL, > + .update_status = NULL, > + }, > + > /* Rohde & Schwarz HMC8043 */ > { "Rohde&Schwarz", "HMC8043", SCPI_DIALECT_UNKNOWN, 0, > - ARRAY_AND_SIZE(rs_hmc8043_devopts), > - ARRAY_AND_SIZE(rs_hmc8043_devopts_cg), > + ARRAY_AND_SIZE(rs_hmc804x_devopts), > + ARRAY_AND_SIZE(rs_hmc804x_devopts_cg), > ARRAY_AND_SIZE(rs_hmc8043_ch), > ARRAY_AND_SIZE(rs_hmc8043_cg), > - rs_hmc8043_cmd, > + rs_hmc804x_cmd, > .probe_channels = NULL, > .init_acquisition = NULL, > .update_status = NULL, _______________________________________________ sigrok-devel mailing list sigrok-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sigrok-devel