07-27-2009 08:58 AM
Dear Sir, I have a question and kindly ask for help.
Our customer has requested for an existing data aquisition built (previously) using Visual C++ 6.0 the integration of Data of the NI OPC cFP-180x family .
I am trying to built an interface to change the range of the data item so that we do not open the MAX. When I check the attributes ot the data item (item meaning the channel itself after the host and server), I get the attributes Quality, timestamp, time high and time low.
Reason for that the client would like to configure (attributes existing in the MAX) using the Visual C++ 6.0 built interface is that control over the NI OPC would be consistently through one interface.
I have the feeling that this is not possible. But I lack experience in the CNI functionality.
Thank you for your help.
Monika
Cairo - Egypt
07-28-2009 05:16 PM
07-29-2009 03:32 AM
Dear Sir,
First sorry for my unclear question and below some clarifications:
* the client's existing Data aquisition is build using Visual C++ 6.0, this means that I have to use the Visual C++ supported by NI Measurement studio. Therefore I am using the CNI data sockets to access channel information readings (Amp, Volts, Boolean) and attributes.
* forgive me for my weak knowledge, about the National Instruments OPC Server; My channels are defined: "opc://localhost/National Instruments.OPCFieldPoint/FP @ 192_168_1_180\cFP-AI-111 @1\Channel 0"
I can read the reading or values of these channels from my client's Data Acquisition Visual C++ 6.0 program fine, I can even produce a chart and so on. I am managing fine with the reading.
Furthermore I have even managed to write to some channels using my client's Data Aquisition program (that has the NI measurement studio support along with new supporting code).
As I mentioned in my previous question I have the cFP-1808, I have or see the readings or values that come from this hardware visible in the Server Explorer, the Measurement and Automation, the Data Aquisition program.
My problem is wheter I can continue to buid in my client's Data Aquisition program an interface that could change the Range of say the "opc://localhost/National Instruments.OPCFieldPoint/FP @ 192_168_1_180\cFP-AI-111 @1\Channel 0" channel.
The change would be done by first reading the Range figures available in the the Measurement and Automation -> the channel configuration tab -> the Data Configuration -> Range combo box values
After the reading the Channel Data configuration (in this case Range) could be changed to another existing value and this value would be sent to the Hardware through the *.iak file.
I am not seeking the code, just an answer is this possible or not.
I have tried several CNI data socket functions to list attribute names, but I have not reached to Channel Data Configuration attributes. I have only reached attributes of : Quality and Time.
I am truely thankfull for any help and shall answer any item that is not clear in my text.
Monika
Cairo - Egypt
07-30-2009 12:33 PM