]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/atten-pps3xxx/protocol.c
Constify a lot more items.
[libsigrok.git] / src / hardware / atten-pps3xxx / protocol.c
index 8e678a16867ea7024ec84c0e18a03cc6d00e64ce..34e0af42824ebff7fa13623c79e84bfb8ad93f9d 100644 (file)
  * along with this program.  If not, see <http://www.gnu.org/licenses/>.
  */
 
+#include <config.h>
 #include <string.h>
 #include "protocol.h"
 
-static void dump_packet(char *msg, uint8_t *packet)
+static void dump_packet(const char *msg, uint8_t *packet)
 {
        int i;
        char str[128];
@@ -36,13 +37,13 @@ static void handle_packet(const struct sr_dev_inst *sdi)
 {
        struct dev_context *devc;
        struct sr_datafeed_packet packet;
-       struct sr_datafeed_analog analog;
+       struct sr_datafeed_analog_old analog;
        float value, data[MAX_CHANNELS];
        int offset, i;
 
        devc = sdi->priv;
        dump_packet("received", devc->packet);
-       packet.type = SR_DF_ANALOG;
+       packet.type = SR_DF_ANALOG_OLD;
        packet.payload = &analog;
        analog.channels = sdi->channels;
        analog.num_samples = 1;