// Interface #region Interface //Note: If the user PC user the Global Proxy(IE Setup), this Function will fail public static bool startTCA(RunTimeError error, string addresss, string exePath = "") { try { #region ResvererCode tas = new ApplicationControl(addresss); string[] tsls = tas.GetTslList(); if (tsls.Length == 0) { tas.StartTsl(); tsls = tas.GetTslList(); if (tsls.Length == 0) { error.Errordescription = "Can not start TCA TSL"; return(false); } } tsl = new TslControlClient(tsls[0]); #endregion #region TCA StartParameter #endregion try { rumaClient = Tiger.Ruma.RumaControlClientFactory.CreateCustom(selectedCpriPorts, selectedTriggerPorts, rxPortBuffer, RxIqBandWidth, TxIqBandWidth, totalRxBufferSize, totalTxBufferSize, allocateAux, allocateDebugPort); } catch (System.Exception ex) { rumaClient = Tiger.Ruma.RumaControlClientFactory.CreateDefault(); } rCpriDataFlow = rumaClient.CpriDataFlow; rCarrierConfig = rumaClient.CarrierConfig; rCpriConfig = rumaClient.CpriConfig; rServerBase = rumaClient.PlatformUtilities; rTriggerConfig = rumaClient.TriggerConfig; rRULoader = rumaClient.OoM.RULoader; rDebugPortConfig = rumaClient.DebugPortConfig; } catch (System.Exception e) { error.Errordescription = "startTCA error : " + e.Message; return(false); } return(true); }
//rumaster stasrtup private void Rumasterswitchbutton_Click(object sender, EventArgs e) { // Connect the the TigerApplication service using a local or remote IP address tas = new ApplicationControl("127.0.0.1"); // Get a list with all started applications. If no application is running - start a new application string[] tsls = tas.GetTslList(); if (tsls.Length == 0) { tas.StartSpecifiedTsl(@"C:\Program Files\Ericsson\TCA\TSL.exe"); tsls = tas.GetTslList(); } // Get attached hardware devices tsl = new TslControlClient(tsls[0]); string[] hwSnrs = tsl.GetHws(); if (hwSnrs.Length == 0) { throw new Exception("No hardwares detected!"); } else { string[] uris = tsl.GetServiceList(ToolType.ID_RUMA); string toolUri; WriteTraceText("uris is :"+ uris.Length.ToString()); if (uris.Length == 1) { toolUri = uris[0]; } else if (uris.Length > 1) { toolUri = uris[uris.Length - 1]; } else { toolUri = tsl.StartService(ToolType.ID_RUMA, hwSnrs[0]); } this.rumaClient = RumaControlClientFactory.Create(toolUri); _TCA_ON = true; this.icdf = this.rumaClient.CpriDataFlow; this.rCarrierConfig = this.rumaClient.CarrierConfig; this.rCpriConfig = this.rumaClient.CpriConfig; this.rServerBase = this.rumaClient.PlatformUtilities; this.tag_rumaster.BackColor = Color.SpringGreen; this.rTriggerConfig = this.rumaClient.TriggerConfig; this.rIRULoader = this.rumaClient.OoM.RULoader; } // Retrieve all running tool services. If no tool service is running - start a new tool //RUMA instance created, now start tool must be executed and resource needs to be allocated. //rumaClient.RuMaUtilities.SetCustomStartupParametersVee(selectedCpriPorts, // trigger1, // trigger2, // trigger3, // trigger4, // rxPortBuffer, // rxIqBandWidth, // txIqBandWidth, // totalRxBufferSize, // totalTxBufferSize, // allocateAuxPort, // allocateDebugPort); }