]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/brymen-dmm/protocol.c
Constify sr_dev_driver::name and sr_dev_driver::long_name.
[libsigrok.git] / src / hardware / brymen-dmm / protocol.c
index 02e14d3198fd6e0a75bd6eba45160e8da8b102ab..4db460afd63c255fcdcd7f0edeb72e5cedd27517 100644 (file)
@@ -17,6 +17,7 @@
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 
+#include <config.h>
 #include "protocol.h"
 
 static void handle_packet(const uint8_t *buf, struct sr_dev_inst *sdi)
@@ -24,7 +25,7 @@ static void handle_packet(const uint8_t *buf, struct sr_dev_inst *sdi)
        float floatval;
        struct dev_context *devc;
        struct sr_datafeed_packet packet;
-       struct sr_datafeed_analog analog;
+       struct sr_datafeed_analog_old analog;
 
        devc = sdi->priv;
 
@@ -39,7 +40,7 @@ static void handle_packet(const uint8_t *buf, struct sr_dev_inst *sdi)
 
        if (analog.mq != -1) {
                /* Got a measurement. */
-               packet.type = SR_DF_ANALOG;
+               packet.type = SR_DF_ANALOG_OLD;
                packet.payload = &analog;
                sr_session_send(devc->cb_data, &packet);
                devc->num_samples++;