def __init__(self, idx, internal_id): Station.__init__(self, idx) self.number = internal_id """ Takes too long to instantiate all the stations, but the smartbike API does not give any useful information for starters.. :( """ self.update()
def __init__(self, idx, internal_id): Station.__init__(self, idx) self.number = internal_id """ Takes too long to instantiate all the stations, but the smartbike API does not give any useful information for starters.. :( """ self.update()
def __init__(self, station_id, x, y, network, p, pe, ge, scale): Station.__init__(self, station_id, x, y, scale) self.__bts_list = set() self.bts = None self.pref_network = network self.p = p self.pe = pe self.ge = ge self.dtx = random.choice((True, False)) self.__rxlev_dl = [] self.__rxlev_up = [] self.__rxqual_up = [] self.__rxqual_dl = [] self.__nb_means_rxlev_up = 0 self.__nb_means_rxlev_dl = 0 self.__nb_means_rxqual_up = 0 self.__nb_means_rxqual_dl = 0 self.__nb_means_distance = 0 self.__rxlev_up_mean = [] self.__rxlev_dl_mean = [] self.__rxqual_up_mean = [] self.__rxqual_dl_mean = [] self.__distanceMsBts_mean = {} self.__rxlev_ncell_mean = {} self.__nbsamples = -1 self.__nb_means = -1 self.__distanceMsBts = {} self.__rxlev_ncell = {} for aBts in self.__bts_list: self.__distanceMsBts[aBts] = [] self.__rxlev_ncell[aBts] = [] self.__bts_candidate = None self.__nb_request = 0 self.__bts_mutex = QtCore.QMutex() self.__last_move = random.randint(0, 7) self.__handover_timer = QtCore.QTimer() self.__handover_timer.timeout.connect(self.measure) self.set_speed(1) self.__start_timer = QtCore.QTimer() self.__start_timer.timeout.connect(self.__handover_timer.start) self.__start_timer.setSingleShot(random.randint(0, 480)) self.__start_timer.start()
def __init__(self, station_id, x, y, network, ho_margin, ms_txpwr_max, bts_txpwr_max, rxlev_min, max_ms_range, l_rxqual_h, l_rxlev_dl_h, l_rxlev_up_h, pe, ge, f, scale): Station.__init__(self, station_id, x, y, scale) self.ms_list = set() self.network = network self.ho_margin = ho_margin self.ms_txpwr_max = ms_txpwr_max self.bts_txpwr_max = bts_txpwr_max self.rxlev_min = rxlev_min self.max_ms_range = max_ms_range self.l_rxqual_h = l_rxqual_h self.l_rxlev_dl_h = l_rxlev_dl_h self.l_rxlev_up_h = l_rxlev_up_h self.pe = pe self.ge = ge self.f = f #log_range = (ge + pe)/20. + 6.628 - math.log10(f) #self.nominal_range = pow(10, log_range) / scale # TODO log_range = (-32.44 - 20 * math.log10(f) + ge + 105 + pe)/20 / 3 self.nominal_range = pow(10, log_range) * 1000 / scale
def __init__(self, idx, pfx): Station.__init__(self, idx) self.prefix = clean_string(pfx)
def __init__(self): Station.__init__(self,name='Earthside',location = 'Earthside') for i in ['Food','Water','General Consumables','Parts','Nitrogen','Brine','Solid Waste','Liquid Waste']: self.storage_avg_price[i] = 0 self.storage_tariff[i] = get_launch_cost()
def __init__(self, idx, prefix): Station.__init__(self,idx) self.prefix = prefix
def __init__(self, idx, prefix): Station.__init__(self, idx) self.prefix = prefix