private void Start() { requested_rate = 30; if (!internalFlag) { _modalityEnabled = false; Debug.Log($"Started {modalityName} modality setter"); var driverSuccess = (bool)initModality.Invoke(client, new object[0]); if (driverSuccess) { Debug.Log($"{modalityName} Modality opened successfully"); } else { Debug.Log($"{modalityName} Modality failed to open"); } } else { Debug.Log($"Started {modalityName} modality setter in internal mode"); } Debug.Log($"{modalityName} Human Modality opened successfully"); bool isinterval = false; var openModality = new OpenModalityProto { ModalityName = modalityName, Fps = 30, }; var transportSuccess = AnimusClient.AnimusClient.OpenModality(robotID, openModality); if (transportSuccess.Success) { Debug.Log($"{modalityName} Transport Modality opened successfully"); _modalityEnabled = true; getModalityFPS = new FpsLag(modalityName, fpsinterval, "end of update to end of update"); } else { Debug.Log("Open modality error: " + transportSuccess.Description); } if (!internalFlag) { StartCoroutine(SetterCoroutine()); } }
private void Start() { if (!internalFlag) { Debug.Log($"Started {modalityName} modality sampler"); var driverSuccess = (bool)initModality.Invoke(client, new object[0]); if (driverSuccess) { Debug.Log($"{modalityName} Modality opened successfully"); } else { Debug.Log($"{modalityName} Modality failed to open"); } } else { Debug.Log($"Starting {modalityName} in internal mode"); } Debug.Log($"{modalityName} Human Modality and sampler thread opened successfully"); var openModality = new OpenModalityProto { ModalityName = modalityName, Fps = 30, }; var transportSuccess = AnimusClient.AnimusClient.OpenModality(robotID, openModality); if (transportSuccess.Success) { Debug.Log($"{modalityName} Transport Modality opened successfully"); _modalityEnabled = true; setModalityFPS = new FpsLag(modalityName, 30, "set modality"); } else { Debug.Log("Open modality error: " + transportSuccess.Description); } }