Avatar

Please consider registering
guest

sp_LogInOut Log In sp_Registration Register

Register | Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

sp_Feed Topic RSS sp_TopicIcon
Error Read Value
March 28, 2014
8:16, EET
Avatar
bernd.parchmann
Member
Members
Forum Posts: 7
Member Since:
March 27, 2014
sp_UserOfflineSmall Offline

hi,

i am testing to connect with java to a beckhoff plc over the beckhoff opc ua/da server.

i connected to the server and i created one node. now i want to read the value. but i got errors:
error1:
com.prosysopc.ua.StatusException: (0x80000000) “” StatusCode= (0x80000000) “”
at com.prosysopc.ua.client.UaClient.a(Unknown Source)
at com.prosysopc.ua.client.UAClient.readAttribute(Unknown Source)
at com.prosysopc.ua.client.UAClient.readValue(Unknown Source)
at ClassName.main(ClassName.java:88)

error2:
com.prosysopc.ua.StatusException: Bad_DeviceFailure (0x808B0000) “There has been a failure in the device/data source that generates the value that has affected the value.”
at com.prosysopc.ua.client.UaClient.a(Unknown Source)
at com.prosysopc.ua.client.UAClient.readAttribute(Unknown Source)
at ClassName.main(ClassName.java:88)

My Code:


UaClient client;
String serverUri = “opc.tcp://localhost:4840”;
try
{
NodeId node = new NodeId(4, “GVL_Write.testBool”);

client = new UaClient(serverUri);
client.setSecurityMode(SecurityMode.NONE);
client.connect();

DataValue valueBrowseName = client.readAttribute(node, Attributes.BrowseName); // works
DataValue valueDataType = client.readAttribute(node, Attributes.DataType); // works
DataValue value1 = client.readValue(node); // error2
DataValue value2 = client.readAttribute(node, Attributes.Value); // error1

can anyone help me?

thx!

March 28, 2014
9:20, EET
Avatar
Jouni Aro
Moderator
Moderators
Forum Posts: 960
Member Since:
December 21, 2011
sp_UserOfflineSmall Offline

Sounds like there is a problem in the PLC / server. Use the Java Client to verify what data is valid and ensure that the PLC is providing the data correctly. The same data should work with your own application.

March 28, 2014
9:51, EET
Avatar
bernd.parchmann
Member
Members
Forum Posts: 7
Member Since:
March 27, 2014
sp_UserOfflineSmall Offline

thx for your reply.

i checked to connect to the opc server. i can connect to it and can see the nodes.
but in an opc ua client i get an error: the values are not readable.
in an opc da client i can read and write the values.

i think, there is an configuration error at the beckhoff plc site…

i try to find the issue!

Forum Timezone: Europe/Helsinki

Most Users Ever Online: 267

Currently Online:
13 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

hbrackel: 124

pramanj: 86

ibrahim: 74

rocket science: 65

kapsl: 57

Sabari: 51

gjevremovic: 49

Xavier: 43

fred: 41

TimK: 41

Member Stats:

Guest Posters: 0

Members: 1749

Moderators: 15

Admins: 1

Forum Stats:

Groups: 3

Forums: 15

Topics: 1323

Posts: 5649

Newest Members:

WalterFOUNC, datafastproxiespx01, LenkaLok, seoninet, justinevillanuev, namtrott5457, DonaldWibip, AlfredoEthix, andreidla, everangel7021

Moderators: Jouni Aro: 960, Otso Palonen: 32, Tuomas Hiltunen: 5, Pyry: 1, Petri: 0, Bjarne Boström: 860, Heikki Tahvanainen: 402, Jukka Asikainen: 1, moldzh08: 0, Jimmy Ni: 25, Teppo Uimonen: 21, Markus Johansson: 42, Niklas Nurminen: 0, Matti Siponen: 222, Lusetti: 0

Administrators: admin: 1