LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

buffer problem?

Hello, 

 

For some reason my potentiostat program stops at random time intervals and then starts up again without popping up as an error. However, it switches the values while the experiment is running. 

 

For example, for the first test shown in this document, at 51 minutes it stops and resumes at 51.5 minutes but instead of potential to current to current exponent to ph, it executes potential twice and seems to mess up the order completely. 

 

We think it may be a buffer problem in case structure 1 within the flat sequence structure but are not sure how to fix this. We put probes after each read/error out and there aren't any errors but it just jumbles up our data, for instance VDATA would suddenly read the data of pHData and CDATA would read VData. 

 

If anyone can help me out that would be great! thanks!

Download All
0 Kudos
Message 1 of 48
(1,938 Views)

could it be a looping problem possibly??

0 Kudos
Message 2 of 48
(1,901 Views)

You might want to reconsider your program architecture a bit.

 

It sounds like one of your VISA read or write operations gets out of sync with the instrument.  Something like trying to write and read the response to READAUX while the instrument is still sending the response to READI.

 

Are there instrument drivers available for your GPIB device?  I think using a driver would simplify your code considerably.

0 Kudos
Message 3 of 48
(1,882 Views)

Hi jabano,

 

First, in order to look at the .vi, you need to include every sub.vi that is called as well. Also, you could just post a screenshot for us to get an idea of what's happening. To cover our bases, what version of LabVIEW are you using, what operating system and 32 or 64 bit for each?

Deborah Burke
Senior LabVIEW Product Manager
Certified LabVIEW Architect
National Instruments
0 Kudos
Message 4 of 48
(1,873 Views)

I have the NI-GPIB-USB-HS device and have the current driver installed. Do you suggest other ways i can make sure the operations are sent without bothering the other write - read? 

I'm currently using LabVIEW 7.0 , and am operating on a 64 bit computer, here is the complete program.

thanks

Download All
0 Kudos
Message 5 of 48
(1,844 Views)

Hi Jabano,

 

A few suggestions to try out here:

So far as architecture, an event structure should always be inside a while loop and it's usually good practice to avoid multiple nested loops/structures. The floating global variables on the far left need to be forced into some sequence, right now there is no way to tell when they're initialized, this could be causing some of the start/stop and read issues.

 

A good way to troubleshoot is to put the code in each structure into sub VI's to force execution order and clean it up, and in this way you can have smaller test VI's to walk through step-by-step and isolate the problem. Please include a bit more information about your application in order to suggest more architecture fixes. Also, Potential.vi wasn't included in the .zip.

 

Thank you,

 

Deborah Y.

Applications Engineer

National Instruments

 

Deborah Burke
Senior LabVIEW Product Manager
Certified LabVIEW Architect
National Instruments
0 Kudos
Message 6 of 48
(1,821 Views)

sorry for that, here's the potential.vi.

0 Kudos
Message 7 of 48
(1,813 Views)

1. we initialize the voltages, and the time intervals

2. the cell (device) turns on then the voltage is set (case structure 0)

3. Then there is a sequence stack which checks if the voltage needs to be changed -- after it reads the voltage, current then the pH while graphing and storing each value into a text document.

4. After this is done, it turns off and the experiment is finished. 

0 Kudos
Message 8 of 48
(1,809 Views)

Great, thank you for that, definitely try some of the suggested strategies and let me know how some of those issues are affected.

 

Deborah Y.

Deborah Burke
Senior LabVIEW Product Manager
Certified LabVIEW Architect
National Instruments
0 Kudos
Message 9 of 48
(1,807 Views)

The instrument we're using is called a potentiostat (model 263A) which controls voltage or current for experiments. 

0 Kudos
Message 10 of 48
(1,806 Views)