LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Brookfield Viscometer serial communication error

   I'm working with a Brookfield DVPro+-II Viscometer.  It sends data over a serial port once every n seconds.  Fairly simple.  My program works find - most of the time.  Every once in a while, the viscometer appears to send out a garbled message.  A regular data frame might look like:
 RPM=0.0 M=RV    S=04 %=0.0   cP=0.00   D/CM2=0.00  1/SEC=0.000 T=23.6C  Z00:01
A corrupt frame can look like:
 RPM=0.0 M=RV    S=04 %=0.0   cP=0.00  MD=C.20 .10S C/0E0=0.T02 .=C3 ZC0:00
Often, it will have a lot of the correct characters, along with some random ones, but with a lot of transposition.  This often happens after the program has been running for about an hour.  Not exactly an hour.  And a few times I saw it after only a few minutes.
   The code runs for a long time without problems, so is it possible that this is a problem with LabVIEW, VISA, or my code?  As a software developer, my first reaction is always to blame the hardware.  I've been wrong in that regard too often, so I'm pretty cautious about doing that.  But I can't fathom any reason how this could be in software and not in hardware.  Also, it appears to happen on the client's computer as well.  (2000 miles away, so diagnostics are limited, but he gets the same symptoms.)  Different viscometer, different cabling, different computer.  We are both using USB-to-serial adapters...
   Any potential explanations or similar observations would be appreciated.

Regards,
   Dave T.
-------------------------------------------------------------
David Thomson Original Code Consulting
www.originalcode.com
National Instruments Alliance Program Member
Certified LabVIEW Architect
Certified Embedded Systems Developer
-------------------------------------------------------------
There are 10 kinds of people: those who understand binary, and those who don't.
0 Kudos
Message 1 of 14
(5,998 Views)
Hi Dave,

For what it's worth, did you try the same experiment with your driver using a machine that has a conventional serial port?  (Without the USB adapter)  Sometimes I've seen whacky results using those USB to serial adapters - I won't buy the cheap ones anymore.  If it's not the USB adapter, then I sure can't think of anything else.

I hope that helps...

Jim


0 Kudos
Message 2 of 14
(5,993 Views)

Dear Dave,

 

I wanted to know if you could provide a copy of the your labview VI?  I plan to have a student put together a system to control a Brookfield CAP 2000+ viscometer for my teaching lab.  As they are working on it, I can have them look this anomaly...

 

I have seen issues with Labview where, on the front panel, the thermocouple readings would drop to zero and then go back to the real value, but you didn't see problems when looking at the raw data.

 

When I had a Ohaus scale connected via a serial port, I saw the values every once in a while go to zero on the front panel, and this would be seen in the data.  I think it's a software issue, not hardware...  

 

Take care!!!

 

Wilson Terrell Jr.

Associate Professor

Dept. of Engineering Science 

Trinity University, San Antonio 

0 Kudos
Message 3 of 14
(5,631 Views)

I made this program to get data from two viscometers.

I have done a new version, but i have in the office computer.

 

Best

 

CPalha

0 Kudos
Message 4 of 14
(5,458 Views)

Hi all,

 

I am a new user of labview and I have to make a program to see the viscosity from Brookfield viscometer DVII+. I have tried your program cpalha but I have always a timeout error. What can be my error?

Thanks in advance,

 

Suneitos

0 Kudos
Message 5 of 14
(5,086 Views)

Dear Suneitos

 

Did you configure the time for print interval in viscometer? How much is it?

If it is 30 secounds for example in the labview program you must input in printinterval window 30000 ms.

 

Another tip is in the windows at top right I think has 10000 it is related with port COM configurations.

What COM port are you using? What the configurations?

 

You need to see it. Ask for help if you want again.

 

Best

 

CPalha 

0 Kudos
Message 6 of 14
(5,072 Views)

Dear CPalha,

 

Thank you for your quick answer. I have checked the timeout and set it at 10sec. Now i have error 1073807343 : what is your IVI drivers configuration? (cf: http://digital.ni.com/public.nsf/allkb/8130049893D6461E86256F3B00461E1B)

I use COM1 with the configuration in attached file.

 

Regards,

 

Suneitos

 

0 Kudos
Message 7 of 14
(5,060 Views)

Suneitos

 

Did you see what COM port configuration you have in the Brookfield menu? Must be the same has in the computer.

 

Do you use a rs232 ubs converter? What COM port the computer named it? Normally the computer attributes COM port 12, or 13 or 14 for this cables.

 

Best

 

CPalha

0 Kudos
Message 8 of 14
(5,041 Views)

Hi,

 

My configuration was good. the only problem was that i had no procedure to follow and i didn't know how to send data from the viscometer to the computer. Now it's OK, I had just to press for 3sec the button "Print". I believed that it was just for the parralel port. 2 days to find this tip. 🙂

Thank you for your help.

 

Suneitos

0 Kudos
Message 9 of 14
(5,026 Views)

Dave,

 

So this incorrect data only occurs in a single, isolated transmission; then the following transmissions are correct until the isolated incident briefly occurs again, correct?

 

Is there any way you can post the code in which you are seeing this incorrect data? Off the top of my head I can't imagine what might be causing the issue. My initial reaction was that this may be similar to problems encountered when trying to implement software handshaking using binary data transmission. But this would typically cause a data transmission failure entirely, not send incorrect data. Have you tried using the VISA examples that ship with LV? You would probably have to modify them a bit, but creating a very basic program with minimal functionality might help eliminate the possibility that it is a problem with your code.

 

Chris G

Applications Engineer
National Instruments
0 Kudos
Message 10 of 14
(5,014 Views)