public void SetCommunicatorLayer(ICommunicationLayer c) { if (m_communicator != null) { m_communicator.RemoveListener(this); } m_communicator = c; if (m_communicator != null) { m_communicator.AddListener(this); } }
public void OnDataArrived(ICommunicationLayer layer, CommunicationData d) { foreach (var m in m_motorConnectors) { if (!m.Value.IsConnected()) { continue; } foreach (var data in d.Data) { if (m.Value.GetSourceJoint() == data.name) { _listeners.ForEach(p => p.OnDataReceived(this, d.TargetName, m.Value.GetTargetJoint(), data.values)); } } } }
public void OnClosed(ICommunicationLayer l) { }
public void OnSchemeChanged(ICommunicationLayer layer, List <string> names) { }