Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA

Solved!
Go to solution

The data have different values at the same time.

Can anybody help me out?

I want to store data as a set of data points with corresponding timestamps.

mb030216_1-1683224217538.png

 

 

0 Kudos
Message 1 of 25
(1,181 Views)

As far as I can see, you are not logging the measurement time yourself and I think it is also not coming from the instrument.

If you measure the system time with tickcount  and use each timestamp to report to the table you get a timestamp.

Only thing you need to do is to keep the first timestamp in a shift register and subtract it from all timestamps before stopping the loop, or just after the loop.

 

The your time series start at zero.

If you need help for this, just ask and I will program a small example.

greetings from the Netherlands
0 Kudos
Message 2 of 25
(1,165 Views)

I don't get it. Can you give an example?

Thank you so much.

0 Kudos
Message 3 of 25
(1,138 Views)

Hi

Maybe you can remove the date time in the beginning.

I added a time at the end.

 

Have a nice time

greetings from the Netherlands
0 Kudos
Message 4 of 25
(1,104 Views)

I typed the wrong requirement.What I need is a data corresponding to different time.

0 Kudos
Message 5 of 25
(1,089 Views)

How fast are you measuring. This should have a resolution of milliseconds.

I replaced time in seconds by tick count in ms.

greetings from the Netherlands
0 Kudos
Message 6 of 25
(1,084 Views)

After the test, the following situation still occurs.

Where am I using it wrong?

 

mb030216_0-1683375715697.png

 

0 Kudos
Message 7 of 25
(1,081 Views)

Hi

You are measuring so fast that ms resolution does not work.

I also tried to be sure that the first measured time was zero but I think that opening the file the first time takes a lot of time, relative to measuring.

So do only aggregate measurements in the loop and wait at least 1 ms. 

Save the data to a file after the loop and make sure not to have to much data so e.g. stop at 1000 iterations.

greetings from the Netherlands
0 Kudos
Message 8 of 25
(1,077 Views)

OK.I really appreciate your help in resolving the problem.

0 Kudos
Message 9 of 25
(1,063 Views)

Hi

Can you send me one of the strings you are reading with VISA.

Just to look at your string to value conversion.

Or even better is there a manual I can read?

 

How much time do you want to measure. We can also limit the reading to once per ms if that is sufficient.

greetings from the Netherlands
0 Kudos
Message 10 of 25
(1,054 Views)