private async void relayNodeWatcher_Added(relaynodeWatcher sender, AllJoynServiceInfo args) { relaynodeJoinSessionResult joinResult = await relaynodeConsumer.JoinSessionAsync(args, sender); if (joinResult.Status == AllJoynStatus.Ok) { _relayNodeConsumer = joinResult.Consumer; _relayNodeConsumer.Signals.ButtonPressedReceived += Signals_ButtonPressedReceived; _relayNodeConsumer.Signals.RelayStateChangedReceived += Signals_RelayStateChangedReceived; RetrieveCurrentState(); _fReady = true; } else { Debug.WriteLine("Joining the session went wrong"); } }
public RelayNodeClient() { _relayNodeConsumer = null; _bus = new AllJoynBusAttachment(); StartWatcher(); }