Professional OPC
Development Tools

logos

Online Forums

Technical support is provided through Support Forums below. Anybody can view them; you need to Register/Login to our site (see links in upper right corner) in order to Post questions. You do not have to be a licensed user of our product.

Please read Rules for forum posts before reporting your issue or asking a question. OPC Labs team is actively monitoring the forums, and replies as soon as possible. Various technical information can also be found in our Knowledge Base. For your convenience, we have also assembled a Frequently Asked Questions page.

Do not use the Contact page for technical issues.

QuickOPC.NET Value Precision (rounding issue)

More
08 Jun 2011 05:15 #401 by support
R.,

Yes – VT_R4 has precision slightly above 6 significant digits. It explains the situation fully. The solution would be to use VT_R8 (or other suitable type) if the server supports it.

Best regards,
<span style="font-family: "Arial","sans-serif"; color: #1f497d; font-size: 10pt">Zbynek Zahradnik

Please Log in or Create an account to join the conversation.

More
08 Jun 2011 05:14 #400 by support
<span style="font-family: "Tahoma","sans-serif"; font-size: 10pt; mso-fareast-font-family: 'Times New Roman'">From:<span style="font-family: "Tahoma","sans-serif"; font-size: 10pt; mso-fareast-font-family: 'Times New Roman'"> R.
Sent: Tuesday, June 07, 2011 9:38 PM
To: Zbynek Zahradnik
Subject: RE: Data.NET Value Precision

Zbynek,

I just wanted to follow up on this and let you know that I think it has to do with what the OPC server is sending us- it’s sending a value in an exponential format (VT_R4 2.054319E+09) so it makes sense that the value is only being displayed as 2054319000. I tested with TOP Server and it retuned the full correct value.

R.

Please Log in or Create an account to join the conversation.

More
07 Jun 2011 12:42 #397 by support
<span style="font-family: "Tahoma","sans-serif"; font-size: 10pt; mso-fareast-font-family: 'Times New Roman'">From:<span style="font-family: "Tahoma","sans-serif"; font-size: 10pt; mso-fareast-font-family: 'Times New Roman'"> R,
Sent: Tuesday, June 07, 2011 2:37 PM
To: Zbynek Zahradnik
Subject: RE: Data.NET Value Precision

Thanks. I will do some testing and try to capture diagnostics.

R.

Please Log in or Create an account to join the conversation.

More
07 Jun 2011 12:41 #396 by support
R.,

The component is not supposed to do rounding. And I do not think it does it, but obviously I cannot rule out a bug, though it would be somewhat weird one.

<span style="font-family: "Arial","sans-serif"; color: #1f497d; font-size: 10pt">Zbynek Zahradnik

Please Log in or Create an account to join the conversation.

More
07 Jun 2011 12:41 #395 by support
<span style="font-family: "Tahoma","sans-serif"; font-size: 10pt; mso-fareast-font-family: 'Times New Roman'">From:<span style="font-family: "Tahoma","sans-serif"; font-size: 10pt; mso-fareast-font-family: 'Times New Roman'"> R.
Sent: Tuesday, June 07, 2011 2:04 PM
To: Zbynek Zahradnik
Subject: Data.NET Value Precision

Zbynek,

I have a customer who has told me the following. They have “an item with a value of 2050505728 in the server is reported in ItemChanged event as 2050506000. The value is rounded.” Is there a way to adjust the precision of the value?

I have not had an opportunity to test this myself to see if I see the same behavior. I can also capture diagnostics, if necessary to see exactly what is being passed to Data.NET, but I thought I would check with you to see if there was a quick property setting to solve this. I wasn’t able to find one that looked like it might work.

Thanks in advance,
R.

Please Log in or Create an account to join the conversation.

Moderators: support
Time to create page: 0.056 seconds