VDTRead2 - how to skip incoming data

Dear all,

I am using VDTRead2 to read a two column, comma-separated stream from an arduino into two Igor Pro waves (wave0, wave1 in my case).

The problem is, each time I make a measurement using a sensor attached to the arduino, there is some noise that I would like to skip before loading the datastream that follows into Igor.

Is there a way to do this using the VDTRead2 command?

Thanks for any help.

RJS
Quote:
The problem is, each time I make a measurement using a sensor attached to the arduino, there is some noise that I would like to skip before loading the datastream that follows into Igor.


This is not specific enough to give a specific answer.

If you know the number of bytes of "noise" then use VDTReadBinary to skip that number of bytes.

Otherwise it may be more complicated - it depends on the precise nature of the noise.
hrodstein wrote:
Quote:
The problem is, each time I make a measurement using a sensor attached to the arduino, there is some noise that I would like to skip before loading the datastream that follows into Igor.


This is not specific enough to give a specific answer.

If you know the number of bytes of "noise" then use VDTReadBinary to skip that number of bytes.

Otherwise it may be more complicated - it depends on the precise nature of the noise.



Dear HRodstein,
Thanks for responding. I am currently dumping (VDTRead2) the first 50 points of my datastream into two separate waves before starting to collect the rest of the datastream into wave0 and wave1. Your suggestion will likely work better.
RJS
Quote:
I am currently dumping (VDTRead2) the first 50 points of my datastream into two separate waves before starting to collect the rest of the datastream into wave0 and wave1. Your suggestion will likely work better.


My suggestion will work only if you know the total number of bytes to skip which will be the case if each of the 50 numbers has the same number of characters.

Another approach is to do VDTReadWave into a wave with 50 points. Then kill the wave. Or read into a free wave which Igor will automatically kill.

But I think your solution of explicitly reading and ignoring 50 values is just as good.