X-Git-Url: https://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Farachnid-labs-re-load-pro%2Fprotocol.h;h=fca1b9782cb98c354b61cb7b378257a87531237b;hb=7f0463840ab5d6a85daaa76850558d2b71e596cf;hp=225ee1c279d6a09493f9ceadbcf9c73d9a664789;hpb=a2172899517ab756ca765913d9957fc1f98e892b;p=libsigrok.git diff --git a/src/hardware/arachnid-labs-re-load-pro/protocol.h b/src/hardware/arachnid-labs-re-load-pro/protocol.h index 225ee1c2..fca1b978 100644 --- a/src/hardware/arachnid-labs-re-load-pro/protocol.h +++ b/src/hardware/arachnid-labs-re-load-pro/protocol.h @@ -30,19 +30,35 @@ #define RELOADPRO_BUFSIZE 100 struct dev_context { - gboolean acquisition_running; struct sr_sw_limits limits; + char buf[RELOADPRO_BUFSIZE]; int buflen; + + float current_limit; + float voltage; + float current; gboolean otp_active; gboolean uvc_active; + float uvc_threshold; + + gboolean acquisition_running; + GMutex acquisition_mutex; + + GCond current_limit_cond; + GCond voltage_cond; + GCond uvc_threshold_cond; }; SR_PRIV int reloadpro_set_current_limit(const struct sr_dev_inst *sdi, float current); SR_PRIV int reloadpro_set_on_off(const struct sr_dev_inst *sdi, gboolean on); +SR_PRIV int reloadpro_set_under_voltage_threshold(const struct sr_dev_inst *sdi, + float uvc_threshold); SR_PRIV int reloadpro_get_current_limit(const struct sr_dev_inst *sdi, - float *current); + float *current_limit); +SR_PRIV int reloadpro_get_under_voltage_threshold(const struct sr_dev_inst *sdi, + float *uvc_threshold); SR_PRIV int reloadpro_get_voltage_current(const struct sr_dev_inst *sdi, float *voltage, float *current); SR_PRIV int reloadpro_receive_data(int fd, int revents, void *cb_data);