08-01-2018 03:56 PM
Hello!
I have system that you can see on attached picture.
The problem zone is marked red.
In best case I got "0x0000 0x0000" string.
I think I must correctly select type of data.
I tried STRING, ARRAYS of U8,I8,U16,I16 but without result.
How can I define type of data and get data?
Thanks.
08-01-2018 04:36 PM
Where is your LabVIEW code? There is nothing attached for people to see how you programmed this.
08-06-2018 11:59 AM
Code is in the attachment.
08-06-2018 12:06 PM - edited 08-06-2018 12:06 PM
If you replace the numeric with a string and use the URL of this web-site, it would return the HTML for these discussion forums.
My point is you need to know what is on the other end associated with that URL to answer your question.
Ben
08-06-2018 03:20 PM
When I read 10 holding registers directly via Modbus/RTU (without the OPC server), I get 10 U16 words.
They include the following information:
reg1/reg2 reg3/reg4 reg5/reg6 reg7/reg8 reg9/reg10
selected measurement measurement min allowed max allowed
physical unit value of PMC1 status value value
Pair reg3/reg4 has float value.
Quote from programmers guide (EPHUM011):
'You cannot read selectively the registers 3 and 4 for the measurement value only. You have to read the
entire length of the command (10 registers) and extract the desired information."
When I read the same data via OPC, I get "0000 0000 0000 0000".
When I open the window of the OPC server, I see the picture I attached.
I.e. OPC server successfully read data, and they have type "string" (string of what?)
Question is: may be should I request type of data from OPC server, and then read that data in right format?
And how can I do that?
08-08-2018 11:25 AM
What output do you get if you don't specify the datatype at DataSocket Read? Or if you read it as a string? The data may be being parsed in a way that we're not expecting.
Nick
Applications Engineer
National Instruments
08-09-2018 03:16 PM
I collected a lot of variants. Silly variants is here too.
I uploaded 2 pics for every variant: VI and output of VI.
I attache ZIP file because count of the attachment in this forum are limited.
First two variants show that I can read something from my OPC server.
Other variants show that I can read not all from my OPC server yet 😞