-
Notifications
You must be signed in to change notification settings - Fork 263
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature Request - examples for all examples. #310
Comments
The examples are code examples not apps which are ready to use. I would guess that the value you are trying to write is a float value but the code in See https://github.com/gopcua/opcua/blob/master/examples/write/write.go#L40-L43 |
Understood, so the string type conversion has to match the value type for the opc ua tag. I eventually, used the following with good result.
Then it worked. |
Thank you for uploading all the code examples a month ago. I know this issue is closed but I was wondering why half of the server example code is commented it out. Is it because it's a work in progress code? |
The server code is on a branch developed by @dwhutchinson but has been stale for a while. Right now we don’t have a working OPC/UA server. |
Understood, I was just trying to integrate this to the influxdata platform. I’ve already submitted a simple OPC ua client |
Not an issue, but I'm wanted to have more examples of the examples. I'm able to apply most of the examples but some are coming back with errors and I think it's just way I'm applying the code.
For instance, I'm able to read a tag value just fine.
Command:
C:\GoProjects\src\github.com\gopcua\opcua> go run examples/read/read.go -endpoint opc.tcp://localhost:49380 -node 'ns=2;s=root.PS1.DB101:REAL:66'
Answer:
3
But I'm stuck when wanting to write to this tag. I appears that we need the tag identifier ID number not the actual tag name.
Command:
C:\GoProjects\src\github.com\gopcua\opcua> go run examples/write/write.go -endpoint opc.tcp://localhost:49380 -node 'ns=2;s=root.PS1.DB101:REAL:66' -value '4.2'
Answer:
The value supplied for the attribute is not of the same type as the attribute's value. StatusBadTypeMismatch (0x80740000)
As a result, can someone add example codes for all the example codes?
The text was updated successfully, but these errors were encountered: