Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [milo-dev] Read out Data with Milo

Hi Simon,

readValue() returns a CompletableFuture. Call its method get(), and it returns the object of desire (in this case DataValue). I would recommend to read about the CompletableFuture interface. It is used extensively in the milo project. Just google it, there are many tutorials explaining it.

Mads

On Fri 1. Jun 2018 at 15:09, Simon Felderer <simon-felderer@xxxxxxxxxx> wrote:

Hey guys, 

if I am using the Code of the Blog OPC UA solutions with Eclipse Milo, and I am trying to read out the value of  a Node ID choosen, I always get as a result something like: java.util.concurrent.CompletableFuture@753436a5[Completed normally]


Does anybody know how I can get the real value of that specific NodeID? 

My Code is the same as in OPC UA solutions from Jens: 

NodeId nodeIdString = new NodeId(1, "PLC.Manufacturere");

CompletableFuture<org.eclipse.milo.stack.core.types.buildin.DataValue> value = client.readValue(0,TimestampsToReturn.Both, nodeIdString);


Thank you! 



_______________________________________________
milo-dev mailing list
milo-dev@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/milo-dev

Back to the top