public void GetMainAntTest() { trans1 = new Transceiver(); AntConfig atcfg1=new AntConfig(); AntConfig atcfg2 = new AntConfig(); AntConfig atcfg3 = new AntConfig(); atcfg1.IsMainAnt = false; atcfg2.IsMainAnt = false; atcfg3.IsMainAnt = true; trans1.addAntConfig(atcfg1); trans1.addAntConfig(atcfg2); trans1.addAntConfig(atcfg3); Assert.AreEqual(atcfg3, Tool.GetMainAnt(trans1)); }
public void Init() { matrix = new TrueFalseMatrix(10, 10, 0.0, 10.0, 1, true); cell = new MockCell(); termianl = new Terminal(); //termianl.Gain = 3f; CsService = new UnionCsService(); CsService.BodyLoss = 5f; PsService = new UnionPsService(); PsService.BodyLoss = 5f; AntConfig1 = new AntConfig(); AntConfig1.IsMainAnt = true; AntConfig1.DlTotalLoss = 6f; AntConfig1.IsUserInput = false; AntConfig1.Feeder = new FeederEquipment(); tran = new Transceiver(); site = new Site(); site.Equipment = new BtsEquipment(); site.Equipment.NoiseFigure = 4f; site.X = 1; site.Y = 1; tran.Parent = site; tran.addAntConfig(AntConfig1); cell.Parent = tran; LinkLossAssist.Init(); }
public void Init() { IProject project = new MockProject(); ProjectSingleton.CurrentProject = project; IGeoProvider Geo = new MockGeoProvider(); ProjectSingleton.CurrentProject.AppContext.RegisterService(Geo); m_Target = new CalcCellToCellLinkLoss(ProjectSingleton.CurrentProject.AppContext); m_CellFrom = new MockIACell(); m_CellTo = new MockIACell(); FrequencyBand fromBand = new FrequencyBand(); fromBand.DLFrequency = 900; m_CellFrom.FreqBand = fromBand; Transceiver fromParent = new Transceiver(); IASite fromSite = new Site(); fromSite.X = 0; fromSite.Y = 0; fromParent.setParent(fromSite); //List<AntConfig> fromConfigs = new List<AntConfig>(); AntConfig fromConfig1 = new AntConfig(); fromConfig1.OutdoorAntenna = new AntennaEntity(); fromConfig1.AntType = 1; fromConfig1.Height = 30; fromConfig1.SectorID = 0; //fromConfigs.Add(fromConfig1); fromParent.addAntConfig(fromConfig1); m_CellFrom.setParent(fromParent, m_CellFrom); FrequencyBand toBand = new FrequencyBand(); toBand.DLFrequency = 905; m_CellTo.FreqBand = toBand; Transceiver toParent = new Transceiver(); IASite toSite = new Site(); toSite.X = 4; toSite.Y = 3; toParent.setParent(toSite); AntConfig toConfig = new AntConfig(); toConfig.OutdoorAntenna = new AntennaEntity(); toConfig.AntType = 1; toConfig.Height = 25; toConfig.SectorID = 0; toParent.addAntConfig(toConfig); m_CellTo.setParent(toParent, m_CellTo); }
private static void InitCell(out IACell cell1, out IACell cell2) { cell1 = new MockACell(); cell1.ID = 1; FrequencyBand Fre1 = new FrequencyBand(); Fre1.DLFrequency = 900; cell1.FreqBand = Fre1; Transceiver Trans1 = new Transceiver(); IASite Site1 = new Site(); Site1.X = 0; Site1.Y = 0; ((Site)Site1).Equipment = new BtsEquipment(); Trans1.setParent(Site1); AntConfig Ant1 = new AntConfig(); Ant1.OutdoorAntenna = new AntennaEntity(); Ant1.AntType = 1; Ant1.Height = 25; Ant1.SectorID = 0; Ant1.IsMainAnt = true; Trans1.addAntConfig(Ant1); cell1.setParent(Trans1, cell1); cell2 = new MockACell(); cell2.ID = 2; FrequencyBand Fre2 = new FrequencyBand(); Fre2.DLFrequency = 925; cell2.FreqBand = Fre2; Transceiver Trans2 = new Transceiver(); IASite Site2 = new Site(); Site2.X = 10; Site2.Y = 10; ((Site)Site2).Equipment = new BtsEquipment(); Trans2.setParent(Site2); AntConfig Ant2 = new AntConfig(); Ant2.OutdoorAntenna = new AntennaEntity(); Ant2.AntType = 1; Ant2.Height = 25; Ant2.SectorID = 0; Ant2.IsMainAnt = true; Trans2.addAntConfig(Ant2); cell2.setParent(Trans2, cell2); }
private void GetAntConfig(Transceiver cell) { cell.addAntConfig(cell.AntConfiguration[0]); //cell.set_AntSetUp(cell.get_AntConfiguration()[0]); }