def __init__(self, access_specifier=0, access_profile=None): self.access_specifier = access_specifier self.access_profile = access_profile Validatable.__init__(self) File.__init__(self, SystemFileIds.ACCESS_PROFILE_0.value + access_specifier, 65)
def __init__(self, d7a_protocol_version_major=0, d7a_protocol_version_minor=0, application_name="", git_sha1=""): self.d7a_protocol_version_major = d7a_protocol_version_major self.d7a_protocol_version_minor = d7a_protocol_version_minor self.application_name = application_name self.git_sha1 = git_sha1 Validatable.__init__(self) File.__init__(self, SystemFileIds.FIRMWARE_VERSION.value, 15)
def __init__(self, up_time=0, rx_time=0, tx_time=0, tx_duty_cycle=0, channel_status_list_length=0, channel_status_identifier=[], channel_noise_floor=[]): self.up_time = up_time self.rx_time = rx_time self.tx_time = tx_time self.tx_duty_cycle = tx_duty_cycle self.channel_status_list_length = channel_status_list_length self.channel_status_identifier = channel_status_identifier if len(channel_status_identifier) != channel_status_list_length: self.channel_status_identifier.extend( [ChannelStatusIdentifier()] * (channel_status_list_length - len(channel_status_identifier))) self.channel_noise_floor = channel_noise_floor if len(channel_noise_floor) != channel_status_list_length: self.channel_noise_floor.extend( [0] * (channel_status_list_length - len(channel_noise_floor))) File.__init__(self, SystemFileIds.PHY_STATUS.value, 15 + (3 * 10)) # allocate enough space for 20 channels Validatable.__init__(self)
def __init__(self, file_id, length=0, data=None, name="NotImplemented"): self.length = length if data is not None: self.data = data else: self.data = [0] * length self.name = name File.__init__(self, file_id, length)
def __init__(self, gain=0, rx_bw_low_rate=10468, rx_bw_normal_rate=78646, rx_bw_high_rate=125868, bitrate_lo_rate=9600, fdev_lo_rate=4800, bitrate_normal_rate=55555, fdev_normal_rate=50000, bitrate_hi_rate=166667, fdev_hi_rate=41667, preamble_size_lo_rate=5, preamble_size_normal_rate=5, preamble_size_hi_rate=7, preamble_detector_size_lo_rate=3, preamble_detector_size_normal_rate=3, preamble_detector_size_hi_rate=3, preamble_tol_lo_rate=15, preamble_tol_normal_rate=10, preamble_tol_hi_rate=10, rssi_smoothing=8, rssi_offset=0, lora_bw=125000, lora_SF=9, gaussian=2, paramp=40): self.gain = gain self.rx_bw_low_rate = rx_bw_low_rate self.rx_bw_normal_rate = rx_bw_normal_rate self.rx_bw_high_rate = rx_bw_high_rate self.bitrate_lo_rate = bitrate_lo_rate self.fdev_lo_rate = fdev_lo_rate self.bitrate_normal_rate = bitrate_normal_rate self.fdev_normal_rate = fdev_normal_rate self.bitrate_hi_rate = bitrate_hi_rate self.fdev_hi_rate = fdev_hi_rate self.preamble_size_lo_rate = preamble_size_lo_rate self.preamble_size_normal_rate = preamble_size_normal_rate self.preamble_size_hi_rate = preamble_size_hi_rate self.preamble_detector_size_lo_rate = preamble_detector_size_lo_rate self.preamble_detector_size_normal_rate = preamble_detector_size_normal_rate self.preamble_detector_size_hi_rate = preamble_detector_size_hi_rate self.preamble_tol_lo_rate = preamble_tol_lo_rate self.preamble_tol_normal_rate = preamble_tol_normal_rate self.preamble_tol_hi_rate = preamble_tol_hi_rate self.rssi_smoothing = int(ceil(log(rssi_smoothing, 2))) - 1 self.rssi_offset = rssi_offset self.lora_bw = lora_bw self.lora_SF = lora_SF self.gaussian = gaussian self.paramp = paramp File.__init__(self, SystemFileIds.FACTORY_SETTINGS.value, 56) Validatable.__init__(self)
def __init__(self, active_access_class=0, lq_filter=0x00, nf_ctrl=0x00, rx_nf_method_parameter=0x00, tx_nf_method_parameter=0x00): self.active_access_class = active_access_class self.lq_filter = lq_filter self.nf_ctrl = nf_ctrl self.rx_nf_method_parameter = rx_nf_method_parameter self.tx_nf_method_parameter = tx_nf_method_parameter File.__init__(self, SystemFileIds.DLL_CONFIG.value, 7) Validatable.__init__(self)
def __init__(self, last_rx_packet_level=0, last_rx_packet_link_budget=0, noise_floor=0, channel_header=ChannelHeader(channel_coding=ChannelCoding.FEC_PN9, channel_band=ChannelBand.BAND_868, channel_class=ChannelClass.LO_RATE), channel_index=0, scan_timeout_ratio=0, scan_count=0, scan_timeout_count=0): self.last_rx_packet_level=last_rx_packet_level self.last_rx_packet_link_budget=last_rx_packet_link_budget self.noise_floor=noise_floor self.channel_header=channel_header self.channel_index=channel_index self.scan_timeout_ratio=scan_timeout_ratio self.scan_count=scan_count self.scan_timeout_count=scan_timeout_count File.__init__(self, SystemFileIds.DLL_STATUS.value, 16) Validatable.__init__(self)
def __init__(self, mode=EngineeringModeMode.ENGINEERING_MODE_MODE_OFF, flags=0, timeout=0, channel_id=ChannelID(channel_header=ChannelHeader( ChannelCoding.PN9, ChannelClass.LO_RATE, ChannelBand.BAND_868), channel_index=0), eirp=0): self.mode = mode self.flags = flags self.timeout = timeout self.channel_id = channel_id self.eirp = eirp File.__init__(self, SystemFileIds.ENGINEERING_MODE, 9) Validatable.__init__(self)
def __init__(self, interface_configuration=InterfaceConfiguration(interface_id=InterfaceType.D7ASP, interface_configuration=None), file_id=0x1D): self.interface_configuration = interface_configuration if interface_configuration.interface_id == InterfaceType.D7ASP: File.__init__(self, file_id, 13) elif interface_configuration.interface_id == InterfaceType.LORAWAN_OTAA: File.__init__(self, file_id, 36) elif interface_configuration.interface_id == InterfaceType.LORAWAN_ABP: File.__init__(self, file_id, 44) Validatable.__init__(self)
def __init__(self, uid=0): self.uid = uid File.__init__(self, SystemFileIds.UID.value, 8) Validatable.__init__(self)
def __init__(self, access_specifier=0, access_profile=None): self.access_specifier = access_specifier self.access_profile = access_profile Validatable.__init__(self) File.__init__(self, SystemFileIds.ACCESS_PROFILE_0.value + access_specifier, 11)
def __init__(self, active_access_class=0, vid=0xFFFF): self.active_access_class = active_access_class self.vid = vid Validatable.__init__(self) File.__init__(self, SystemFileIds.DLL_CONFIG.value, 6)
def __init__(self, key=0): self.key = key Validatable.__init__(self) File.__init__(self, SystemFileIds.NWL_SECURITY_KEY.value, 16)
def __init__(self, file_id, length=0): self.length = length File.__init__(self, file_id, length)