Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Error 1073807339 from Sartorius CP225D Labview control program

I'm trying to use RS232-to-USB to read from Sartorius analytic balance CP225D. I built a program using the Sartorius-SBI drivers from NI. 

However, whenever I run the program, it always gives the error 1073807339. Sometimes, I can obtain several correct measurement data and then it suddenly outputs error. 

 

Alternatively, we have been using the software called Winwedge (http://www.taltech.com/winwedge) to read data from the balance and it has actually been working. I'm working on the Labview program because I need to synchronize multiple instruments and Winwedge is not going to help with that. That said, I believe the program is not in the balance, and I've matched baud rate, parity, data bits and stop bits in each program. But it still doesn't work. 

 

Can anyone suggest what could be wrong?

 

Download All
0 Kudos
Message 1 of 7
(6,794 Views)
The initialize function should only be called once. Move it to the outside of the loop and try it.
0 Kudos
Message 2 of 7
(6,783 Views)

Hi, Dennis,

 

I moved the Initialize outside the loop. But I still got the same problem. It reads data correctly for a few seconds, and then it errored. Still the same error code.

Download All
0 Kudos
Message 3 of 7
(6,770 Views)
I don't know what else to try other than moving the filter function as well.
0 Kudos
Message 4 of 7
(6,761 Views)

The electronic balance is set to output data automatically. It seems there is no need to send command to the balance to ask for data.

I created a simple VISA communication program, removed VISA Write and used only VISA Read. I could read data from the port. However, it seems that the VISA is reading only in first in first out mode, while the balance output tons of data. Thus, the readout is always the initial value.

Is there a way to set it to last in first out mode? 

0 Kudos
Message 5 of 7
(6,726 Views)
Are you not getting the timeout any more? I just noticed with your previous post that you were getting the error on the write. That would indicate a problem with the handshaking. If the timeout error is gone, try doing a flush buffer before starting your read. You shouldn't have any wait inside the loop either.
0 Kudos
Message 6 of 7
(6,714 Views)

Thanks, Dennis, you are right. Removing the time wait inside the While loop will make the program work.

 

I'm posting my solution here in case other fellows encounter similar problems. 

 

Settings on the Sartorius CP225D:

Two settings from the default settings need to be changed: Communication mode needs to be changed to 551 (SBI), and printing mode to 614 (automatic without stability). Other settings remain factory default. 

 

Labview program is attached. 

Message 7 of 7
(6,691 Views)