From a07d3063da8d07285e6af4d274beefd6b1742e20 Mon Sep 17 00:00:00 2001 From: Ben Meadors Date: Mon, 6 Dec 2021 16:48:08 -0600 Subject: [PATCH 1/4] Added link to example_config.yml --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index e88dfff..da1ba96 100644 --- a/README.md +++ b/README.md @@ -128,7 +128,7 @@ Writing modified channels to device ## Changing multiple settings from a yaml file -You can put parameters into a yaml file to update multiple values. See the example_config.yml. +You can put parameters into a yaml file to update multiple values. See the [example_config.yaml](example_config.yaml). This is how you might call it: ``` From b881ce4af5418e199c49254aaee2fb4589279d66 Mon Sep 17 00:00:00 2001 From: Jm Casler Date: Mon, 6 Dec 2021 16:09:03 -0800 Subject: [PATCH 2/4] updating proto submodule to latest --- proto | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/proto b/proto index 5a556ee..a05411d 160000 --- a/proto +++ b/proto @@ -1 +1 @@ -Subproject commit 5a556ee4a940d27761a41b43df5630d16ccaf728 +Subproject commit a05411df398d67aee668c366233ddfb88307698a From 163021de2a61caaf34cddb754b2434d5976b80cb Mon Sep 17 00:00:00 2001 From: Jm Casler Date: Mon, 6 Dec 2021 16:33:56 -0800 Subject: [PATCH 3/4] Add new channel configurations Create new default channel configurations. https://github.com/meshtastic/Meshtastic-device/issues/965 --- meshtastic/__main__.py | 20 ++++++++++++-- meshtastic/channel_pb2.py | 24 +++++++++++------ meshtastic/mesh_pb2.py | 51 ++++++++++++++++++++--------------- meshtastic/radioconfig_pb2.py | 41 ++++++++++++++++------------ 4 files changed, 87 insertions(+), 49 deletions(-) diff --git a/meshtastic/__main__.py b/meshtastic/__main__.py index ee76914..d765aff 100644 --- a/meshtastic/__main__.py +++ b/meshtastic/__main__.py @@ -428,14 +428,14 @@ def onConnected(interface): print(f"Deleting channel {channelIndex}") ch = getNode().deleteChannel(channelIndex) - if args.ch_set or args.ch_longslow or args.ch_shortfast: + if args.ch_set or args.ch_longslow or args.ch_longsfast or args.ch_mediumslow or args.ch_mediumsfast or args.ch_shortslow or args.ch_shortfast: closeNow = True ch = getNode().channels[channelIndex] enable = args.ch_enable # should we enable this channel? - if args.ch_longslow or args.ch_shortfast: + if or args.ch_longslow or args.ch_longsfast or args.ch_mediumslow or args.ch_mediumsfast or args.ch_shortslow or args.ch_shortfast: if channelIndex != 0: raise Exception( "standard channel settings can only be applied to the PRIMARY channel") @@ -457,6 +457,22 @@ def onConnected(interface): setSimpleChannel( channel_pb2.ChannelSettings.ModemConfig.Bw125Cr48Sf4096) + if args.ch_longsfast: + setSimpleChannel( + channel_pb2.ChannelSettings.ModemConfig.Bw31_25Cr48Sf512) + + if args.ch_mediumslow: + setSimpleChannel( + channel_pb2.ChannelSettings.ModemConfig.Bw250Cr46Sf2048) + + if args.ch_mediumsfast: + setSimpleChannel( + channel_pb2.ChannelSettings.ModemConfig.Bw250Cr47Sf1024) + + if args.ch_shortslow: + setSimpleChannel( + channel_pb2.ChannelSettings.ModemConfig.Bw125Cr45Sf128) + if args.ch_shortfast: setSimpleChannel( channel_pb2.ChannelSettings.ModemConfig.Bw500Cr45Sf128) diff --git a/meshtastic/channel_pb2.py b/meshtastic/channel_pb2.py index 43ae666..599645d 100644 --- a/meshtastic/channel_pb2.py +++ b/meshtastic/channel_pb2.py @@ -18,7 +18,7 @@ DESCRIPTOR = _descriptor.FileDescriptor( package='', syntax='proto3', serialized_options=b'\n\023com.geeksville.meshB\rChannelProtosH\003Z!github.com/meshtastic/gomeshproto', - serialized_pb=b'\n\rchannel.proto\"\xe6\x02\n\x0f\x43hannelSettings\x12\x10\n\x08tx_power\x18\x01 \x01(\x05\x12\x32\n\x0cmodem_config\x18\x03 \x01(\x0e\x32\x1c.ChannelSettings.ModemConfig\x12\x11\n\tbandwidth\x18\x06 \x01(\r\x12\x15\n\rspread_factor\x18\x07 \x01(\r\x12\x13\n\x0b\x63oding_rate\x18\x08 \x01(\r\x12\x13\n\x0b\x63hannel_num\x18\t \x01(\r\x12\x0b\n\x03psk\x18\x04 \x01(\x0c\x12\x0c\n\x04name\x18\x05 \x01(\t\x12\n\n\x02id\x18\n \x01(\x07\x12\x16\n\x0euplink_enabled\x18\x10 \x01(\x08\x12\x18\n\x10\x64ownlink_enabled\x18\x11 \x01(\x08\"`\n\x0bModemConfig\x12\x12\n\x0e\x42w125Cr45Sf128\x10\x00\x12\x12\n\x0e\x42w500Cr45Sf128\x10\x01\x12\x14\n\x10\x42w31_25Cr48Sf512\x10\x02\x12\x13\n\x0f\x42w125Cr48Sf4096\x10\x03\"\x8b\x01\n\x07\x43hannel\x12\r\n\x05index\x18\x01 \x01(\x05\x12\"\n\x08settings\x18\x02 \x01(\x0b\x32\x10.ChannelSettings\x12\x1b\n\x04role\x18\x03 \x01(\x0e\x32\r.Channel.Role\"0\n\x04Role\x12\x0c\n\x08\x44ISABLED\x10\x00\x12\x0b\n\x07PRIMARY\x10\x01\x12\r\n\tSECONDARY\x10\x02\x42I\n\x13\x63om.geeksville.meshB\rChannelProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' + serialized_pb=b'\n\rchannel.proto\"\x91\x03\n\x0f\x43hannelSettings\x12\x10\n\x08tx_power\x18\x01 \x01(\x05\x12\x32\n\x0cmodem_config\x18\x03 \x01(\x0e\x32\x1c.ChannelSettings.ModemConfig\x12\x11\n\tbandwidth\x18\x06 \x01(\r\x12\x15\n\rspread_factor\x18\x07 \x01(\r\x12\x13\n\x0b\x63oding_rate\x18\x08 \x01(\r\x12\x13\n\x0b\x63hannel_num\x18\t \x01(\r\x12\x0b\n\x03psk\x18\x04 \x01(\x0c\x12\x0c\n\x04name\x18\x05 \x01(\t\x12\n\n\x02id\x18\n \x01(\x07\x12\x16\n\x0euplink_enabled\x18\x10 \x01(\x08\x12\x18\n\x10\x64ownlink_enabled\x18\x11 \x01(\x08\"\x8a\x01\n\x0bModemConfig\x12\x12\n\x0e\x42w125Cr45Sf128\x10\x00\x12\x12\n\x0e\x42w500Cr45Sf128\x10\x01\x12\x14\n\x10\x42w31_25Cr48Sf512\x10\x02\x12\x13\n\x0f\x42w125Cr48Sf4096\x10\x03\x12\x13\n\x0f\x42w250Cr46Sf2048\x10\x04\x12\x13\n\x0f\x42w250Cr47Sf1024\x10\x05\"\x8b\x01\n\x07\x43hannel\x12\r\n\x05index\x18\x01 \x01(\x05\x12\"\n\x08settings\x18\x02 \x01(\x0b\x32\x10.ChannelSettings\x12\x1b\n\x04role\x18\x03 \x01(\x0e\x32\r.Channel.Role\"0\n\x04Role\x12\x0c\n\x08\x44ISABLED\x10\x00\x12\x0b\n\x07PRIMARY\x10\x01\x12\r\n\tSECONDARY\x10\x02\x42I\n\x13\x63om.geeksville.meshB\rChannelProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' ) @@ -45,11 +45,19 @@ _CHANNELSETTINGS_MODEMCONFIG = _descriptor.EnumDescriptor( name='Bw125Cr48Sf4096', index=3, number=3, serialized_options=None, type=None), + _descriptor.EnumValueDescriptor( + name='Bw250Cr46Sf2048', index=4, number=4, + serialized_options=None, + type=None), + _descriptor.EnumValueDescriptor( + name='Bw250Cr47Sf1024', index=5, number=5, + serialized_options=None, + type=None), ], containing_type=None, serialized_options=None, - serialized_start=280, - serialized_end=376, + serialized_start=281, + serialized_end=419, ) _sym_db.RegisterEnumDescriptor(_CHANNELSETTINGS_MODEMCONFIG) @@ -74,8 +82,8 @@ _CHANNEL_ROLE = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=470, - serialized_end=518, + serialized_start=513, + serialized_end=561, ) _sym_db.RegisterEnumDescriptor(_CHANNEL_ROLE) @@ -178,7 +186,7 @@ _CHANNELSETTINGS = _descriptor.Descriptor( oneofs=[ ], serialized_start=18, - serialized_end=376, + serialized_end=419, ) @@ -223,8 +231,8 @@ _CHANNEL = _descriptor.Descriptor( extension_ranges=[], oneofs=[ ], - serialized_start=379, - serialized_end=518, + serialized_start=422, + serialized_end=561, ) _CHANNELSETTINGS.fields_by_name['modem_config'].enum_type = _CHANNELSETTINGS_MODEMCONFIG diff --git a/meshtastic/mesh_pb2.py b/meshtastic/mesh_pb2.py index d3f965b..9921689 100644 --- a/meshtastic/mesh_pb2.py +++ b/meshtastic/mesh_pb2.py @@ -20,7 +20,7 @@ DESCRIPTOR = _descriptor.FileDescriptor( package='', syntax='proto3', serialized_options=b'\n\023com.geeksville.meshB\nMeshProtosH\003Z!github.com/meshtastic/gomeshproto', - serialized_pb=b'\n\nmesh.proto\x1a\x0eportnums.proto\"\x94\x06\n\x08Position\x12\x12\n\nlatitude_i\x18\x01 \x01(\x0f\x12\x13\n\x0blongitude_i\x18\x02 \x01(\x0f\x12\x10\n\x08\x61ltitude\x18\x03 \x01(\x05\x12\x15\n\rbattery_level\x18\x04 \x01(\x05\x12\x0c\n\x04time\x18\t \x01(\x07\x12,\n\x0flocation_source\x18\n \x01(\x0e\x32\x13.Position.LocSource\x12,\n\x0f\x61ltitude_source\x18\x0b \x01(\x0e\x32\x13.Position.AltSource\x12\x15\n\rpos_timestamp\x18\x0c \x01(\x07\x12\x17\n\x0fpos_time_millis\x18\r \x01(\x05\x12\x14\n\x0c\x61ltitude_hae\x18\x0e \x01(\x11\x12\x15\n\ralt_geoid_sep\x18\x0f \x01(\x11\x12\x0c\n\x04PDOP\x18\x10 \x01(\r\x12\x0c\n\x04HDOP\x18\x11 \x01(\r\x12\x0c\n\x04VDOP\x18\x12 \x01(\r\x12\x14\n\x0cgps_accuracy\x18\x13 \x01(\r\x12\x14\n\x0cground_speed\x18\x14 \x01(\r\x12\x14\n\x0cground_track\x18\x15 \x01(\r\x12\x13\n\x0b\x66ix_quality\x18\x16 \x01(\r\x12\x10\n\x08\x66ix_type\x18\x17 \x01(\r\x12\x14\n\x0csats_in_view\x18\x18 \x01(\r\x12\x11\n\tsensor_id\x18\x19 \x01(\r\x12\x17\n\x0fpos_next_update\x18( \x01(\r\x12\x16\n\x0epos_seq_number\x18) \x01(\r\"n\n\tLocSource\x12\x16\n\x12LOCSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13LOCSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13LOCSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13LOCSRC_GPS_EXTERNAL\x10\x03\"\x85\x01\n\tAltSource\x12\x16\n\x12\x41LTSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13\x41LTSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13\x41LTSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13\x41LTSRC_GPS_EXTERNAL\x10\x03\x12\x15\n\x11\x41LTSRC_BAROMETRIC\x10\x04J\x04\x08\x07\x10\x08J\x04\x08\x08\x10\t\"\xd7\x01\n\x04User\x12\n\n\x02id\x18\x01 \x01(\t\x12\x11\n\tlong_name\x18\x02 \x01(\t\x12\x12\n\nshort_name\x18\x03 \x01(\t\x12\x0f\n\x07macaddr\x18\x04 \x01(\x0c\x12 \n\x08hw_model\x18\x06 \x01(\x0e\x32\x0e.HardwareModel\x12\x13\n\x0bis_licensed\x18\x07 \x01(\x08\x12\x13\n\x04team\x18\x08 \x01(\x0e\x32\x05.Team\x12\x14\n\x0ctx_power_dbm\x18\n \x01(\r\x12\x14\n\x0c\x61nt_gain_dbi\x18\x0b \x01(\r\x12\x13\n\x0b\x61nt_azimuth\x18\x0c \x01(\r\"\x1f\n\x0eRouteDiscovery\x12\r\n\x05route\x18\x02 \x03(\x07\"\xc5\x02\n\x07Routing\x12(\n\rroute_request\x18\x01 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0broute_reply\x18\x02 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0c\x65rror_reason\x18\x03 \x01(\x0e\x32\x0e.Routing.ErrorH\x00\"\xb4\x01\n\x05\x45rror\x12\x08\n\x04NONE\x10\x00\x12\x0c\n\x08NO_ROUTE\x10\x01\x12\x0b\n\x07GOT_NAK\x10\x02\x12\x0b\n\x07TIMEOUT\x10\x03\x12\x10\n\x0cNO_INTERFACE\x10\x04\x12\x12\n\x0eMAX_RETRANSMIT\x10\x05\x12\x0e\n\nNO_CHANNEL\x10\x06\x12\r\n\tTOO_LARGE\x10\x07\x12\x0f\n\x0bNO_RESPONSE\x10\x08\x12\x0f\n\x0b\x42\x41\x44_REQUEST\x10 \x12\x12\n\x0eNOT_AUTHORIZED\x10!B\t\n\x07variant\"{\n\x04\x44\x61ta\x12\x19\n\x07portnum\x18\x01 \x01(\x0e\x32\x08.PortNum\x12\x0f\n\x07payload\x18\x02 \x01(\x0c\x12\x15\n\rwant_response\x18\x03 \x01(\x08\x12\x0c\n\x04\x64\x65st\x18\x04 \x01(\x07\x12\x0e\n\x06source\x18\x05 \x01(\x07\x12\x12\n\nrequest_id\x18\x06 \x01(\x07\"\xe0\x02\n\nMeshPacket\x12\x0c\n\x04\x66rom\x18\x01 \x01(\x07\x12\n\n\x02to\x18\x02 \x01(\x07\x12\x0f\n\x07\x63hannel\x18\x03 \x01(\r\x12\x18\n\x07\x64\x65\x63oded\x18\x04 \x01(\x0b\x32\x05.DataH\x00\x12\x13\n\tencrypted\x18\x05 \x01(\x0cH\x00\x12\n\n\x02id\x18\x06 \x01(\x07\x12\x0f\n\x07rx_time\x18\x07 \x01(\x07\x12\x0e\n\x06rx_snr\x18\x08 \x01(\x02\x12\x11\n\thop_limit\x18\n \x01(\r\x12\x10\n\x08want_ack\x18\x0b \x01(\x08\x12&\n\x08priority\x18\x0c \x01(\x0e\x32\x14.MeshPacket.Priority\x12\x0f\n\x07rx_rssi\x18\r \x01(\x05\"[\n\x08Priority\x12\t\n\x05UNSET\x10\x00\x12\x07\n\x03MIN\x10\x01\x12\x0e\n\nBACKGROUND\x10\n\x12\x0b\n\x07\x44\x45\x46\x41ULT\x10@\x12\x0c\n\x08RELIABLE\x10\x46\x12\x07\n\x03\x41\x43K\x10x\x12\x07\n\x03MAX\x10\x7f\x42\x10\n\x0epayloadVariant\"j\n\x08NodeInfo\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x13\n\x04user\x18\x02 \x01(\x0b\x32\x05.User\x12\x1b\n\x08position\x18\x03 \x01(\x0b\x32\t.Position\x12\x0b\n\x03snr\x18\x07 \x01(\x02\x12\x12\n\nlast_heard\x18\x04 \x01(\x07\"\xcb\x02\n\nMyNodeInfo\x12\x13\n\x0bmy_node_num\x18\x01 \x01(\r\x12\x0f\n\x07has_gps\x18\x02 \x01(\x08\x12\x11\n\tnum_bands\x18\x03 \x01(\r\x12\x14\n\x0cmax_channels\x18\x0f \x01(\r\x12\x12\n\x06region\x18\x04 \x01(\tB\x02\x18\x01\x12\x1f\n\x13hw_model_deprecated\x18\x05 \x01(\tB\x02\x18\x01\x12\x18\n\x10\x66irmware_version\x18\x06 \x01(\t\x12&\n\nerror_code\x18\x07 \x01(\x0e\x32\x12.CriticalErrorCode\x12\x15\n\rerror_address\x18\x08 \x01(\r\x12\x13\n\x0b\x65rror_count\x18\t \x01(\r\x12\x14\n\x0creboot_count\x18\n \x01(\r\x12\x1c\n\x14message_timeout_msec\x18\r \x01(\r\x12\x17\n\x0fmin_app_version\x18\x0e \x01(\r\"\xb5\x01\n\tLogRecord\x12\x0f\n\x07message\x18\x01 \x01(\t\x12\x0c\n\x04time\x18\x02 \x01(\x07\x12\x0e\n\x06source\x18\x03 \x01(\t\x12\x1f\n\x05level\x18\x04 \x01(\x0e\x32\x10.LogRecord.Level\"X\n\x05Level\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08\x43RITICAL\x10\x32\x12\t\n\x05\x45RROR\x10(\x12\x0b\n\x07WARNING\x10\x1e\x12\x08\n\x04INFO\x10\x14\x12\t\n\x05\x44\x45\x42UG\x10\n\x12\t\n\x05TRACE\x10\x05\"\xe9\x01\n\tFromRadio\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x1d\n\x06packet\x18\x0b \x01(\x0b\x32\x0b.MeshPacketH\x00\x12\x1e\n\x07my_info\x18\x03 \x01(\x0b\x32\x0b.MyNodeInfoH\x00\x12\x1e\n\tnode_info\x18\x04 \x01(\x0b\x32\t.NodeInfoH\x00\x12 \n\nlog_record\x18\x07 \x01(\x0b\x32\n.LogRecordH\x00\x12\x1c\n\x12\x63onfig_complete_id\x18\x08 \x01(\rH\x00\x12\x12\n\x08rebooted\x18\t \x01(\x08H\x00\x42\x10\n\x0epayloadVariantJ\x04\x08\x02\x10\x03J\x04\x08\x06\x10\x07\"\xe1\x01\n\x07ToRadio\x12\x1d\n\x06packet\x18\x02 \x01(\x0b\x32\x0b.MeshPacketH\x00\x12&\n\tpeer_info\x18\x03 \x01(\x0b\x32\x11.ToRadio.PeerInfoH\x00\x12\x18\n\x0ewant_config_id\x18\x64 \x01(\rH\x00\x12\x14\n\ndisconnect\x18h \x01(\x08H\x00\x1a\x35\n\x08PeerInfo\x12\x13\n\x0b\x61pp_version\x18\x01 \x01(\r\x12\x14\n\x0cmqtt_gateway\x18\x02 \x01(\x08\x42\x10\n\x0epayloadVariantJ\x04\x08\x01\x10\x02J\x04\x08\x65\x10\x66J\x04\x08\x66\x10gJ\x04\x08g\x10h*\xac\x02\n\rHardwareModel\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08TLORA_V2\x10\x01\x12\x0c\n\x08TLORA_V1\x10\x02\x12\x12\n\x0eTLORA_V2_1_1p6\x10\x03\x12\t\n\x05TBEAM\x10\x04\x12\x0f\n\x0bHELTEC_V2_0\x10\x05\x12\x0c\n\x08TBEAM0p7\x10\x06\x12\n\n\x06T_ECHO\x10\x07\x12\x10\n\x0cTLORA_V1_1p3\x10\x08\x12\x0b\n\x07RAK4631\x10\t\x12\x0f\n\x0bHELTEC_V2_1\x10\n\x12\x11\n\rLORA_RELAY_V1\x10 \x12\x0e\n\nNRF52840DK\x10!\x12\x07\n\x03PPR\x10\"\x12\x0f\n\x0bGENIEBLOCKS\x10#\x12\x11\n\rNRF52_UNKNOWN\x10$\x12\r\n\tPORTDUINO\x10%\x12\x0f\n\x0b\x41NDROID_SIM\x10&\x12\n\n\x06\x44IY_V1\x10\'*\xb5\x01\n\x04Team\x12\t\n\x05\x43LEAR\x10\x00\x12\x08\n\x04\x43YAN\x10\x01\x12\t\n\x05WHITE\x10\x02\x12\n\n\x06YELLOW\x10\x03\x12\n\n\x06ORANGE\x10\x04\x12\x0b\n\x07MAGENTA\x10\x05\x12\x07\n\x03RED\x10\x06\x12\n\n\x06MAROON\x10\x07\x12\n\n\x06PURPLE\x10\x08\x12\r\n\tDARK_BLUE\x10\t\x12\x08\n\x04\x42LUE\x10\n\x12\x08\n\x04TEAL\x10\x0b\x12\t\n\x05GREEN\x10\x0c\x12\x0e\n\nDARK_GREEN\x10\r\x12\t\n\x05\x42ROWN\x10\x0e*.\n\tConstants\x12\n\n\x06Unused\x10\x00\x12\x15\n\x10\x44\x41TA_PAYLOAD_LEN\x10\xed\x01*\xe1\x01\n\x11\x43riticalErrorCode\x12\x08\n\x04None\x10\x00\x12\x0e\n\nTxWatchdog\x10\x01\x12\x12\n\x0eSleepEnterWait\x10\x02\x12\x0b\n\x07NoRadio\x10\x03\x12\x0f\n\x0bUnspecified\x10\x04\x12\x13\n\x0fUBloxInitFailed\x10\x05\x12\x0c\n\x08NoAXP192\x10\x06\x12\x17\n\x13InvalidRadioSetting\x10\x07\x12\x12\n\x0eTransmitFailed\x10\x08\x12\x0c\n\x08\x42rownout\x10\t\x12\x11\n\rSX1262Failure\x10\n\x12\x0f\n\x0bRadioSpiBug\x10\x0b\x42\x46\n\x13\x63om.geeksville.meshB\nMeshProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' + serialized_pb=b'\n\nmesh.proto\x1a\x0eportnums.proto\"\x94\x06\n\x08Position\x12\x12\n\nlatitude_i\x18\x01 \x01(\x0f\x12\x13\n\x0blongitude_i\x18\x02 \x01(\x0f\x12\x10\n\x08\x61ltitude\x18\x03 \x01(\x05\x12\x15\n\rbattery_level\x18\x04 \x01(\x05\x12\x0c\n\x04time\x18\t \x01(\x07\x12,\n\x0flocation_source\x18\n \x01(\x0e\x32\x13.Position.LocSource\x12,\n\x0f\x61ltitude_source\x18\x0b \x01(\x0e\x32\x13.Position.AltSource\x12\x15\n\rpos_timestamp\x18\x0c \x01(\x07\x12\x17\n\x0fpos_time_millis\x18\r \x01(\x05\x12\x14\n\x0c\x61ltitude_hae\x18\x0e \x01(\x11\x12\x15\n\ralt_geoid_sep\x18\x0f \x01(\x11\x12\x0c\n\x04PDOP\x18\x10 \x01(\r\x12\x0c\n\x04HDOP\x18\x11 \x01(\r\x12\x0c\n\x04VDOP\x18\x12 \x01(\r\x12\x14\n\x0cgps_accuracy\x18\x13 \x01(\r\x12\x14\n\x0cground_speed\x18\x14 \x01(\r\x12\x14\n\x0cground_track\x18\x15 \x01(\r\x12\x13\n\x0b\x66ix_quality\x18\x16 \x01(\r\x12\x10\n\x08\x66ix_type\x18\x17 \x01(\r\x12\x14\n\x0csats_in_view\x18\x18 \x01(\r\x12\x11\n\tsensor_id\x18\x19 \x01(\r\x12\x17\n\x0fpos_next_update\x18( \x01(\r\x12\x16\n\x0epos_seq_number\x18) \x01(\r\"n\n\tLocSource\x12\x16\n\x12LOCSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13LOCSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13LOCSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13LOCSRC_GPS_EXTERNAL\x10\x03\"\x85\x01\n\tAltSource\x12\x16\n\x12\x41LTSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13\x41LTSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13\x41LTSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13\x41LTSRC_GPS_EXTERNAL\x10\x03\x12\x15\n\x11\x41LTSRC_BAROMETRIC\x10\x04J\x04\x08\x07\x10\x08J\x04\x08\x08\x10\t\"\xd7\x01\n\x04User\x12\n\n\x02id\x18\x01 \x01(\t\x12\x11\n\tlong_name\x18\x02 \x01(\t\x12\x12\n\nshort_name\x18\x03 \x01(\t\x12\x0f\n\x07macaddr\x18\x04 \x01(\x0c\x12 \n\x08hw_model\x18\x06 \x01(\x0e\x32\x0e.HardwareModel\x12\x13\n\x0bis_licensed\x18\x07 \x01(\x08\x12\x13\n\x04team\x18\x08 \x01(\x0e\x32\x05.Team\x12\x14\n\x0ctx_power_dbm\x18\n \x01(\r\x12\x14\n\x0c\x61nt_gain_dbi\x18\x0b \x01(\r\x12\x13\n\x0b\x61nt_azimuth\x18\x0c \x01(\r\"\x1f\n\x0eRouteDiscovery\x12\r\n\x05route\x18\x02 \x03(\x07\"\xc5\x02\n\x07Routing\x12(\n\rroute_request\x18\x01 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0broute_reply\x18\x02 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0c\x65rror_reason\x18\x03 \x01(\x0e\x32\x0e.Routing.ErrorH\x00\"\xb4\x01\n\x05\x45rror\x12\x08\n\x04NONE\x10\x00\x12\x0c\n\x08NO_ROUTE\x10\x01\x12\x0b\n\x07GOT_NAK\x10\x02\x12\x0b\n\x07TIMEOUT\x10\x03\x12\x10\n\x0cNO_INTERFACE\x10\x04\x12\x12\n\x0eMAX_RETRANSMIT\x10\x05\x12\x0e\n\nNO_CHANNEL\x10\x06\x12\r\n\tTOO_LARGE\x10\x07\x12\x0f\n\x0bNO_RESPONSE\x10\x08\x12\x0f\n\x0b\x42\x41\x44_REQUEST\x10 \x12\x12\n\x0eNOT_AUTHORIZED\x10!B\t\n\x07variant\"{\n\x04\x44\x61ta\x12\x19\n\x07portnum\x18\x01 \x01(\x0e\x32\x08.PortNum\x12\x0f\n\x07payload\x18\x02 \x01(\x0c\x12\x15\n\rwant_response\x18\x03 \x01(\x08\x12\x0c\n\x04\x64\x65st\x18\x04 \x01(\x07\x12\x0e\n\x06source\x18\x05 \x01(\x07\x12\x12\n\nrequest_id\x18\x06 \x01(\x07\"\xe0\x02\n\nMeshPacket\x12\x0c\n\x04\x66rom\x18\x01 \x01(\x07\x12\n\n\x02to\x18\x02 \x01(\x07\x12\x0f\n\x07\x63hannel\x18\x03 \x01(\r\x12\x18\n\x07\x64\x65\x63oded\x18\x04 \x01(\x0b\x32\x05.DataH\x00\x12\x13\n\tencrypted\x18\x05 \x01(\x0cH\x00\x12\n\n\x02id\x18\x06 \x01(\x07\x12\x0f\n\x07rx_time\x18\x07 \x01(\x07\x12\x0e\n\x06rx_snr\x18\x08 \x01(\x02\x12\x11\n\thop_limit\x18\n \x01(\r\x12\x10\n\x08want_ack\x18\x0b \x01(\x08\x12&\n\x08priority\x18\x0c \x01(\x0e\x32\x14.MeshPacket.Priority\x12\x0f\n\x07rx_rssi\x18\r \x01(\x05\"[\n\x08Priority\x12\t\n\x05UNSET\x10\x00\x12\x07\n\x03MIN\x10\x01\x12\x0e\n\nBACKGROUND\x10\n\x12\x0b\n\x07\x44\x45\x46\x41ULT\x10@\x12\x0c\n\x08RELIABLE\x10\x46\x12\x07\n\x03\x41\x43K\x10x\x12\x07\n\x03MAX\x10\x7f\x42\x10\n\x0epayloadVariant\"j\n\x08NodeInfo\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x13\n\x04user\x18\x02 \x01(\x0b\x32\x05.User\x12\x1b\n\x08position\x18\x03 \x01(\x0b\x32\t.Position\x12\x0b\n\x03snr\x18\x07 \x01(\x02\x12\x12\n\nlast_heard\x18\x04 \x01(\x07\"\xdc\x02\n\nMyNodeInfo\x12\x13\n\x0bmy_node_num\x18\x01 \x01(\r\x12\x0f\n\x07has_gps\x18\x02 \x01(\x08\x12\x11\n\tnum_bands\x18\x03 \x01(\r\x12\x14\n\x0cmax_channels\x18\x0f \x01(\r\x12\x12\n\x06region\x18\x04 \x01(\tB\x02\x18\x01\x12\x1f\n\x13hw_model_deprecated\x18\x05 \x01(\tB\x02\x18\x01\x12\x18\n\x10\x66irmware_version\x18\x06 \x01(\t\x12&\n\nerror_code\x18\x07 \x01(\x0e\x32\x12.CriticalErrorCode\x12\x15\n\rerror_address\x18\x08 \x01(\r\x12\x13\n\x0b\x65rror_count\x18\t \x01(\r\x12\x14\n\x0creboot_count\x18\n \x01(\r\x12\x0f\n\x07\x62itrate\x18\x0b \x01(\x02\x12\x1c\n\x14message_timeout_msec\x18\r \x01(\r\x12\x17\n\x0fmin_app_version\x18\x0e \x01(\r\"\xb5\x01\n\tLogRecord\x12\x0f\n\x07message\x18\x01 \x01(\t\x12\x0c\n\x04time\x18\x02 \x01(\x07\x12\x0e\n\x06source\x18\x03 \x01(\t\x12\x1f\n\x05level\x18\x04 \x01(\x0e\x32\x10.LogRecord.Level\"X\n\x05Level\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08\x43RITICAL\x10\x32\x12\t\n\x05\x45RROR\x10(\x12\x0b\n\x07WARNING\x10\x1e\x12\x08\n\x04INFO\x10\x14\x12\t\n\x05\x44\x45\x42UG\x10\n\x12\t\n\x05TRACE\x10\x05\"\xe9\x01\n\tFromRadio\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x1d\n\x06packet\x18\x0b \x01(\x0b\x32\x0b.MeshPacketH\x00\x12\x1e\n\x07my_info\x18\x03 \x01(\x0b\x32\x0b.MyNodeInfoH\x00\x12\x1e\n\tnode_info\x18\x04 \x01(\x0b\x32\t.NodeInfoH\x00\x12 \n\nlog_record\x18\x07 \x01(\x0b\x32\n.LogRecordH\x00\x12\x1c\n\x12\x63onfig_complete_id\x18\x08 \x01(\rH\x00\x12\x12\n\x08rebooted\x18\t \x01(\x08H\x00\x42\x10\n\x0epayloadVariantJ\x04\x08\x02\x10\x03J\x04\x08\x06\x10\x07\"\xe1\x01\n\x07ToRadio\x12\x1d\n\x06packet\x18\x02 \x01(\x0b\x32\x0b.MeshPacketH\x00\x12&\n\tpeer_info\x18\x03 \x01(\x0b\x32\x11.ToRadio.PeerInfoH\x00\x12\x18\n\x0ewant_config_id\x18\x64 \x01(\rH\x00\x12\x14\n\ndisconnect\x18h \x01(\x08H\x00\x1a\x35\n\x08PeerInfo\x12\x13\n\x0b\x61pp_version\x18\x01 \x01(\r\x12\x14\n\x0cmqtt_gateway\x18\x02 \x01(\x08\x42\x10\n\x0epayloadVariantJ\x04\x08\x01\x10\x02J\x04\x08\x65\x10\x66J\x04\x08\x66\x10gJ\x04\x08g\x10h*\xac\x02\n\rHardwareModel\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08TLORA_V2\x10\x01\x12\x0c\n\x08TLORA_V1\x10\x02\x12\x12\n\x0eTLORA_V2_1_1p6\x10\x03\x12\t\n\x05TBEAM\x10\x04\x12\x0f\n\x0bHELTEC_V2_0\x10\x05\x12\x0c\n\x08TBEAM0p7\x10\x06\x12\n\n\x06T_ECHO\x10\x07\x12\x10\n\x0cTLORA_V1_1p3\x10\x08\x12\x0b\n\x07RAK4631\x10\t\x12\x0f\n\x0bHELTEC_V2_1\x10\n\x12\x11\n\rLORA_RELAY_V1\x10 \x12\x0e\n\nNRF52840DK\x10!\x12\x07\n\x03PPR\x10\"\x12\x0f\n\x0bGENIEBLOCKS\x10#\x12\x11\n\rNRF52_UNKNOWN\x10$\x12\r\n\tPORTDUINO\x10%\x12\x0f\n\x0b\x41NDROID_SIM\x10&\x12\n\n\x06\x44IY_V1\x10\'*\xb5\x01\n\x04Team\x12\t\n\x05\x43LEAR\x10\x00\x12\x08\n\x04\x43YAN\x10\x01\x12\t\n\x05WHITE\x10\x02\x12\n\n\x06YELLOW\x10\x03\x12\n\n\x06ORANGE\x10\x04\x12\x0b\n\x07MAGENTA\x10\x05\x12\x07\n\x03RED\x10\x06\x12\n\n\x06MAROON\x10\x07\x12\n\n\x06PURPLE\x10\x08\x12\r\n\tDARK_BLUE\x10\t\x12\x08\n\x04\x42LUE\x10\n\x12\x08\n\x04TEAL\x10\x0b\x12\t\n\x05GREEN\x10\x0c\x12\x0e\n\nDARK_GREEN\x10\r\x12\t\n\x05\x42ROWN\x10\x0e*.\n\tConstants\x12\n\n\x06Unused\x10\x00\x12\x15\n\x10\x44\x41TA_PAYLOAD_LEN\x10\xed\x01*\xe1\x01\n\x11\x43riticalErrorCode\x12\x08\n\x04None\x10\x00\x12\x0e\n\nTxWatchdog\x10\x01\x12\x12\n\x0eSleepEnterWait\x10\x02\x12\x0b\n\x07NoRadio\x10\x03\x12\x0f\n\x0bUnspecified\x10\x04\x12\x13\n\x0fUBloxInitFailed\x10\x05\x12\x0c\n\x08NoAXP192\x10\x06\x12\x17\n\x13InvalidRadioSetting\x10\x07\x12\x12\n\x0eTransmitFailed\x10\x08\x12\x0c\n\x08\x42rownout\x10\t\x12\x11\n\rSX1262Failure\x10\n\x12\x0f\n\x0bRadioSpiBug\x10\x0b\x42\x46\n\x13\x63om.geeksville.meshB\nMeshProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' , dependencies=[portnums__pb2.DESCRIPTOR,]) @@ -109,8 +109,8 @@ _HARDWAREMODEL = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2971, - serialized_end=3271, + serialized_start=2988, + serialized_end=3288, ) _sym_db.RegisterEnumDescriptor(_HARDWAREMODEL) @@ -184,8 +184,8 @@ _TEAM = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3274, - serialized_end=3455, + serialized_start=3291, + serialized_end=3472, ) _sym_db.RegisterEnumDescriptor(_TEAM) @@ -207,8 +207,8 @@ _CONSTANTS = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3457, - serialized_end=3503, + serialized_start=3474, + serialized_end=3520, ) _sym_db.RegisterEnumDescriptor(_CONSTANTS) @@ -270,8 +270,8 @@ _CRITICALERRORCODE = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3506, - serialized_end=3731, + serialized_start=3523, + serialized_end=3748, ) _sym_db.RegisterEnumDescriptor(_CRITICALERRORCODE) @@ -527,8 +527,8 @@ _LOGRECORD_LEVEL = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2416, - serialized_end=2504, + serialized_start=2433, + serialized_end=2521, ) _sym_db.RegisterEnumDescriptor(_LOGRECORD_LEVEL) @@ -1216,14 +1216,21 @@ _MYNODEINFO = _descriptor.Descriptor( is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR), _descriptor.FieldDescriptor( - name='message_timeout_msec', full_name='MyNodeInfo.message_timeout_msec', index=11, + name='bitrate', full_name='MyNodeInfo.bitrate', index=11, + number=11, type=2, cpp_type=6, label=1, + has_default_value=False, default_value=float(0), + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), + _descriptor.FieldDescriptor( + name='message_timeout_msec', full_name='MyNodeInfo.message_timeout_msec', index=12, number=13, type=13, cpp_type=3, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR), _descriptor.FieldDescriptor( - name='min_app_version', full_name='MyNodeInfo.min_app_version', index=12, + name='min_app_version', full_name='MyNodeInfo.min_app_version', index=13, number=14, type=13, cpp_type=3, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, @@ -1242,7 +1249,7 @@ _MYNODEINFO = _descriptor.Descriptor( oneofs=[ ], serialized_start=1989, - serialized_end=2320, + serialized_end=2337, ) @@ -1294,8 +1301,8 @@ _LOGRECORD = _descriptor.Descriptor( extension_ranges=[], oneofs=[ ], - serialized_start=2323, - serialized_end=2504, + serialized_start=2340, + serialized_end=2521, ) @@ -1370,8 +1377,8 @@ _FROMRADIO = _descriptor.Descriptor( name='payloadVariant', full_name='FromRadio.payloadVariant', index=0, containing_type=None, fields=[]), ], - serialized_start=2507, - serialized_end=2740, + serialized_start=2524, + serialized_end=2757, ) @@ -1408,8 +1415,8 @@ _TORADIO_PEERINFO = _descriptor.Descriptor( extension_ranges=[], oneofs=[ ], - serialized_start=2873, - serialized_end=2926, + serialized_start=2890, + serialized_end=2943, ) _TORADIO = _descriptor.Descriptor( @@ -1462,8 +1469,8 @@ _TORADIO = _descriptor.Descriptor( name='payloadVariant', full_name='ToRadio.payloadVariant', index=0, containing_type=None, fields=[]), ], - serialized_start=2743, - serialized_end=2968, + serialized_start=2760, + serialized_end=2985, ) _POSITION.fields_by_name['location_source'].enum_type = _POSITION_LOCSOURCE diff --git a/meshtastic/radioconfig_pb2.py b/meshtastic/radioconfig_pb2.py index 1e755fb..3ee457e 100644 --- a/meshtastic/radioconfig_pb2.py +++ b/meshtastic/radioconfig_pb2.py @@ -19,7 +19,7 @@ DESCRIPTOR = _descriptor.FileDescriptor( package='', syntax='proto3', serialized_options=b'\n\023com.geeksville.meshB\021RadioConfigProtosH\003Z!github.com/meshtastic/gomeshproto', - serialized_pb=b'\n\x11radioconfig.proto\"\xfa\x12\n\x0bRadioConfig\x12\x31\n\x0bpreferences\x18\x01 \x01(\x0b\x32\x1c.RadioConfig.UserPreferences\x1a\xb7\x12\n\x0fUserPreferences\x12\x1f\n\x17position_broadcast_secs\x18\x01 \x01(\r\x12 \n\x18position_broadcast_smart\x18\x11 \x01(\x08\x12\x1b\n\x13send_owner_interval\x18\x02 \x01(\r\x12\x1b\n\x13wait_bluetooth_secs\x18\x04 \x01(\r\x12\x16\n\x0escreen_on_secs\x18\x05 \x01(\r\x12\x1a\n\x12phone_timeout_secs\x18\x06 \x01(\r\x12\x1d\n\x15phone_sds_timeout_sec\x18\x07 \x01(\r\x12\x1d\n\x15mesh_sds_timeout_secs\x18\x08 \x01(\r\x12\x10\n\x08sds_secs\x18\t \x01(\r\x12\x0f\n\x07ls_secs\x18\n \x01(\r\x12\x15\n\rmin_wake_secs\x18\x0b \x01(\r\x12\x11\n\twifi_ssid\x18\x0c \x01(\t\x12\x15\n\rwifi_password\x18\r \x01(\t\x12\x14\n\x0cwifi_ap_mode\x18\x0e \x01(\x08\x12\x1b\n\x06region\x18\x0f \x01(\x0e\x32\x0b.RegionCode\x12&\n\x0e\x63harge_current\x18\x10 \x01(\x0e\x32\x0e.ChargeCurrent\x12\x11\n\tis_router\x18% \x01(\x08\x12\x14\n\x0cis_low_power\x18& \x01(\x08\x12\x16\n\x0e\x66ixed_position\x18\' \x01(\x08\x12\x17\n\x0fserial_disabled\x18( \x01(\x08\x12(\n\x0elocation_share\x18 \x01(\x0e\x32\x10.LocationSharing\x12$\n\rgps_operation\x18! \x01(\x0e\x32\r.GpsOperation\x12\x1b\n\x13gps_update_interval\x18\" \x01(\r\x12\x18\n\x10gps_attempt_time\x18$ \x01(\r\x12\x15\n\rgps_accept_2d\x18- \x01(\x08\x12\x13\n\x0bgps_max_dop\x18. \x01(\r\x12\x18\n\x10\x66requency_offset\x18) \x01(\x02\x12\x13\n\x0bmqtt_server\x18* \x01(\t\x12\x15\n\rmqtt_disabled\x18+ \x01(\x08\x12(\n\ngps_format\x18, \x01(\x0e\x32\x14.GpsCoordinateFormat\x12\x15\n\rfactory_reset\x18\x64 \x01(\x08\x12\x19\n\x11\x64\x65\x62ug_log_enabled\x18\x65 \x01(\x08\x12\x17\n\x0fignore_incoming\x18g \x03(\r\x12\x1c\n\x14serialplugin_enabled\x18x \x01(\x08\x12\x19\n\x11serialplugin_echo\x18y \x01(\x08\x12\x18\n\x10serialplugin_rxd\x18z \x01(\r\x12\x18\n\x10serialplugin_txd\x18{ \x01(\r\x12\x1c\n\x14serialplugin_timeout\x18| \x01(\r\x12\x19\n\x11serialplugin_mode\x18} \x01(\r\x12\'\n\x1f\x65xt_notification_plugin_enabled\x18~ \x01(\x08\x12)\n!ext_notification_plugin_output_ms\x18\x7f \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_output\x18\x80\x01 \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_active\x18\x81\x01 \x01(\x08\x12.\n%ext_notification_plugin_alert_message\x18\x82\x01 \x01(\x08\x12+\n\"ext_notification_plugin_alert_bell\x18\x83\x01 \x01(\x08\x12\"\n\x19range_test_plugin_enabled\x18\x84\x01 \x01(\x08\x12!\n\x18range_test_plugin_sender\x18\x85\x01 \x01(\r\x12\x1f\n\x16range_test_plugin_save\x18\x86\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_enabled\x18\x94\x01 \x01(\x08\x12\'\n\x1estore_forward_plugin_heartbeat\x18\x95\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_records\x18\x89\x01 \x01(\r\x12\x30\n\'store_forward_plugin_history_return_max\x18\x8a\x01 \x01(\r\x12\x33\n*store_forward_plugin_history_return_window\x18\x8b\x01 \x01(\r\x12=\n4environmental_measurement_plugin_measurement_enabled\x18\x8c\x01 \x01(\x08\x12\x38\n/environmental_measurement_plugin_screen_enabled\x18\x8d\x01 \x01(\x08\x12\x44\n;environmental_measurement_plugin_read_error_count_threshold\x18\x8e\x01 \x01(\r\x12\x39\n0environmental_measurement_plugin_update_interval\x18\x8f\x01 \x01(\r\x12;\n2environmental_measurement_plugin_recovery_interval\x18\x90\x01 \x01(\r\x12;\n2environmental_measurement_plugin_display_farenheit\x18\x91\x01 \x01(\x08\x12v\n,environmental_measurement_plugin_sensor_type\x18\x92\x01 \x01(\x0e\x32?.RadioConfig.UserPreferences.EnvironmentalMeasurementSensorType\x12\x34\n+environmental_measurement_plugin_sensor_pin\x18\x93\x01 \x01(\r\x12\x17\n\x0eposition_flags\x18\x96\x01 \x01(\r\x12\x1a\n\x11is_always_powered\x18\x97\x01 \x01(\x08\x12\"\n\x19\x61uto_screen_carousel_secs\x18\x98\x01 \x01(\r\"<\n\"EnvironmentalMeasurementSensorType\x12\t\n\x05\x44HT11\x10\x00\x12\x0b\n\x07\x44S18B20\x10\x01J\x06\x08\x88\x01\x10\x89\x01*f\n\nRegionCode\x12\t\n\x05Unset\x10\x00\x12\x06\n\x02US\x10\x01\x12\t\n\x05\x45U433\x10\x02\x12\t\n\x05\x45U865\x10\x03\x12\x06\n\x02\x43N\x10\x04\x12\x06\n\x02JP\x10\x05\x12\x07\n\x03\x41NZ\x10\x06\x12\x06\n\x02KR\x10\x07\x12\x06\n\x02TW\x10\x08\x12\x06\n\x02RU\x10\t*\xd1\x01\n\rChargeCurrent\x12\x0b\n\x07MAUnset\x10\x00\x12\t\n\x05MA100\x10\x01\x12\t\n\x05MA190\x10\x02\x12\t\n\x05MA280\x10\x03\x12\t\n\x05MA360\x10\x04\x12\t\n\x05MA450\x10\x05\x12\t\n\x05MA550\x10\x06\x12\t\n\x05MA630\x10\x07\x12\t\n\x05MA700\x10\x08\x12\t\n\x05MA780\x10\t\x12\t\n\x05MA880\x10\n\x12\t\n\x05MA960\x10\x0b\x12\n\n\x06MA1000\x10\x0c\x12\n\n\x06MA1080\x10\r\x12\n\n\x06MA1160\x10\x0e\x12\n\n\x06MA1240\x10\x0f\x12\n\n\x06MA1320\x10\x10*j\n\x0cGpsOperation\x12\x0e\n\nGpsOpUnset\x10\x00\x12\x13\n\x0fGpsOpStationary\x10\x01\x12\x0f\n\x0bGpsOpMobile\x10\x02\x12\x11\n\rGpsOpTimeOnly\x10\x03\x12\x11\n\rGpsOpDisabled\x10\x04*\x83\x01\n\x13GpsCoordinateFormat\x12\x10\n\x0cGpsFormatDec\x10\x00\x12\x10\n\x0cGpsFormatDMS\x10\x01\x12\x10\n\x0cGpsFormatUTM\x10\x02\x12\x11\n\rGpsFormatMGRS\x10\x03\x12\x10\n\x0cGpsFormatOLC\x10\x04\x12\x11\n\rGpsFormatOSGR\x10\x05*@\n\x0fLocationSharing\x12\x0c\n\x08LocUnset\x10\x00\x12\x0e\n\nLocEnabled\x10\x01\x12\x0f\n\x0bLocDisabled\x10\x02*\xbc\x01\n\rPositionFlags\x12\x11\n\rPOS_UNDEFINED\x10\x00\x12\x10\n\x0cPOS_ALTITUDE\x10\x01\x12\x0f\n\x0bPOS_ALT_MSL\x10\x02\x12\x0f\n\x0bPOS_GEO_SEP\x10\x04\x12\x0b\n\x07POS_DOP\x10\x08\x12\r\n\tPOS_HVDOP\x10\x10\x12\x0f\n\x0bPOS_BATTERY\x10 \x12\x11\n\rPOS_SATINVIEW\x10@\x12\x10\n\x0bPOS_SEQ_NOS\x10\x80\x01\x12\x12\n\rPOS_TIMESTAMP\x10\x80\x02\x42M\n\x13\x63om.geeksville.meshB\x11RadioConfigProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' + serialized_pb=b'\n\x11radioconfig.proto\"\xa3\x13\n\x0bRadioConfig\x12\x31\n\x0bpreferences\x18\x01 \x01(\x0b\x32\x1c.RadioConfig.UserPreferences\x1a\xe0\x12\n\x0fUserPreferences\x12\x1f\n\x17position_broadcast_secs\x18\x01 \x01(\r\x12 \n\x18position_broadcast_smart\x18\x11 \x01(\x08\x12\x1b\n\x13send_owner_interval\x18\x02 \x01(\r\x12\x1b\n\x13wait_bluetooth_secs\x18\x04 \x01(\r\x12\x16\n\x0escreen_on_secs\x18\x05 \x01(\r\x12\x1a\n\x12phone_timeout_secs\x18\x06 \x01(\r\x12\x1d\n\x15phone_sds_timeout_sec\x18\x07 \x01(\r\x12\x1d\n\x15mesh_sds_timeout_secs\x18\x08 \x01(\r\x12\x10\n\x08sds_secs\x18\t \x01(\r\x12\x0f\n\x07ls_secs\x18\n \x01(\r\x12\x15\n\rmin_wake_secs\x18\x0b \x01(\r\x12\x11\n\twifi_ssid\x18\x0c \x01(\t\x12\x15\n\rwifi_password\x18\r \x01(\t\x12\x14\n\x0cwifi_ap_mode\x18\x0e \x01(\x08\x12\x1b\n\x06region\x18\x0f \x01(\x0e\x32\x0b.RegionCode\x12&\n\x0e\x63harge_current\x18\x10 \x01(\x0e\x32\x0e.ChargeCurrent\x12\x11\n\tis_router\x18% \x01(\x08\x12\x14\n\x0cis_low_power\x18& \x01(\x08\x12\x16\n\x0e\x66ixed_position\x18\' \x01(\x08\x12\x17\n\x0fserial_disabled\x18( \x01(\x08\x12(\n\x0elocation_share\x18 \x01(\x0e\x32\x10.LocationSharing\x12$\n\rgps_operation\x18! \x01(\x0e\x32\r.GpsOperation\x12\x1b\n\x13gps_update_interval\x18\" \x01(\r\x12\x18\n\x10gps_attempt_time\x18$ \x01(\r\x12\x15\n\rgps_accept_2d\x18- \x01(\x08\x12\x13\n\x0bgps_max_dop\x18. \x01(\r\x12\x18\n\x10\x66requency_offset\x18) \x01(\x02\x12\x13\n\x0bmqtt_server\x18* \x01(\t\x12\x15\n\rmqtt_disabled\x18+ \x01(\x08\x12(\n\ngps_format\x18, \x01(\x0e\x32\x14.GpsCoordinateFormat\x12\x15\n\rfactory_reset\x18\x64 \x01(\x08\x12\x19\n\x11\x64\x65\x62ug_log_enabled\x18\x65 \x01(\x08\x12\x17\n\x0fignore_incoming\x18g \x03(\r\x12\x1c\n\x14serialplugin_enabled\x18x \x01(\x08\x12\x19\n\x11serialplugin_echo\x18y \x01(\x08\x12\x18\n\x10serialplugin_rxd\x18z \x01(\r\x12\x18\n\x10serialplugin_txd\x18{ \x01(\r\x12\x1c\n\x14serialplugin_timeout\x18| \x01(\r\x12\x19\n\x11serialplugin_mode\x18} \x01(\r\x12\'\n\x1f\x65xt_notification_plugin_enabled\x18~ \x01(\x08\x12)\n!ext_notification_plugin_output_ms\x18\x7f \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_output\x18\x80\x01 \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_active\x18\x81\x01 \x01(\x08\x12.\n%ext_notification_plugin_alert_message\x18\x82\x01 \x01(\x08\x12+\n\"ext_notification_plugin_alert_bell\x18\x83\x01 \x01(\x08\x12\"\n\x19range_test_plugin_enabled\x18\x84\x01 \x01(\x08\x12!\n\x18range_test_plugin_sender\x18\x85\x01 \x01(\r\x12\x1f\n\x16range_test_plugin_save\x18\x86\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_enabled\x18\x94\x01 \x01(\x08\x12\'\n\x1estore_forward_plugin_heartbeat\x18\x95\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_records\x18\x89\x01 \x01(\r\x12\x30\n\'store_forward_plugin_history_return_max\x18\x8a\x01 \x01(\r\x12\x33\n*store_forward_plugin_history_return_window\x18\x8b\x01 \x01(\r\x12=\n4environmental_measurement_plugin_measurement_enabled\x18\x8c\x01 \x01(\x08\x12\x38\n/environmental_measurement_plugin_screen_enabled\x18\x8d\x01 \x01(\x08\x12\x44\n;environmental_measurement_plugin_read_error_count_threshold\x18\x8e\x01 \x01(\r\x12\x39\n0environmental_measurement_plugin_update_interval\x18\x8f\x01 \x01(\r\x12;\n2environmental_measurement_plugin_recovery_interval\x18\x90\x01 \x01(\r\x12;\n2environmental_measurement_plugin_display_farenheit\x18\x91\x01 \x01(\x08\x12v\n,environmental_measurement_plugin_sensor_type\x18\x92\x01 \x01(\x0e\x32?.RadioConfig.UserPreferences.EnvironmentalMeasurementSensorType\x12\x34\n+environmental_measurement_plugin_sensor_pin\x18\x93\x01 \x01(\r\x12\x17\n\x0eposition_flags\x18\x96\x01 \x01(\r\x12\x1a\n\x11is_always_powered\x18\x97\x01 \x01(\x08\x12\"\n\x19\x61uto_screen_carousel_secs\x18\x98\x01 \x01(\r\x12\'\n\x1eon_battery_shutdown_after_secs\x18\x99\x01 \x01(\r\"<\n\"EnvironmentalMeasurementSensorType\x12\t\n\x05\x44HT11\x10\x00\x12\x0b\n\x07\x44S18B20\x10\x01J\x06\x08\x88\x01\x10\x89\x01*f\n\nRegionCode\x12\t\n\x05Unset\x10\x00\x12\x06\n\x02US\x10\x01\x12\t\n\x05\x45U433\x10\x02\x12\t\n\x05\x45U865\x10\x03\x12\x06\n\x02\x43N\x10\x04\x12\x06\n\x02JP\x10\x05\x12\x07\n\x03\x41NZ\x10\x06\x12\x06\n\x02KR\x10\x07\x12\x06\n\x02TW\x10\x08\x12\x06\n\x02RU\x10\t*\xd1\x01\n\rChargeCurrent\x12\x0b\n\x07MAUnset\x10\x00\x12\t\n\x05MA100\x10\x01\x12\t\n\x05MA190\x10\x02\x12\t\n\x05MA280\x10\x03\x12\t\n\x05MA360\x10\x04\x12\t\n\x05MA450\x10\x05\x12\t\n\x05MA550\x10\x06\x12\t\n\x05MA630\x10\x07\x12\t\n\x05MA700\x10\x08\x12\t\n\x05MA780\x10\t\x12\t\n\x05MA880\x10\n\x12\t\n\x05MA960\x10\x0b\x12\n\n\x06MA1000\x10\x0c\x12\n\n\x06MA1080\x10\r\x12\n\n\x06MA1160\x10\x0e\x12\n\n\x06MA1240\x10\x0f\x12\n\n\x06MA1320\x10\x10*j\n\x0cGpsOperation\x12\x0e\n\nGpsOpUnset\x10\x00\x12\x13\n\x0fGpsOpStationary\x10\x01\x12\x0f\n\x0bGpsOpMobile\x10\x02\x12\x11\n\rGpsOpTimeOnly\x10\x03\x12\x11\n\rGpsOpDisabled\x10\x04*\x83\x01\n\x13GpsCoordinateFormat\x12\x10\n\x0cGpsFormatDec\x10\x00\x12\x10\n\x0cGpsFormatDMS\x10\x01\x12\x10\n\x0cGpsFormatUTM\x10\x02\x12\x11\n\rGpsFormatMGRS\x10\x03\x12\x10\n\x0cGpsFormatOLC\x10\x04\x12\x11\n\rGpsFormatOSGR\x10\x05*@\n\x0fLocationSharing\x12\x0c\n\x08LocUnset\x10\x00\x12\x0e\n\nLocEnabled\x10\x01\x12\x0f\n\x0bLocDisabled\x10\x02*\xbc\x01\n\rPositionFlags\x12\x11\n\rPOS_UNDEFINED\x10\x00\x12\x10\n\x0cPOS_ALTITUDE\x10\x01\x12\x0f\n\x0bPOS_ALT_MSL\x10\x02\x12\x0f\n\x0bPOS_GEO_SEP\x10\x04\x12\x0b\n\x07POS_DOP\x10\x08\x12\r\n\tPOS_HVDOP\x10\x10\x12\x0f\n\x0bPOS_BATTERY\x10 \x12\x11\n\rPOS_SATINVIEW\x10@\x12\x10\n\x0bPOS_SEQ_NOS\x10\x80\x01\x12\x12\n\rPOS_TIMESTAMP\x10\x80\x02\x42M\n\x13\x63om.geeksville.meshB\x11RadioConfigProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' ) _REGIONCODE = _descriptor.EnumDescriptor( @@ -71,8 +71,8 @@ _REGIONCODE = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2450, - serialized_end=2552, + serialized_start=2491, + serialized_end=2593, ) _sym_db.RegisterEnumDescriptor(_REGIONCODE) @@ -154,8 +154,8 @@ _CHARGECURRENT = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2555, - serialized_end=2764, + serialized_start=2596, + serialized_end=2805, ) _sym_db.RegisterEnumDescriptor(_CHARGECURRENT) @@ -189,8 +189,8 @@ _GPSOPERATION = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2766, - serialized_end=2872, + serialized_start=2807, + serialized_end=2913, ) _sym_db.RegisterEnumDescriptor(_GPSOPERATION) @@ -228,8 +228,8 @@ _GPSCOORDINATEFORMAT = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2875, - serialized_end=3006, + serialized_start=2916, + serialized_end=3047, ) _sym_db.RegisterEnumDescriptor(_GPSCOORDINATEFORMAT) @@ -255,8 +255,8 @@ _LOCATIONSHARING = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3008, - serialized_end=3072, + serialized_start=3049, + serialized_end=3113, ) _sym_db.RegisterEnumDescriptor(_LOCATIONSHARING) @@ -310,8 +310,8 @@ _POSITIONFLAGS = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3075, - serialized_end=3263, + serialized_start=3116, + serialized_end=3304, ) _sym_db.RegisterEnumDescriptor(_POSITIONFLAGS) @@ -386,8 +386,8 @@ _RADIOCONFIG_USERPREFERENCES_ENVIRONMENTALMEASUREMENTSENSORTYPE = _descriptor.En ], containing_type=None, serialized_options=None, - serialized_start=2380, - serialized_end=2440, + serialized_start=2421, + serialized_end=2481, ) _sym_db.RegisterEnumDescriptor(_RADIOCONFIG_USERPREFERENCES_ENVIRONMENTALMEASUREMENTSENSORTYPE) @@ -847,6 +847,13 @@ _RADIOCONFIG_USERPREFERENCES = _descriptor.Descriptor( message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR), + _descriptor.FieldDescriptor( + name='on_battery_shutdown_after_secs', full_name='RadioConfig.UserPreferences.on_battery_shutdown_after_secs', index=64, + number=153, type=13, cpp_type=3, label=1, + has_default_value=False, default_value=0, + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), ], extensions=[ ], @@ -861,7 +868,7 @@ _RADIOCONFIG_USERPREFERENCES = _descriptor.Descriptor( oneofs=[ ], serialized_start=89, - serialized_end=2448, + serialized_end=2489, ) _RADIOCONFIG = _descriptor.Descriptor( @@ -891,7 +898,7 @@ _RADIOCONFIG = _descriptor.Descriptor( oneofs=[ ], serialized_start=22, - serialized_end=2448, + serialized_end=2489, ) _RADIOCONFIG_USERPREFERENCES.fields_by_name['region'].enum_type = _REGIONCODE From 6896e70c314cd6280e2ecf36a7add89a192b4545 Mon Sep 17 00:00:00 2001 From: Jm Casler Date: Mon, 6 Dec 2021 17:48:18 -0800 Subject: [PATCH 4/4] Updated docs for mt py --- docs/meshtastic/admin_pb2.html | 6 +- docs/meshtastic/channel_pb2.html | 34 +++- docs/meshtastic/deviceonly_pb2.html | 6 +- docs/meshtastic/index.html | 170 +++++++++------- docs/meshtastic/mesh_pb2.html | 70 ++++--- docs/meshtastic/node.html | 59 +++--- docs/meshtastic/radioconfig_pb2.html | 41 ++-- docs/meshtastic/remote_hardware.html | 8 +- docs/meshtastic/storeforward_pb2.html | 269 +++++++++++++------------- docs/meshtastic/test.html | 47 +++-- docs/meshtastic/tunnel.html | 38 +++- docs/meshtastic/util.html | 33 +++- 12 files changed, 454 insertions(+), 327 deletions(-) diff --git a/docs/meshtastic/admin_pb2.html b/docs/meshtastic/admin_pb2.html index 4e48e0b..20b1262 100644 --- a/docs/meshtastic/admin_pb2.html +++ b/docs/meshtastic/admin_pb2.html @@ -39,9 +39,9 @@ from google.protobuf import symbol_database as _symbol_database _sym_db = _symbol_database.Default() +from . import channel_pb2 as channel__pb2 from . import mesh_pb2 as mesh__pb2 from . import radioconfig_pb2 as radioconfig__pb2 -from . import channel_pb2 as channel__pb2 DESCRIPTOR = _descriptor.FileDescriptor( @@ -49,9 +49,9 @@ DESCRIPTOR = _descriptor.FileDescriptor( package='', syntax='proto3', serialized_options=b'\n\023com.geeksville.meshB\013AdminProtosH\003Z!github.com/meshtastic/gomeshproto', - serialized_pb=b'\n\x0b\x61\x64min.proto\x1a\nmesh.proto\x1a\x11radioconfig.proto\x1a\rchannel.proto\"\xfb\x02\n\x0c\x41\x64minMessage\x12!\n\tset_radio\x18\x01 \x01(\x0b\x32\x0c.RadioConfigH\x00\x12\x1a\n\tset_owner\x18\x02 \x01(\x0b\x32\x05.UserH\x00\x12\x1f\n\x0bset_channel\x18\x03 \x01(\x0b\x32\x08.ChannelH\x00\x12\x1b\n\x11get_radio_request\x18\x04 \x01(\x08H\x00\x12*\n\x12get_radio_response\x18\x05 \x01(\x0b\x32\x0c.RadioConfigH\x00\x12\x1d\n\x13get_channel_request\x18\x06 \x01(\rH\x00\x12(\n\x14get_channel_response\x18\x07 \x01(\x0b\x32\x08.ChannelH\x00\x12\x1d\n\x13\x63onfirm_set_channel\x18 \x01(\x08H\x00\x12\x1b\n\x11\x63onfirm_set_radio\x18! \x01(\x08H\x00\x12\x18\n\x0e\x65xit_simulator\x18\" \x01(\x08H\x00\x12\x18\n\x0ereboot_seconds\x18# \x01(\x05H\x00\x42\t\n\x07variantBG\n\x13\x63om.geeksville.meshB\x0b\x41\x64minProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' + serialized_pb=b'\n\x0b\x61\x64min.proto\x1a\rchannel.proto\x1a\nmesh.proto\x1a\x11radioconfig.proto\"\xfb\x02\n\x0c\x41\x64minMessage\x12!\n\tset_radio\x18\x01 \x01(\x0b\x32\x0c.RadioConfigH\x00\x12\x1a\n\tset_owner\x18\x02 \x01(\x0b\x32\x05.UserH\x00\x12\x1f\n\x0bset_channel\x18\x03 \x01(\x0b\x32\x08.ChannelH\x00\x12\x1b\n\x11get_radio_request\x18\x04 \x01(\x08H\x00\x12*\n\x12get_radio_response\x18\x05 \x01(\x0b\x32\x0c.RadioConfigH\x00\x12\x1d\n\x13get_channel_request\x18\x06 \x01(\rH\x00\x12(\n\x14get_channel_response\x18\x07 \x01(\x0b\x32\x08.ChannelH\x00\x12\x1d\n\x13\x63onfirm_set_channel\x18 \x01(\x08H\x00\x12\x1b\n\x11\x63onfirm_set_radio\x18! \x01(\x08H\x00\x12\x18\n\x0e\x65xit_simulator\x18\" \x01(\x08H\x00\x12\x18\n\x0ereboot_seconds\x18# \x01(\x05H\x00\x42\t\n\x07variantBG\n\x13\x63om.geeksville.meshB\x0b\x41\x64minProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' , - dependencies=[mesh__pb2.DESCRIPTOR,radioconfig__pb2.DESCRIPTOR,channel__pb2.DESCRIPTOR,]) + dependencies=[channel__pb2.DESCRIPTOR,mesh__pb2.DESCRIPTOR,radioconfig__pb2.DESCRIPTOR,]) diff --git a/docs/meshtastic/channel_pb2.html b/docs/meshtastic/channel_pb2.html index 7bc29a1..f717c6d 100644 --- a/docs/meshtastic/channel_pb2.html +++ b/docs/meshtastic/channel_pb2.html @@ -46,7 +46,7 @@ DESCRIPTOR = _descriptor.FileDescriptor( package='', syntax='proto3', serialized_options=b'\n\023com.geeksville.meshB\rChannelProtosH\003Z!github.com/meshtastic/gomeshproto', - serialized_pb=b'\n\rchannel.proto\"\xe6\x02\n\x0f\x43hannelSettings\x12\x10\n\x08tx_power\x18\x01 \x01(\x05\x12\x32\n\x0cmodem_config\x18\x03 \x01(\x0e\x32\x1c.ChannelSettings.ModemConfig\x12\x11\n\tbandwidth\x18\x06 \x01(\r\x12\x15\n\rspread_factor\x18\x07 \x01(\r\x12\x13\n\x0b\x63oding_rate\x18\x08 \x01(\r\x12\x13\n\x0b\x63hannel_num\x18\t \x01(\r\x12\x0b\n\x03psk\x18\x04 \x01(\x0c\x12\x0c\n\x04name\x18\x05 \x01(\t\x12\n\n\x02id\x18\n \x01(\x07\x12\x16\n\x0euplink_enabled\x18\x10 \x01(\x08\x12\x18\n\x10\x64ownlink_enabled\x18\x11 \x01(\x08\"`\n\x0bModemConfig\x12\x12\n\x0e\x42w125Cr45Sf128\x10\x00\x12\x12\n\x0e\x42w500Cr45Sf128\x10\x01\x12\x14\n\x10\x42w31_25Cr48Sf512\x10\x02\x12\x13\n\x0f\x42w125Cr48Sf4096\x10\x03\"\x8b\x01\n\x07\x43hannel\x12\r\n\x05index\x18\x01 \x01(\x05\x12\"\n\x08settings\x18\x02 \x01(\x0b\x32\x10.ChannelSettings\x12\x1b\n\x04role\x18\x03 \x01(\x0e\x32\r.Channel.Role\"0\n\x04Role\x12\x0c\n\x08\x44ISABLED\x10\x00\x12\x0b\n\x07PRIMARY\x10\x01\x12\r\n\tSECONDARY\x10\x02\x42I\n\x13\x63om.geeksville.meshB\rChannelProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' + serialized_pb=b'\n\rchannel.proto\"\x91\x03\n\x0f\x43hannelSettings\x12\x10\n\x08tx_power\x18\x01 \x01(\x05\x12\x32\n\x0cmodem_config\x18\x03 \x01(\x0e\x32\x1c.ChannelSettings.ModemConfig\x12\x11\n\tbandwidth\x18\x06 \x01(\r\x12\x15\n\rspread_factor\x18\x07 \x01(\r\x12\x13\n\x0b\x63oding_rate\x18\x08 \x01(\r\x12\x13\n\x0b\x63hannel_num\x18\t \x01(\r\x12\x0b\n\x03psk\x18\x04 \x01(\x0c\x12\x0c\n\x04name\x18\x05 \x01(\t\x12\n\n\x02id\x18\n \x01(\x07\x12\x16\n\x0euplink_enabled\x18\x10 \x01(\x08\x12\x18\n\x10\x64ownlink_enabled\x18\x11 \x01(\x08\"\x8a\x01\n\x0bModemConfig\x12\x12\n\x0e\x42w125Cr45Sf128\x10\x00\x12\x12\n\x0e\x42w500Cr45Sf128\x10\x01\x12\x14\n\x10\x42w31_25Cr48Sf512\x10\x02\x12\x13\n\x0f\x42w125Cr48Sf4096\x10\x03\x12\x13\n\x0f\x42w250Cr46Sf2048\x10\x04\x12\x13\n\x0f\x42w250Cr47Sf1024\x10\x05\"\x8b\x01\n\x07\x43hannel\x12\r\n\x05index\x18\x01 \x01(\x05\x12\"\n\x08settings\x18\x02 \x01(\x0b\x32\x10.ChannelSettings\x12\x1b\n\x04role\x18\x03 \x01(\x0e\x32\r.Channel.Role\"0\n\x04Role\x12\x0c\n\x08\x44ISABLED\x10\x00\x12\x0b\n\x07PRIMARY\x10\x01\x12\r\n\tSECONDARY\x10\x02\x42I\n\x13\x63om.geeksville.meshB\rChannelProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' ) @@ -73,11 +73,19 @@ _CHANNELSETTINGS_MODEMCONFIG = _descriptor.EnumDescriptor( name='Bw125Cr48Sf4096', index=3, number=3, serialized_options=None, type=None), + _descriptor.EnumValueDescriptor( + name='Bw250Cr46Sf2048', index=4, number=4, + serialized_options=None, + type=None), + _descriptor.EnumValueDescriptor( + name='Bw250Cr47Sf1024', index=5, number=5, + serialized_options=None, + type=None), ], containing_type=None, serialized_options=None, - serialized_start=280, - serialized_end=376, + serialized_start=281, + serialized_end=419, ) _sym_db.RegisterEnumDescriptor(_CHANNELSETTINGS_MODEMCONFIG) @@ -102,8 +110,8 @@ _CHANNEL_ROLE = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=470, - serialized_end=518, + serialized_start=513, + serialized_end=561, ) _sym_db.RegisterEnumDescriptor(_CHANNEL_ROLE) @@ -206,7 +214,7 @@ _CHANNELSETTINGS = _descriptor.Descriptor( oneofs=[ ], serialized_start=18, - serialized_end=376, + serialized_end=419, ) @@ -251,8 +259,8 @@ _CHANNEL = _descriptor.Descriptor( extension_ranges=[], oneofs=[ ], - serialized_start=379, - serialized_end=518, + serialized_start=422, + serialized_end=561, ) _CHANNELSETTINGS.fields_by_name['modem_config'].enum_type = _CHANNELSETTINGS_MODEMCONFIG @@ -915,6 +923,14 @@ shown below.

+
var Bw250Cr46Sf2048
+
+
+
+
var Bw250Cr47Sf1024
+
+
+
var Bw31_25Cr48Sf512
@@ -1667,6 +1683,8 @@ and propagates this to our listener iff this was a state change.

  • BANDWIDTH_FIELD_NUMBER
  • Bw125Cr45Sf128
  • Bw125Cr48Sf4096
  • +
  • Bw250Cr46Sf2048
  • +
  • Bw250Cr47Sf1024
  • Bw31_25Cr48Sf512
  • Bw500Cr45Sf128
  • ByteSize
  • diff --git a/docs/meshtastic/deviceonly_pb2.html b/docs/meshtastic/deviceonly_pb2.html index 09d7afc..6b4df19 100644 --- a/docs/meshtastic/deviceonly_pb2.html +++ b/docs/meshtastic/deviceonly_pb2.html @@ -39,8 +39,8 @@ from google.protobuf import symbol_database as _symbol_database _sym_db = _symbol_database.Default() -from . import mesh_pb2 as mesh__pb2 from . import channel_pb2 as channel__pb2 +from . import mesh_pb2 as mesh__pb2 from . import radioconfig_pb2 as radioconfig__pb2 @@ -49,9 +49,9 @@ DESCRIPTOR = _descriptor.FileDescriptor( package='', syntax='proto3', serialized_options=b'\n\023com.geeksville.meshB\nDeviceOnlyH\003Z!github.com/meshtastic/gomeshproto', - serialized_pb=b'\n\x10\x64\x65viceonly.proto\x1a\nmesh.proto\x1a\rchannel.proto\x1a\x11radioconfig.proto\"\x80\x01\n\x11LegacyRadioConfig\x12\x39\n\x0bpreferences\x18\x01 \x01(\x0b\x32$.LegacyRadioConfig.LegacyPreferences\x1a\x30\n\x11LegacyPreferences\x12\x1b\n\x06region\x18\x0f \x01(\x0e\x32\x0b.RegionCode\"\x8f\x02\n\x0b\x44\x65viceState\x12\'\n\x0blegacyRadio\x18\x01 \x01(\x0b\x32\x12.LegacyRadioConfig\x12\x1c\n\x07my_node\x18\x02 \x01(\x0b\x32\x0b.MyNodeInfo\x12\x14\n\x05owner\x18\x03 \x01(\x0b\x32\x05.User\x12\x1a\n\x07node_db\x18\x04 \x03(\x0b\x32\t.NodeInfo\x12\"\n\rreceive_queue\x18\x05 \x03(\x0b\x32\x0b.MeshPacket\x12\x0f\n\x07version\x18\x08 \x01(\r\x12$\n\x0frx_text_message\x18\x07 \x01(\x0b\x32\x0b.MeshPacket\x12\x0f\n\x07no_save\x18\t \x01(\x08\x12\x15\n\rdid_gps_reset\x18\x0b \x01(\x08J\x04\x08\x0c\x10\r\")\n\x0b\x43hannelFile\x12\x1a\n\x08\x63hannels\x18\x01 \x03(\x0b\x32\x08.ChannelBF\n\x13\x63om.geeksville.meshB\nDeviceOnlyH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' + serialized_pb=b'\n\x10\x64\x65viceonly.proto\x1a\rchannel.proto\x1a\nmesh.proto\x1a\x11radioconfig.proto\"\x80\x01\n\x11LegacyRadioConfig\x12\x39\n\x0bpreferences\x18\x01 \x01(\x0b\x32$.LegacyRadioConfig.LegacyPreferences\x1a\x30\n\x11LegacyPreferences\x12\x1b\n\x06region\x18\x0f \x01(\x0e\x32\x0b.RegionCode\"\x8f\x02\n\x0b\x44\x65viceState\x12\'\n\x0blegacyRadio\x18\x01 \x01(\x0b\x32\x12.LegacyRadioConfig\x12\x1c\n\x07my_node\x18\x02 \x01(\x0b\x32\x0b.MyNodeInfo\x12\x14\n\x05owner\x18\x03 \x01(\x0b\x32\x05.User\x12\x1a\n\x07node_db\x18\x04 \x03(\x0b\x32\t.NodeInfo\x12\"\n\rreceive_queue\x18\x05 \x03(\x0b\x32\x0b.MeshPacket\x12\x0f\n\x07version\x18\x08 \x01(\r\x12$\n\x0frx_text_message\x18\x07 \x01(\x0b\x32\x0b.MeshPacket\x12\x0f\n\x07no_save\x18\t \x01(\x08\x12\x15\n\rdid_gps_reset\x18\x0b \x01(\x08J\x04\x08\x0c\x10\r\")\n\x0b\x43hannelFile\x12\x1a\n\x08\x63hannels\x18\x01 \x03(\x0b\x32\x08.ChannelBF\n\x13\x63om.geeksville.meshB\nDeviceOnlyH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' , - dependencies=[mesh__pb2.DESCRIPTOR,channel__pb2.DESCRIPTOR,radioconfig__pb2.DESCRIPTOR,]) + dependencies=[channel__pb2.DESCRIPTOR,mesh__pb2.DESCRIPTOR,radioconfig__pb2.DESCRIPTOR,]) diff --git a/docs/meshtastic/index.html b/docs/meshtastic/index.html index 800f161..b32c90d 100644 --- a/docs/meshtastic/index.html +++ b/docs/meshtastic/index.html @@ -115,10 +115,10 @@ type of packet, you should subscribe to the full topic name. If you want to see - meshtastic.receive.data.portnum(packet) (where portnum is an integer or well known PortNum enum) - meshtastic.node.updated(node = NodeInfo) - published when a node in the DB changes (appears, location changed, username changed, etc...) -We receive position, user, or data packets from the mesh. You probably only care about meshtastic.receive.data. The first argument for -that publish will be the packet. Text or binary data packets (from sendData or sendText) will both arrive this way. If you print packet -you'll see the fields in the dictionary. decoded.data.payload will contain the raw bytes that were sent. If the packet was sent with -sendText, decoded.data.text will **also** be populated with the decoded string. For ASCII these two strings will be the same, but for +We receive position, user, or data packets from the mesh. You probably only care about meshtastic.receive.data. The first argument for +that publish will be the packet. Text or binary data packets (from sendData or sendText) will both arrive this way. If you print packet +you'll see the fields in the dictionary. decoded.data.payload will contain the raw bytes that were sent. If the packet was sent with +sendText, decoded.data.text will **also** be populated with the decoded string. For ASCII these two strings will be the same, but for unicode scripts they can be different. # Example Usage @@ -142,30 +142,30 @@ interface = meshtastic.SerialInterface() """ -import pygatt -import google.protobuf.json_format -import serial -import threading +import base64 import logging -import sys +import os +import platform import random +import socket +import sys +import stat +import threading import traceback import time -import base64 -import platform -import socket +from datetime import datetime +from typing import * +import serial import timeago -import os -import stat -from . import mesh_pb2, portnums_pb2, apponly_pb2, admin_pb2, environmental_measurement_pb2, remote_hardware_pb2, channel_pb2, radioconfig_pb2, util -from .util import fixme, catchAndIgnore, stripnl, DeferredExecution, Timeout -from .node import Node +import google.protobuf.json_format +import pygatt from pubsub import pub from dotmap import DotMap -from datetime import datetime from tabulate import tabulate -from typing import * from google.protobuf.json_format import MessageToJson +from .util import fixme, catchAndIgnore, stripnl, DeferredExecution, Timeout +from .node import Node +from . import mesh_pb2, portnums_pb2, apponly_pb2, admin_pb2, environmental_measurement_pb2, remote_hardware_pb2, channel_pb2, radioconfig_pb2, util START1 = 0x94 START2 = 0xc3 @@ -359,7 +359,7 @@ class MeshInterface: wantResponse=wantResponse, hopLimit=hopLimit, onResponse=onResponse, - channelIndex=channelIndex); + channelIndex=channelIndex) def sendData(self, data, destinationId=BROADCAST_ADDR, portNum=portnums_pb2.PortNum.PRIVATE_APP, wantAck=False, @@ -375,7 +375,8 @@ class MeshInterface: portNum -- the application portnum (similar to IP port numbers) of the destination, see portnums.proto for a list wantAck -- True if you want the message sent in a reliable manner (with retries and ack/nak provided for delivery) wantResponse -- True if you want the service on the other side to send an application layer response - onResponse -- A closure of the form funct(packet), that will be called when a response packet arrives (or the transaction is NAKed due to non receipt) + onResponse -- A closure of the form funct(packet), that will be called when a response packet arrives + (or the transaction is NAKed due to non receipt) Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ @@ -413,13 +414,13 @@ class MeshInterface: Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ p = mesh_pb2.Position() - if(latitude != 0.0): + if latitude != 0.0: p.latitude_i = int(latitude / 1e-7) - if(longitude != 0.0): + if longitude != 0.0: p.longitude_i = int(longitude / 1e-7) - if(altitude != 0): + if altitude != 0: p.altitude = int(altitude) if timeSec == 0: @@ -440,7 +441,7 @@ class MeshInterface: """Send a MeshPacket to the specified node (or if unspecified, broadcast). You probably don't want this - use sendData instead. - Returns the sent packet. The id field will be populated in this packet and + Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ @@ -489,23 +490,27 @@ class MeshInterface: raise Exception("Timed out waiting for interface config") def getMyNodeInfo(self): + """Get info about my node.""" if self.myInfo is None: return None return self.nodesByNum.get(self.myInfo.my_node_num) def getMyUser(self): + """Get user""" nodeInfo = self.getMyNodeInfo() if nodeInfo is not None: return nodeInfo.get('user') return None def getLongName(self): + """Get long name""" user = self.getMyUser() if user is not None: return user.get('longName', None) return None def getShortName(self): + """Get short name""" user = self.getMyUser() if user is not None: return user.get('shortName', None) @@ -839,7 +844,7 @@ class StreamInterface(MeshInterface): """Interface class for meshtastic devices over a stream link (serial, TCP, etc)""" def __init__(self, debugOut=None, noProto=False, connectNow=True): - """Constructor, opens a connection to self.stream + """Constructor, opens a connection to self.stream Keyword Arguments: devPath {string} -- A filepath to a device, i.e. /dev/ttyUSB0 (default: {None}) @@ -1019,7 +1024,7 @@ class SerialInterface(StreamInterface): # rts=False Needed to prevent TBEAMs resetting on OSX, because rts is connected to reset self.stream.port = devPath - + # HACK: If the platform driving the serial port is unable to leave the RTS pin in high-impedance # mode, set RTS to false so that the device platform won't be reset spuriously. # Linux does this properly, so don't apply this hack on Linux (because it makes the reset button not work). @@ -1029,30 +1034,30 @@ class SerialInterface(StreamInterface): StreamInterface.__init__( self, debugOut=debugOut, noProto=noProto, connectNow=connectNow) - + """true if platform driving the serial port is Windows Subsystem for Linux 1.""" def _isWsl1(self): - # WSL1 identifies itself as Linux, but has a special char device at /dev/lxss for use with session control, - # e.g. /init. We should treat WSL1 as Windows for the RTS-driving hack because the underlying platfrom + # WSL1 identifies itself as Linux, but has a special char device at /dev/lxss for use with session control, + # e.g. /init. We should treat WSL1 as Windows for the RTS-driving hack because the underlying platfrom # serial driver for the CP21xx still exhibits the buggy behavior. - # WSL2 is not covered here, as it does not (as of 2021-May-25) support the appropriate functionality to + # WSL2 is not covered here, as it does not (as of 2021-May-25) support the appropriate functionality to # share or pass-through serial ports. try: # Claims to be Linux, but has /dev/lxss; must be WSL 1 - return platform.system() == 'Linux' and stat.S_ISCHR(os.stat('/dev/lxss').st_mode); + return platform.system() == 'Linux' and stat.S_ISCHR(os.stat('/dev/lxss').st_mode) except: # Couldn't stat /dev/lxss special device; not WSL1 - return False; - + return False + def _hostPlatformAlwaysDrivesUartRts(self): # OS-X/Windows seems to have a bug in its CP21xx serial drivers. It ignores that we asked for no RTSCTS # control and will always drive RTS either high or low (rather than letting the CP102 leave # it as an open-collector floating pin). - # TODO: When WSL2 supports USB passthrough, this will get messier. If/when WSL2 gets virtual serial - # ports that "share" the Windows serial port (and thus the Windows drivers), this code will need to be + # TODO: When WSL2 supports USB passthrough, this will get messier. If/when WSL2 gets virtual serial + # ports that "share" the Windows serial port (and thus the Windows drivers), this code will need to be # updated to reflect that as well -- or if T-Beams get made with an alternate USB to UART bridge that has # a less buggy driver. - return platform.system() != 'Linux' or self._isWsl1(); + return platform.system() != 'Linux' or self._isWsl1() class TCPInterface(StreamInterface): """Interface class for meshtastic devices over a TCP link""" @@ -1217,15 +1222,15 @@ protocols = {
    meshtastic.test
    -
    +

    Testing

    meshtastic.tunnel
    -
    +

    Code for IP tunnel over a mesh …

    meshtastic.util
    -
    +

    Utility functions.

    @@ -1312,7 +1317,11 @@ noProto – If True, don't try to run our protocol on the link - just be a d
  • MeshInterface:
    • close
    • +
    • getLongName
    • +
    • getMyNodeInfo
    • +
    • getMyUser
    • getNode
    • +
    • getShortName
    • sendData
    • sendPosition
    • sendText
    • @@ -1530,7 +1539,7 @@ noProto – If True, don't try to run our protocol on the link - just be a d wantResponse=wantResponse, hopLimit=hopLimit, onResponse=onResponse, - channelIndex=channelIndex); + channelIndex=channelIndex) def sendData(self, data, destinationId=BROADCAST_ADDR, portNum=portnums_pb2.PortNum.PRIVATE_APP, wantAck=False, @@ -1546,7 +1555,8 @@ noProto – If True, don't try to run our protocol on the link - just be a d portNum -- the application portnum (similar to IP port numbers) of the destination, see portnums.proto for a list wantAck -- True if you want the message sent in a reliable manner (with retries and ack/nak provided for delivery) wantResponse -- True if you want the service on the other side to send an application layer response - onResponse -- A closure of the form funct(packet), that will be called when a response packet arrives (or the transaction is NAKed due to non receipt) + onResponse -- A closure of the form funct(packet), that will be called when a response packet arrives + (or the transaction is NAKed due to non receipt) Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ @@ -1584,13 +1594,13 @@ noProto – If True, don't try to run our protocol on the link - just be a d Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ p = mesh_pb2.Position() - if(latitude != 0.0): + if latitude != 0.0: p.latitude_i = int(latitude / 1e-7) - if(longitude != 0.0): + if longitude != 0.0: p.longitude_i = int(longitude / 1e-7) - if(altitude != 0): + if altitude != 0: p.altitude = int(altitude) if timeSec == 0: @@ -1611,7 +1621,7 @@ noProto – If True, don't try to run our protocol on the link - just be a d """Send a MeshPacket to the specified node (or if unspecified, broadcast). You probably don't want this - use sendData instead. - Returns the sent packet. The id field will be populated in this packet and + Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ @@ -1660,23 +1670,27 @@ noProto – If True, don't try to run our protocol on the link - just be a d raise Exception("Timed out waiting for interface config") def getMyNodeInfo(self): + """Get info about my node.""" if self.myInfo is None: return None return self.nodesByNum.get(self.myInfo.my_node_num) def getMyUser(self): + """Get user""" nodeInfo = self.getMyNodeInfo() if nodeInfo is not None: return nodeInfo.get('user') return None def getLongName(self): + """Get long name""" user = self.getMyUser() if user is not None: return user.get('longName', None) return None def getShortName(self): + """Get short name""" user = self.getMyUser() if user is not None: return user.get('shortName', None) @@ -1988,12 +2002,13 @@ noProto – If True, don't try to run our protocol on the link - just be a d def getLongName(self)
      -
      +

      Get long name

      Expand source code
      def getLongName(self):
      +    """Get long name"""
           user = self.getMyUser()
           if user is not None:
               return user.get('longName', None)
      @@ -2004,12 +2019,13 @@ noProto – If True, don't try to run our protocol on the link - just be a d
       def getMyNodeInfo(self)
       
       
      -
      +

      Get info about my node.

      Expand source code
      def getMyNodeInfo(self):
      +    """Get info about my node."""
           if self.myInfo is None:
               return None
           return self.nodesByNum.get(self.myInfo.my_node_num)
      @@ -2019,12 +2035,13 @@ noProto – If True, don't try to run our protocol on the link - just be a d def getMyUser(self)
      -
      +

      Get user

      Expand source code
      def getMyUser(self):
      +    """Get user"""
           nodeInfo = self.getMyNodeInfo()
           if nodeInfo is not None:
               return nodeInfo.get('user')
      @@ -2056,12 +2073,13 @@ noProto – If True, don't try to run our protocol on the link - just be a d
       def getShortName(self)
       
       
      -
      +

      Get short name

      Expand source code
      def getShortName(self):
      +    """Get short name"""
           user = self.getMyUser()
           if user is not None:
               return user.get('shortName', None)
      @@ -2079,7 +2097,8 @@ destinationId {nodeId or nodeNum} – where to send this message (default: {
       portNum – the application portnum (similar to IP port numbers) of the destination, see portnums.proto for a list
       wantAck – True if you want the message sent in a reliable manner (with retries and ack/nak provided for delivery)
       wantResponse – True if you want the service on the other side to send an application layer response
      -onResponse – A closure of the form funct(packet), that will be called when a response packet arrives (or the transaction is NAKed due to non receipt)

      +onResponse – A closure of the form funct(packet), that will be called when a response packet arrives +(or the transaction is NAKed due to non receipt)

      Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks.

      @@ -2099,7 +2118,8 @@ onResponse – A closure of the form funct(packet), that will be called when portNum -- the application portnum (similar to IP port numbers) of the destination, see portnums.proto for a list wantAck -- True if you want the message sent in a reliable manner (with retries and ack/nak provided for delivery) wantResponse -- True if you want the service on the other side to send an application layer response - onResponse -- A closure of the form funct(packet), that will be called when a response packet arrives (or the transaction is NAKed due to non receipt) + onResponse -- A closure of the form funct(packet), that will be called when a response packet arrives + (or the transaction is NAKed due to non receipt) Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ @@ -2151,13 +2171,13 @@ the local position.

      Returns the sent packet. The id field will be populated in this packet and can be used to track future message acks/naks. """ p = mesh_pb2.Position() - if(latitude != 0.0): + if latitude != 0.0: p.latitude_i = int(latitude / 1e-7) - if(longitude != 0.0): + if longitude != 0.0: p.longitude_i = int(longitude / 1e-7) - if(altitude != 0): + if altitude != 0: p.altitude = int(altitude) if timeSec == 0: @@ -2213,7 +2233,7 @@ wantResponse – True if you want the service on the other side to send an a wantResponse=wantResponse, hopLimit=hopLimit, onResponse=onResponse, - channelIndex=channelIndex);
      + channelIndex=channelIndex)
      @@ -2394,7 +2414,7 @@ debugOut {stream} – If a stream is provided, any debug serial output from # rts=False Needed to prevent TBEAMs resetting on OSX, because rts is connected to reset self.stream.port = devPath - + # HACK: If the platform driving the serial port is unable to leave the RTS pin in high-impedance # mode, set RTS to false so that the device platform won't be reset spuriously. # Linux does this properly, so don't apply this hack on Linux (because it makes the reset button not work). @@ -2404,30 +2424,30 @@ debugOut {stream} – If a stream is provided, any debug serial output from StreamInterface.__init__( self, debugOut=debugOut, noProto=noProto, connectNow=connectNow) - + """true if platform driving the serial port is Windows Subsystem for Linux 1.""" def _isWsl1(self): - # WSL1 identifies itself as Linux, but has a special char device at /dev/lxss for use with session control, - # e.g. /init. We should treat WSL1 as Windows for the RTS-driving hack because the underlying platfrom + # WSL1 identifies itself as Linux, but has a special char device at /dev/lxss for use with session control, + # e.g. /init. We should treat WSL1 as Windows for the RTS-driving hack because the underlying platfrom # serial driver for the CP21xx still exhibits the buggy behavior. - # WSL2 is not covered here, as it does not (as of 2021-May-25) support the appropriate functionality to + # WSL2 is not covered here, as it does not (as of 2021-May-25) support the appropriate functionality to # share or pass-through serial ports. try: # Claims to be Linux, but has /dev/lxss; must be WSL 1 - return platform.system() == 'Linux' and stat.S_ISCHR(os.stat('/dev/lxss').st_mode); + return platform.system() == 'Linux' and stat.S_ISCHR(os.stat('/dev/lxss').st_mode) except: # Couldn't stat /dev/lxss special device; not WSL1 - return False; - + return False + def _hostPlatformAlwaysDrivesUartRts(self): # OS-X/Windows seems to have a bug in its CP21xx serial drivers. It ignores that we asked for no RTSCTS # control and will always drive RTS either high or low (rather than letting the CP102 leave # it as an open-collector floating pin). - # TODO: When WSL2 supports USB passthrough, this will get messier. If/when WSL2 gets virtual serial - # ports that "share" the Windows serial port (and thus the Windows drivers), this code will need to be + # TODO: When WSL2 supports USB passthrough, this will get messier. If/when WSL2 gets virtual serial + # ports that "share" the Windows serial port (and thus the Windows drivers), this code will need to be # updated to reflect that as well -- or if T-Beams get made with an alternate USB to UART bridge that has # a less buggy driver. - return platform.system() != 'Linux' or self._isWsl1();
      + return platform.system() != 'Linux' or self._isWsl1()

      Ancestors

        @@ -2440,7 +2460,11 @@ debugOut {stream} – If a stream is provided, any debug serial output from
        • close
        • connect
        • +
        • getLongName
        • +
        • getMyNodeInfo
        • +
        • getMyUser
        • getNode
        • +
        • getShortName
        • sendData
        • sendPosition
        • sendText
        • @@ -2457,7 +2481,7 @@ debugOut {stream} – If a stream is provided, any debug serial output from

          Interface class for meshtastic devices over a stream link (serial, TCP, etc)

          -

          Constructor, opens a connection to self.stream

          +

          Constructor, opens a connection to self.stream

          Keyword Arguments: devPath {string} – A filepath to a device, i.e. /dev/ttyUSB0 (default: {None}) debugOut {stream} – If a stream is provided, any debug serial output from the device will be emitted to that stream. (default: {None})

          @@ -2476,7 +2500,7 @@ debugOut {stream} – If a stream is provided, any debug serial output from """Interface class for meshtastic devices over a stream link (serial, TCP, etc)""" def __init__(self, debugOut=None, noProto=False, connectNow=True): - """Constructor, opens a connection to self.stream + """Constructor, opens a connection to self.stream Keyword Arguments: devPath {string} -- A filepath to a device, i.e. /dev/ttyUSB0 (default: {None}) @@ -2692,7 +2716,11 @@ start the reading thread later.

          • MeshInterface:
              +
            • getLongName
            • +
            • getMyNodeInfo
            • +
            • getMyUser
            • getNode
            • +
            • getShortName
            • sendData
            • sendPosition
            • sendText
            • @@ -2772,7 +2800,11 @@ hostname {string} – Hostname/IP address of the device to connect to

            • close
            • connect
            • +
            • getLongName
            • +
            • getMyNodeInfo
            • +
            • getMyUser
            • getNode
            • +
            • getShortName
            • sendData
            • sendPosition
            • sendText
            • diff --git a/docs/meshtastic/mesh_pb2.html b/docs/meshtastic/mesh_pb2.html index 5bb5253..40d64ee 100644 --- a/docs/meshtastic/mesh_pb2.html +++ b/docs/meshtastic/mesh_pb2.html @@ -48,7 +48,7 @@ DESCRIPTOR = _descriptor.FileDescriptor( package='', syntax='proto3', serialized_options=b'\n\023com.geeksville.meshB\nMeshProtosH\003Z!github.com/meshtastic/gomeshproto', - serialized_pb=b'\n\nmesh.proto\x1a\x0eportnums.proto\"\x94\x06\n\x08Position\x12\x12\n\nlatitude_i\x18\x01 \x01(\x0f\x12\x13\n\x0blongitude_i\x18\x02 \x01(\x0f\x12\x10\n\x08\x61ltitude\x18\x03 \x01(\x05\x12\x15\n\rbattery_level\x18\x04 \x01(\x05\x12\x0c\n\x04time\x18\t \x01(\x07\x12,\n\x0flocation_source\x18\n \x01(\x0e\x32\x13.Position.LocSource\x12,\n\x0f\x61ltitude_source\x18\x0b \x01(\x0e\x32\x13.Position.AltSource\x12\x15\n\rpos_timestamp\x18\x0c \x01(\x07\x12\x17\n\x0fpos_time_millis\x18\r \x01(\x05\x12\x14\n\x0c\x61ltitude_hae\x18\x0e \x01(\x11\x12\x15\n\ralt_geoid_sep\x18\x0f \x01(\x11\x12\x0c\n\x04PDOP\x18\x10 \x01(\r\x12\x0c\n\x04HDOP\x18\x11 \x01(\r\x12\x0c\n\x04VDOP\x18\x12 \x01(\r\x12\x14\n\x0cgps_accuracy\x18\x13 \x01(\r\x12\x14\n\x0cground_speed\x18\x14 \x01(\r\x12\x14\n\x0cground_track\x18\x15 \x01(\r\x12\x13\n\x0b\x66ix_quality\x18\x16 \x01(\r\x12\x10\n\x08\x66ix_type\x18\x17 \x01(\r\x12\x14\n\x0csats_in_view\x18\x18 \x01(\r\x12\x11\n\tsensor_id\x18\x19 \x01(\r\x12\x17\n\x0fpos_next_update\x18( \x01(\r\x12\x16\n\x0epos_seq_number\x18) \x01(\r\"n\n\tLocSource\x12\x16\n\x12LOCSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13LOCSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13LOCSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13LOCSRC_GPS_EXTERNAL\x10\x03\"\x85\x01\n\tAltSource\x12\x16\n\x12\x41LTSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13\x41LTSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13\x41LTSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13\x41LTSRC_GPS_EXTERNAL\x10\x03\x12\x15\n\x11\x41LTSRC_BAROMETRIC\x10\x04J\x04\x08\x07\x10\x08J\x04\x08\x08\x10\t\"\xd7\x01\n\x04User\x12\n\n\x02id\x18\x01 \x01(\t\x12\x11\n\tlong_name\x18\x02 \x01(\t\x12\x12\n\nshort_name\x18\x03 \x01(\t\x12\x0f\n\x07macaddr\x18\x04 \x01(\x0c\x12 \n\x08hw_model\x18\x06 \x01(\x0e\x32\x0e.HardwareModel\x12\x13\n\x0bis_licensed\x18\x07 \x01(\x08\x12\x13\n\x04team\x18\x08 \x01(\x0e\x32\x05.Team\x12\x14\n\x0ctx_power_dbm\x18\n \x01(\r\x12\x14\n\x0c\x61nt_gain_dbi\x18\x0b \x01(\r\x12\x13\n\x0b\x61nt_azimuth\x18\x0c \x01(\r\"\x1f\n\x0eRouteDiscovery\x12\r\n\x05route\x18\x02 \x03(\x07\"\xc5\x02\n\x07Routing\x12(\n\rroute_request\x18\x01 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0broute_reply\x18\x02 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0c\x65rror_reason\x18\x03 \x01(\x0e\x32\x0e.Routing.ErrorH\x00\"\xb4\x01\n\x05\x45rror\x12\x08\n\x04NONE\x10\x00\x12\x0c\n\x08NO_ROUTE\x10\x01\x12\x0b\n\x07GOT_NAK\x10\x02\x12\x0b\n\x07TIMEOUT\x10\x03\x12\x10\n\x0cNO_INTERFACE\x10\x04\x12\x12\n\x0eMAX_RETRANSMIT\x10\x05\x12\x0e\n\nNO_CHANNEL\x10\x06\x12\r\n\tTOO_LARGE\x10\x07\x12\x0f\n\x0bNO_RESPONSE\x10\x08\x12\x0f\n\x0b\x42\x41\x44_REQUEST\x10 \x12\x12\n\x0eNOT_AUTHORIZED\x10!B\t\n\x07variant\"{\n\x04\x44\x61ta\x12\x19\n\x07portnum\x18\x01 \x01(\x0e\x32\x08.PortNum\x12\x0f\n\x07payload\x18\x02 \x01(\x0c\x12\x15\n\rwant_response\x18\x03 \x01(\x08\x12\x0c\n\x04\x64\x65st\x18\x04 \x01(\x07\x12\x0e\n\x06source\x18\x05 \x01(\x07\x12\x12\n\nrequest_id\x18\x06 \x01(\x07\"\xe0\x02\n\nMeshPacket\x12\x0c\n\x04\x66rom\x18\x01 \x01(\x07\x12\n\n\x02to\x18\x02 \x01(\x07\x12\x0f\n\x07\x63hannel\x18\x03 \x01(\r\x12\x18\n\x07\x64\x65\x63oded\x18\x04 \x01(\x0b\x32\x05.DataH\x00\x12\x13\n\tencrypted\x18\x05 \x01(\x0cH\x00\x12\n\n\x02id\x18\x06 \x01(\x07\x12\x0f\n\x07rx_time\x18\x07 \x01(\x07\x12\x0e\n\x06rx_snr\x18\x08 \x01(\x02\x12\x11\n\thop_limit\x18\n \x01(\r\x12\x10\n\x08want_ack\x18\x0b \x01(\x08\x12&\n\x08priority\x18\x0c \x01(\x0e\x32\x14.MeshPacket.Priority\x12\x0f\n\x07rx_rssi\x18\r \x01(\x05\"[\n\x08Priority\x12\t\n\x05UNSET\x10\x00\x12\x07\n\x03MIN\x10\x01\x12\x0e\n\nBACKGROUND\x10\n\x12\x0b\n\x07\x44\x45\x46\x41ULT\x10@\x12\x0c\n\x08RELIABLE\x10\x46\x12\x07\n\x03\x41\x43K\x10x\x12\x07\n\x03MAX\x10\x7f\x42\x10\n\x0epayloadVariant\"j\n\x08NodeInfo\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x13\n\x04user\x18\x02 \x01(\x0b\x32\x05.User\x12\x1b\n\x08position\x18\x03 \x01(\x0b\x32\t.Position\x12\x0b\n\x03snr\x18\x07 \x01(\x02\x12\x12\n\nlast_heard\x18\x04 \x01(\x07\"\xcb\x02\n\nMyNodeInfo\x12\x13\n\x0bmy_node_num\x18\x01 \x01(\r\x12\x0f\n\x07has_gps\x18\x02 \x01(\x08\x12\x11\n\tnum_bands\x18\x03 \x01(\r\x12\x14\n\x0cmax_channels\x18\x0f \x01(\r\x12\x12\n\x06region\x18\x04 \x01(\tB\x02\x18\x01\x12\x1f\n\x13hw_model_deprecated\x18\x05 \x01(\tB\x02\x18\x01\x12\x18\n\x10\x66irmware_version\x18\x06 \x01(\t\x12&\n\nerror_code\x18\x07 \x01(\x0e\x32\x12.CriticalErrorCode\x12\x15\n\rerror_address\x18\x08 \x01(\r\x12\x13\n\x0b\x65rror_count\x18\t \x01(\r\x12\x14\n\x0creboot_count\x18\n \x01(\r\x12\x1c\n\x14message_timeout_msec\x18\r \x01(\r\x12\x17\n\x0fmin_app_version\x18\x0e \x01(\r\"\xb5\x01\n\tLogRecord\x12\x0f\n\x07message\x18\x01 \x01(\t\x12\x0c\n\x04time\x18\x02 \x01(\x07\x12\x0e\n\x06source\x18\x03 \x01(\t\x12\x1f\n\x05level\x18\x04 \x01(\x0e\x32\x10.LogRecord.Level\"X\n\x05Level\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08\x43RITICAL\x10\x32\x12\t\n\x05\x45RROR\x10(\x12\x0b\n\x07WARNING\x10\x1e\x12\x08\n\x04INFO\x10\x14\x12\t\n\x05\x44\x45\x42UG\x10\n\x12\t\n\x05TRACE\x10\x05\"\xe9\x01\n\tFromRadio\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x1d\n\x06packet\x18\x0b \x01(\x0b\x32\x0b.MeshPacketH\x00\x12\x1e\n\x07my_info\x18\x03 \x01(\x0b\x32\x0b.MyNodeInfoH\x00\x12\x1e\n\tnode_info\x18\x04 \x01(\x0b\x32\t.NodeInfoH\x00\x12 \n\nlog_record\x18\x07 \x01(\x0b\x32\n.LogRecordH\x00\x12\x1c\n\x12\x63onfig_complete_id\x18\x08 \x01(\rH\x00\x12\x12\n\x08rebooted\x18\t \x01(\x08H\x00\x42\x10\n\x0epayloadVariantJ\x04\x08\x02\x10\x03J\x04\x08\x06\x10\x07\"\xe1\x01\n\x07ToRadio\x12\x1d\n\x06packet\x18\x02 \x01(\x0b\x32\x0b.MeshPacketH\x00\x12&\n\tpeer_info\x18\x03 \x01(\x0b\x32\x11.ToRadio.PeerInfoH\x00\x12\x18\n\x0ewant_config_id\x18\x64 \x01(\rH\x00\x12\x14\n\ndisconnect\x18h \x01(\x08H\x00\x1a\x35\n\x08PeerInfo\x12\x13\n\x0b\x61pp_version\x18\x01 \x01(\r\x12\x14\n\x0cmqtt_gateway\x18\x02 \x01(\x08\x42\x10\n\x0epayloadVariantJ\x04\x08\x01\x10\x02J\x04\x08\x65\x10\x66J\x04\x08\x66\x10gJ\x04\x08g\x10h*\xac\x02\n\rHardwareModel\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08TLORA_V2\x10\x01\x12\x0c\n\x08TLORA_V1\x10\x02\x12\x12\n\x0eTLORA_V2_1_1p6\x10\x03\x12\t\n\x05TBEAM\x10\x04\x12\x0f\n\x0bHELTEC_V2_0\x10\x05\x12\x0c\n\x08TBEAM0p7\x10\x06\x12\n\n\x06T_ECHO\x10\x07\x12\x10\n\x0cTLORA_V1_1p3\x10\x08\x12\x0b\n\x07RAK4631\x10\t\x12\x0f\n\x0bHELTEC_V2_1\x10\n\x12\x11\n\rLORA_RELAY_V1\x10 \x12\x0e\n\nNRF52840DK\x10!\x12\x07\n\x03PPR\x10\"\x12\x0f\n\x0bGENIEBLOCKS\x10#\x12\x11\n\rNRF52_UNKNOWN\x10$\x12\r\n\tPORTDUINO\x10%\x12\x0f\n\x0b\x41NDROID_SIM\x10&\x12\n\n\x06\x44IY_V1\x10\'*\xb5\x01\n\x04Team\x12\t\n\x05\x43LEAR\x10\x00\x12\x08\n\x04\x43YAN\x10\x01\x12\t\n\x05WHITE\x10\x02\x12\n\n\x06YELLOW\x10\x03\x12\n\n\x06ORANGE\x10\x04\x12\x0b\n\x07MAGENTA\x10\x05\x12\x07\n\x03RED\x10\x06\x12\n\n\x06MAROON\x10\x07\x12\n\n\x06PURPLE\x10\x08\x12\r\n\tDARK_BLUE\x10\t\x12\x08\n\x04\x42LUE\x10\n\x12\x08\n\x04TEAL\x10\x0b\x12\t\n\x05GREEN\x10\x0c\x12\x0e\n\nDARK_GREEN\x10\r\x12\t\n\x05\x42ROWN\x10\x0e*.\n\tConstants\x12\n\n\x06Unused\x10\x00\x12\x15\n\x10\x44\x41TA_PAYLOAD_LEN\x10\xed\x01*\xe1\x01\n\x11\x43riticalErrorCode\x12\x08\n\x04None\x10\x00\x12\x0e\n\nTxWatchdog\x10\x01\x12\x12\n\x0eSleepEnterWait\x10\x02\x12\x0b\n\x07NoRadio\x10\x03\x12\x0f\n\x0bUnspecified\x10\x04\x12\x13\n\x0fUBloxInitFailed\x10\x05\x12\x0c\n\x08NoAXP192\x10\x06\x12\x17\n\x13InvalidRadioSetting\x10\x07\x12\x12\n\x0eTransmitFailed\x10\x08\x12\x0c\n\x08\x42rownout\x10\t\x12\x11\n\rSX1262Failure\x10\n\x12\x0f\n\x0bRadioSpiBug\x10\x0b\x42\x46\n\x13\x63om.geeksville.meshB\nMeshProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' + serialized_pb=b'\n\nmesh.proto\x1a\x0eportnums.proto\"\x94\x06\n\x08Position\x12\x12\n\nlatitude_i\x18\x01 \x01(\x0f\x12\x13\n\x0blongitude_i\x18\x02 \x01(\x0f\x12\x10\n\x08\x61ltitude\x18\x03 \x01(\x05\x12\x15\n\rbattery_level\x18\x04 \x01(\x05\x12\x0c\n\x04time\x18\t \x01(\x07\x12,\n\x0flocation_source\x18\n \x01(\x0e\x32\x13.Position.LocSource\x12,\n\x0f\x61ltitude_source\x18\x0b \x01(\x0e\x32\x13.Position.AltSource\x12\x15\n\rpos_timestamp\x18\x0c \x01(\x07\x12\x17\n\x0fpos_time_millis\x18\r \x01(\x05\x12\x14\n\x0c\x61ltitude_hae\x18\x0e \x01(\x11\x12\x15\n\ralt_geoid_sep\x18\x0f \x01(\x11\x12\x0c\n\x04PDOP\x18\x10 \x01(\r\x12\x0c\n\x04HDOP\x18\x11 \x01(\r\x12\x0c\n\x04VDOP\x18\x12 \x01(\r\x12\x14\n\x0cgps_accuracy\x18\x13 \x01(\r\x12\x14\n\x0cground_speed\x18\x14 \x01(\r\x12\x14\n\x0cground_track\x18\x15 \x01(\r\x12\x13\n\x0b\x66ix_quality\x18\x16 \x01(\r\x12\x10\n\x08\x66ix_type\x18\x17 \x01(\r\x12\x14\n\x0csats_in_view\x18\x18 \x01(\r\x12\x11\n\tsensor_id\x18\x19 \x01(\r\x12\x17\n\x0fpos_next_update\x18( \x01(\r\x12\x16\n\x0epos_seq_number\x18) \x01(\r\"n\n\tLocSource\x12\x16\n\x12LOCSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13LOCSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13LOCSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13LOCSRC_GPS_EXTERNAL\x10\x03\"\x85\x01\n\tAltSource\x12\x16\n\x12\x41LTSRC_UNSPECIFIED\x10\x00\x12\x17\n\x13\x41LTSRC_MANUAL_ENTRY\x10\x01\x12\x17\n\x13\x41LTSRC_GPS_INTERNAL\x10\x02\x12\x17\n\x13\x41LTSRC_GPS_EXTERNAL\x10\x03\x12\x15\n\x11\x41LTSRC_BAROMETRIC\x10\x04J\x04\x08\x07\x10\x08J\x04\x08\x08\x10\t\"\xd7\x01\n\x04User\x12\n\n\x02id\x18\x01 \x01(\t\x12\x11\n\tlong_name\x18\x02 \x01(\t\x12\x12\n\nshort_name\x18\x03 \x01(\t\x12\x0f\n\x07macaddr\x18\x04 \x01(\x0c\x12 \n\x08hw_model\x18\x06 \x01(\x0e\x32\x0e.HardwareModel\x12\x13\n\x0bis_licensed\x18\x07 \x01(\x08\x12\x13\n\x04team\x18\x08 \x01(\x0e\x32\x05.Team\x12\x14\n\x0ctx_power_dbm\x18\n \x01(\r\x12\x14\n\x0c\x61nt_gain_dbi\x18\x0b \x01(\r\x12\x13\n\x0b\x61nt_azimuth\x18\x0c \x01(\r\"\x1f\n\x0eRouteDiscovery\x12\r\n\x05route\x18\x02 \x03(\x07\"\xc5\x02\n\x07Routing\x12(\n\rroute_request\x18\x01 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0broute_reply\x18\x02 \x01(\x0b\x32\x0f.RouteDiscoveryH\x00\x12&\n\x0c\x65rror_reason\x18\x03 \x01(\x0e\x32\x0e.Routing.ErrorH\x00\"\xb4\x01\n\x05\x45rror\x12\x08\n\x04NONE\x10\x00\x12\x0c\n\x08NO_ROUTE\x10\x01\x12\x0b\n\x07GOT_NAK\x10\x02\x12\x0b\n\x07TIMEOUT\x10\x03\x12\x10\n\x0cNO_INTERFACE\x10\x04\x12\x12\n\x0eMAX_RETRANSMIT\x10\x05\x12\x0e\n\nNO_CHANNEL\x10\x06\x12\r\n\tTOO_LARGE\x10\x07\x12\x0f\n\x0bNO_RESPONSE\x10\x08\x12\x0f\n\x0b\x42\x41\x44_REQUEST\x10 \x12\x12\n\x0eNOT_AUTHORIZED\x10!B\t\n\x07variant\"{\n\x04\x44\x61ta\x12\x19\n\x07portnum\x18\x01 \x01(\x0e\x32\x08.PortNum\x12\x0f\n\x07payload\x18\x02 \x01(\x0c\x12\x15\n\rwant_response\x18\x03 \x01(\x08\x12\x0c\n\x04\x64\x65st\x18\x04 \x01(\x07\x12\x0e\n\x06source\x18\x05 \x01(\x07\x12\x12\n\nrequest_id\x18\x06 \x01(\x07\"\xe0\x02\n\nMeshPacket\x12\x0c\n\x04\x66rom\x18\x01 \x01(\x07\x12\n\n\x02to\x18\x02 \x01(\x07\x12\x0f\n\x07\x63hannel\x18\x03 \x01(\r\x12\x18\n\x07\x64\x65\x63oded\x18\x04 \x01(\x0b\x32\x05.DataH\x00\x12\x13\n\tencrypted\x18\x05 \x01(\x0cH\x00\x12\n\n\x02id\x18\x06 \x01(\x07\x12\x0f\n\x07rx_time\x18\x07 \x01(\x07\x12\x0e\n\x06rx_snr\x18\x08 \x01(\x02\x12\x11\n\thop_limit\x18\n \x01(\r\x12\x10\n\x08want_ack\x18\x0b \x01(\x08\x12&\n\x08priority\x18\x0c \x01(\x0e\x32\x14.MeshPacket.Priority\x12\x0f\n\x07rx_rssi\x18\r \x01(\x05\"[\n\x08Priority\x12\t\n\x05UNSET\x10\x00\x12\x07\n\x03MIN\x10\x01\x12\x0e\n\nBACKGROUND\x10\n\x12\x0b\n\x07\x44\x45\x46\x41ULT\x10@\x12\x0c\n\x08RELIABLE\x10\x46\x12\x07\n\x03\x41\x43K\x10x\x12\x07\n\x03MAX\x10\x7f\x42\x10\n\x0epayloadVariant\"j\n\x08NodeInfo\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x13\n\x04user\x18\x02 \x01(\x0b\x32\x05.User\x12\x1b\n\x08position\x18\x03 \x01(\x0b\x32\t.Position\x12\x0b\n\x03snr\x18\x07 \x01(\x02\x12\x12\n\nlast_heard\x18\x04 \x01(\x07\"\xdc\x02\n\nMyNodeInfo\x12\x13\n\x0bmy_node_num\x18\x01 \x01(\r\x12\x0f\n\x07has_gps\x18\x02 \x01(\x08\x12\x11\n\tnum_bands\x18\x03 \x01(\r\x12\x14\n\x0cmax_channels\x18\x0f \x01(\r\x12\x12\n\x06region\x18\x04 \x01(\tB\x02\x18\x01\x12\x1f\n\x13hw_model_deprecated\x18\x05 \x01(\tB\x02\x18\x01\x12\x18\n\x10\x66irmware_version\x18\x06 \x01(\t\x12&\n\nerror_code\x18\x07 \x01(\x0e\x32\x12.CriticalErrorCode\x12\x15\n\rerror_address\x18\x08 \x01(\r\x12\x13\n\x0b\x65rror_count\x18\t \x01(\r\x12\x14\n\x0creboot_count\x18\n \x01(\r\x12\x0f\n\x07\x62itrate\x18\x0b \x01(\x02\x12\x1c\n\x14message_timeout_msec\x18\r \x01(\r\x12\x17\n\x0fmin_app_version\x18\x0e \x01(\r\"\xb5\x01\n\tLogRecord\x12\x0f\n\x07message\x18\x01 \x01(\t\x12\x0c\n\x04time\x18\x02 \x01(\x07\x12\x0e\n\x06source\x18\x03 \x01(\t\x12\x1f\n\x05level\x18\x04 \x01(\x0e\x32\x10.LogRecord.Level\"X\n\x05Level\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08\x43RITICAL\x10\x32\x12\t\n\x05\x45RROR\x10(\x12\x0b\n\x07WARNING\x10\x1e\x12\x08\n\x04INFO\x10\x14\x12\t\n\x05\x44\x45\x42UG\x10\n\x12\t\n\x05TRACE\x10\x05\"\xe9\x01\n\tFromRadio\x12\x0b\n\x03num\x18\x01 \x01(\r\x12\x1d\n\x06packet\x18\x0b \x01(\x0b\x32\x0b.MeshPacketH\x00\x12\x1e\n\x07my_info\x18\x03 \x01(\x0b\x32\x0b.MyNodeInfoH\x00\x12\x1e\n\tnode_info\x18\x04 \x01(\x0b\x32\t.NodeInfoH\x00\x12 \n\nlog_record\x18\x07 \x01(\x0b\x32\n.LogRecordH\x00\x12\x1c\n\x12\x63onfig_complete_id\x18\x08 \x01(\rH\x00\x12\x12\n\x08rebooted\x18\t \x01(\x08H\x00\x42\x10\n\x0epayloadVariantJ\x04\x08\x02\x10\x03J\x04\x08\x06\x10\x07\"\xe1\x01\n\x07ToRadio\x12\x1d\n\x06packet\x18\x02 \x01(\x0b\x32\x0b.MeshPacketH\x00\x12&\n\tpeer_info\x18\x03 \x01(\x0b\x32\x11.ToRadio.PeerInfoH\x00\x12\x18\n\x0ewant_config_id\x18\x64 \x01(\rH\x00\x12\x14\n\ndisconnect\x18h \x01(\x08H\x00\x1a\x35\n\x08PeerInfo\x12\x13\n\x0b\x61pp_version\x18\x01 \x01(\r\x12\x14\n\x0cmqtt_gateway\x18\x02 \x01(\x08\x42\x10\n\x0epayloadVariantJ\x04\x08\x01\x10\x02J\x04\x08\x65\x10\x66J\x04\x08\x66\x10gJ\x04\x08g\x10h*\xac\x02\n\rHardwareModel\x12\t\n\x05UNSET\x10\x00\x12\x0c\n\x08TLORA_V2\x10\x01\x12\x0c\n\x08TLORA_V1\x10\x02\x12\x12\n\x0eTLORA_V2_1_1p6\x10\x03\x12\t\n\x05TBEAM\x10\x04\x12\x0f\n\x0bHELTEC_V2_0\x10\x05\x12\x0c\n\x08TBEAM0p7\x10\x06\x12\n\n\x06T_ECHO\x10\x07\x12\x10\n\x0cTLORA_V1_1p3\x10\x08\x12\x0b\n\x07RAK4631\x10\t\x12\x0f\n\x0bHELTEC_V2_1\x10\n\x12\x11\n\rLORA_RELAY_V1\x10 \x12\x0e\n\nNRF52840DK\x10!\x12\x07\n\x03PPR\x10\"\x12\x0f\n\x0bGENIEBLOCKS\x10#\x12\x11\n\rNRF52_UNKNOWN\x10$\x12\r\n\tPORTDUINO\x10%\x12\x0f\n\x0b\x41NDROID_SIM\x10&\x12\n\n\x06\x44IY_V1\x10\'*\xb5\x01\n\x04Team\x12\t\n\x05\x43LEAR\x10\x00\x12\x08\n\x04\x43YAN\x10\x01\x12\t\n\x05WHITE\x10\x02\x12\n\n\x06YELLOW\x10\x03\x12\n\n\x06ORANGE\x10\x04\x12\x0b\n\x07MAGENTA\x10\x05\x12\x07\n\x03RED\x10\x06\x12\n\n\x06MAROON\x10\x07\x12\n\n\x06PURPLE\x10\x08\x12\r\n\tDARK_BLUE\x10\t\x12\x08\n\x04\x42LUE\x10\n\x12\x08\n\x04TEAL\x10\x0b\x12\t\n\x05GREEN\x10\x0c\x12\x0e\n\nDARK_GREEN\x10\r\x12\t\n\x05\x42ROWN\x10\x0e*.\n\tConstants\x12\n\n\x06Unused\x10\x00\x12\x15\n\x10\x44\x41TA_PAYLOAD_LEN\x10\xed\x01*\xe1\x01\n\x11\x43riticalErrorCode\x12\x08\n\x04None\x10\x00\x12\x0e\n\nTxWatchdog\x10\x01\x12\x12\n\x0eSleepEnterWait\x10\x02\x12\x0b\n\x07NoRadio\x10\x03\x12\x0f\n\x0bUnspecified\x10\x04\x12\x13\n\x0fUBloxInitFailed\x10\x05\x12\x0c\n\x08NoAXP192\x10\x06\x12\x17\n\x13InvalidRadioSetting\x10\x07\x12\x12\n\x0eTransmitFailed\x10\x08\x12\x0c\n\x08\x42rownout\x10\t\x12\x11\n\rSX1262Failure\x10\n\x12\x0f\n\x0bRadioSpiBug\x10\x0b\x42\x46\n\x13\x63om.geeksville.meshB\nMeshProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3' , dependencies=[portnums__pb2.DESCRIPTOR,]) @@ -137,8 +137,8 @@ _HARDWAREMODEL = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2971, - serialized_end=3271, + serialized_start=2988, + serialized_end=3288, ) _sym_db.RegisterEnumDescriptor(_HARDWAREMODEL) @@ -212,8 +212,8 @@ _TEAM = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3274, - serialized_end=3455, + serialized_start=3291, + serialized_end=3472, ) _sym_db.RegisterEnumDescriptor(_TEAM) @@ -235,8 +235,8 @@ _CONSTANTS = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3457, - serialized_end=3503, + serialized_start=3474, + serialized_end=3520, ) _sym_db.RegisterEnumDescriptor(_CONSTANTS) @@ -298,8 +298,8 @@ _CRITICALERRORCODE = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=3506, - serialized_end=3731, + serialized_start=3523, + serialized_end=3748, ) _sym_db.RegisterEnumDescriptor(_CRITICALERRORCODE) @@ -555,8 +555,8 @@ _LOGRECORD_LEVEL = _descriptor.EnumDescriptor( ], containing_type=None, serialized_options=None, - serialized_start=2416, - serialized_end=2504, + serialized_start=2433, + serialized_end=2521, ) _sym_db.RegisterEnumDescriptor(_LOGRECORD_LEVEL) @@ -1244,14 +1244,21 @@ _MYNODEINFO = _descriptor.Descriptor( is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR), _descriptor.FieldDescriptor( - name='message_timeout_msec', full_name='MyNodeInfo.message_timeout_msec', index=11, + name='bitrate', full_name='MyNodeInfo.bitrate', index=11, + number=11, type=2, cpp_type=6, label=1, + has_default_value=False, default_value=float(0), + message_type=None, enum_type=None, containing_type=None, + is_extension=False, extension_scope=None, + serialized_options=None, file=DESCRIPTOR), + _descriptor.FieldDescriptor( + name='message_timeout_msec', full_name='MyNodeInfo.message_timeout_msec', index=12, number=13, type=13, cpp_type=3, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, is_extension=False, extension_scope=None, serialized_options=None, file=DESCRIPTOR), _descriptor.FieldDescriptor( - name='min_app_version', full_name='MyNodeInfo.min_app_version', index=12, + name='min_app_version', full_name='MyNodeInfo.min_app_version', index=13, number=14, type=13, cpp_type=3, label=1, has_default_value=False, default_value=0, message_type=None, enum_type=None, containing_type=None, @@ -1270,7 +1277,7 @@ _MYNODEINFO = _descriptor.Descriptor( oneofs=[ ], serialized_start=1989, - serialized_end=2320, + serialized_end=2337, ) @@ -1322,8 +1329,8 @@ _LOGRECORD = _descriptor.Descriptor( extension_ranges=[], oneofs=[ ], - serialized_start=2323, - serialized_end=2504, + serialized_start=2340, + serialized_end=2521, ) @@ -1398,8 +1405,8 @@ _FROMRADIO = _descriptor.Descriptor( name='payloadVariant', full_name='FromRadio.payloadVariant', index=0, containing_type=None, fields=[]), ], - serialized_start=2507, - serialized_end=2740, + serialized_start=2524, + serialized_end=2757, ) @@ -1436,8 +1443,8 @@ _TORADIO_PEERINFO = _descriptor.Descriptor( extension_ranges=[], oneofs=[ ], - serialized_start=2873, - serialized_end=2926, + serialized_start=2890, + serialized_end=2943, ) _TORADIO = _descriptor.Descriptor( @@ -1490,8 +1497,8 @@ _TORADIO = _descriptor.Descriptor( name='payloadVariant', full_name='ToRadio.payloadVariant', index=0, containing_type=None, fields=[]), ], - serialized_start=2743, - serialized_end=2968, + serialized_start=2760, + serialized_end=2985, ) _POSITION.fields_by_name['location_source'].enum_type = _POSITION_LOCSOURCE @@ -4378,6 +4385,10 @@ shown below.

            Class variables

            +
            var BITRATE_FIELD_NUMBER
            +
            +
            +
            var DESCRIPTOR
            @@ -4472,6 +4483,19 @@ shown below.

            Instance variables

            +
            var bitrate
            +
            +

            Getter for bitrate.

            +
            + +Expand source code + +
            def getter(self):
            +  # TODO(protobuf-team): This may be broken since there may not be
            +  # default_value.  Combine with has_default_value somehow.
            +  return self._fields.get(field, default_value)
            +
            +
            var error_address

            Getter for error_address.

            @@ -9346,6 +9370,7 @@ and propagates this to our listener iff this was a state change.

          • MyNodeInfo

              +
            • BITRATE_FIELD_NUMBER
            • ByteSize
            • Clear
            • ClearField
            • @@ -9377,6 +9402,7 @@ and propagates this to our listener iff this was a state change.

            • SetInParent
            • UnknownFields
            • WhichOneof
            • +
            • bitrate
            • error_address
            • error_code
            • error_count
            • diff --git a/docs/meshtastic/node.html b/docs/meshtastic/node.html index 36df65b..7104932 100644 --- a/docs/meshtastic/node.html +++ b/docs/meshtastic/node.html @@ -115,10 +115,10 @@ type of packet, you should subscribe to the full topic name. If you want to see - meshtastic.receive.data.portnum(packet) (where portnum is an integer or well known PortNum enum) - meshtastic.node.updated(node = NodeInfo) - published when a node in the DB changes (appears, location changed, username changed, etc...) -We receive position, user, or data packets from the mesh. You probably only care about meshtastic.receive.data. The first argument for -that publish will be the packet. Text or binary data packets (from sendData or sendText) will both arrive this way. If you print packet -you'll see the fields in the dictionary. decoded.data.payload will contain the raw bytes that were sent. If the packet was sent with -sendText, decoded.data.text will **also** be populated with the decoded string. For ASCII these two strings will be the same, but for +We receive position, user, or data packets from the mesh. You probably only care about meshtastic.receive.data. The first argument for +that publish will be the packet. Text or binary data packets (from sendData or sendText) will both arrive this way. If you print packet +you'll see the fields in the dictionary. decoded.data.payload will contain the raw bytes that were sent. If the packet was sent with +sendText, decoded.data.text will **also** be populated with the decoded string. For ASCII these two strings will be the same, but for unicode scripts they can be different. # Example Usage @@ -142,24 +142,12 @@ interface = meshtastic.SerialInterface() """ -import pygatt -import google.protobuf.json_format -import serial -import threading import logging -import sys -import random -import traceback -import time import base64 -import platform -import socket -from . import mesh_pb2, portnums_pb2, apponly_pb2, admin_pb2, environmental_measurement_pb2, remote_hardware_pb2, channel_pb2, radioconfig_pb2, util -from .util import fixme, catchAndIgnore, stripnl, DeferredExecution, Timeout -from pubsub import pub -from dotmap import DotMap from typing import * from google.protobuf.json_format import MessageToJson +from . import portnums_pb2, apponly_pb2, admin_pb2, channel_pb2 +from .util import stripnl, Timeout @@ -229,7 +217,7 @@ class Node: def writeConfig(self): """Write the current (edited) radioConfig to the device""" - if self.radioConfig == None: + if self.radioConfig is None: raise Exception("No RadioConfig has been read") p = admin_pb2.AdminMessage() @@ -292,7 +280,7 @@ class Node: else: return 0 - def setOwner(self, long_name, short_name=None, is_licensed=False): + def setOwner(self, long_name=None, short_name=None, is_licensed=False, team=None): """Set device owner name""" nChars = 3 minChars = 2 @@ -320,6 +308,8 @@ class Node: short_name = short_name[:nChars] p.set_owner.short_name = short_name p.set_owner.is_licensed = is_licensed + if team is not None: + p.set_owner.team = team return self._sendAdmin(p) @@ -337,7 +327,7 @@ class Node: def setURL(self, url): """Set mesh network URL""" - if self.radioConfig == None: + if self.radioConfig is None: raise Exception("No RadioConfig has been read") # URLs are of the form https://www.meshtastic.org/d/#{base64_channel_set} @@ -356,6 +346,9 @@ class Node: channelSet = apponly_pb2.ChannelSet() channelSet.ParseFromString(decodedURL) + if len(channelSet.settings) == 0: + raise Exception("There were no settings.") + i = 0 for chs in channelSet.settings: ch = channel_pb2.Channel() @@ -588,7 +581,7 @@ class Node: def writeConfig(self): """Write the current (edited) radioConfig to the device""" - if self.radioConfig == None: + if self.radioConfig is None: raise Exception("No RadioConfig has been read") p = admin_pb2.AdminMessage() @@ -651,7 +644,7 @@ class Node: else: return 0 - def setOwner(self, long_name, short_name=None, is_licensed=False): + def setOwner(self, long_name=None, short_name=None, is_licensed=False, team=None): """Set device owner name""" nChars = 3 minChars = 2 @@ -679,6 +672,8 @@ class Node: short_name = short_name[:nChars] p.set_owner.short_name = short_name p.set_owner.is_licensed = is_licensed + if team is not None: + p.set_owner.team = team return self._sendAdmin(p) @@ -696,7 +691,7 @@ class Node: def setURL(self, url): """Set mesh network URL""" - if self.radioConfig == None: + if self.radioConfig is None: raise Exception("No RadioConfig has been read") # URLs are of the form https://www.meshtastic.org/d/#{base64_channel_set} @@ -715,6 +710,9 @@ class Node: channelSet = apponly_pb2.ChannelSet() channelSet.ParseFromString(decodedURL) + if len(channelSet.settings) == 0: + raise Exception("There were no settings.") + i = 0 for chs in channelSet.settings: ch = channel_pb2.Channel() @@ -998,7 +996,7 @@ class Node:
          • -def setOwner(self, long_name, short_name=None, is_licensed=False) +def setOwner(self, long_name=None, short_name=None, is_licensed=False, team=None)

            Set device owner name

            @@ -1006,7 +1004,7 @@ class Node: Expand source code -
            def setOwner(self, long_name, short_name=None, is_licensed=False):
            +
            def setOwner(self, long_name=None, short_name=None, is_licensed=False, team=None):
                 """Set device owner name"""
                 nChars = 3
                 minChars = 2
            @@ -1034,6 +1032,8 @@ class Node:
                         short_name = short_name[:nChars]
                     p.set_owner.short_name = short_name
                     p.set_owner.is_licensed = is_licensed
            +    if team is not None:
            +        p.set_owner.team = team
             
                 return self._sendAdmin(p)
            @@ -1049,7 +1049,7 @@ class Node:
            def setURL(self, url):
                 """Set mesh network URL"""
            -    if self.radioConfig == None:
            +    if self.radioConfig is None:
                     raise Exception("No RadioConfig has been read")
             
                 # URLs are of the form https://www.meshtastic.org/d/#{base64_channel_set}
            @@ -1068,6 +1068,9 @@ class Node:
                 channelSet = apponly_pb2.ChannelSet()
                 channelSet.ParseFromString(decodedURL)
             
            +    if len(channelSet.settings) == 0:
            +        raise Exception("There were no settings.")
            +
                 i = 0
                 for chs in channelSet.settings:
                     ch = channel_pb2.Channel()
            @@ -1163,7 +1166,7 @@ class Node:
             
             
            def writeConfig(self):
                 """Write the current (edited) radioConfig to the device"""
            -    if self.radioConfig == None:
            +    if self.radioConfig is None:
                     raise Exception("No RadioConfig has been read")
             
                 p = admin_pb2.AdminMessage()
            diff --git a/docs/meshtastic/radioconfig_pb2.html b/docs/meshtastic/radioconfig_pb2.html
            index 9670823..bb1b452 100644
            --- a/docs/meshtastic/radioconfig_pb2.html
            +++ b/docs/meshtastic/radioconfig_pb2.html
            @@ -47,7 +47,7 @@ DESCRIPTOR = _descriptor.FileDescriptor(
               package='',
               syntax='proto3',
               serialized_options=b'\n\023com.geeksville.meshB\021RadioConfigProtosH\003Z!github.com/meshtastic/gomeshproto',
            -  serialized_pb=b'\n\x11radioconfig.proto\"\xfa\x12\n\x0bRadioConfig\x12\x31\n\x0bpreferences\x18\x01 \x01(\x0b\x32\x1c.RadioConfig.UserPreferences\x1a\xb7\x12\n\x0fUserPreferences\x12\x1f\n\x17position_broadcast_secs\x18\x01 \x01(\r\x12 \n\x18position_broadcast_smart\x18\x11 \x01(\x08\x12\x1b\n\x13send_owner_interval\x18\x02 \x01(\r\x12\x1b\n\x13wait_bluetooth_secs\x18\x04 \x01(\r\x12\x16\n\x0escreen_on_secs\x18\x05 \x01(\r\x12\x1a\n\x12phone_timeout_secs\x18\x06 \x01(\r\x12\x1d\n\x15phone_sds_timeout_sec\x18\x07 \x01(\r\x12\x1d\n\x15mesh_sds_timeout_secs\x18\x08 \x01(\r\x12\x10\n\x08sds_secs\x18\t \x01(\r\x12\x0f\n\x07ls_secs\x18\n \x01(\r\x12\x15\n\rmin_wake_secs\x18\x0b \x01(\r\x12\x11\n\twifi_ssid\x18\x0c \x01(\t\x12\x15\n\rwifi_password\x18\r \x01(\t\x12\x14\n\x0cwifi_ap_mode\x18\x0e \x01(\x08\x12\x1b\n\x06region\x18\x0f \x01(\x0e\x32\x0b.RegionCode\x12&\n\x0e\x63harge_current\x18\x10 \x01(\x0e\x32\x0e.ChargeCurrent\x12\x11\n\tis_router\x18% \x01(\x08\x12\x14\n\x0cis_low_power\x18& \x01(\x08\x12\x16\n\x0e\x66ixed_position\x18\' \x01(\x08\x12\x17\n\x0fserial_disabled\x18( \x01(\x08\x12(\n\x0elocation_share\x18  \x01(\x0e\x32\x10.LocationSharing\x12$\n\rgps_operation\x18! \x01(\x0e\x32\r.GpsOperation\x12\x1b\n\x13gps_update_interval\x18\" \x01(\r\x12\x18\n\x10gps_attempt_time\x18$ \x01(\r\x12\x15\n\rgps_accept_2d\x18- \x01(\x08\x12\x13\n\x0bgps_max_dop\x18. \x01(\r\x12\x18\n\x10\x66requency_offset\x18) \x01(\x02\x12\x13\n\x0bmqtt_server\x18* \x01(\t\x12\x15\n\rmqtt_disabled\x18+ \x01(\x08\x12(\n\ngps_format\x18, \x01(\x0e\x32\x14.GpsCoordinateFormat\x12\x15\n\rfactory_reset\x18\x64 \x01(\x08\x12\x19\n\x11\x64\x65\x62ug_log_enabled\x18\x65 \x01(\x08\x12\x17\n\x0fignore_incoming\x18g \x03(\r\x12\x1c\n\x14serialplugin_enabled\x18x \x01(\x08\x12\x19\n\x11serialplugin_echo\x18y \x01(\x08\x12\x18\n\x10serialplugin_rxd\x18z \x01(\r\x12\x18\n\x10serialplugin_txd\x18{ \x01(\r\x12\x1c\n\x14serialplugin_timeout\x18| \x01(\r\x12\x19\n\x11serialplugin_mode\x18} \x01(\r\x12\'\n\x1f\x65xt_notification_plugin_enabled\x18~ \x01(\x08\x12)\n!ext_notification_plugin_output_ms\x18\x7f \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_output\x18\x80\x01 \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_active\x18\x81\x01 \x01(\x08\x12.\n%ext_notification_plugin_alert_message\x18\x82\x01 \x01(\x08\x12+\n\"ext_notification_plugin_alert_bell\x18\x83\x01 \x01(\x08\x12\"\n\x19range_test_plugin_enabled\x18\x84\x01 \x01(\x08\x12!\n\x18range_test_plugin_sender\x18\x85\x01 \x01(\r\x12\x1f\n\x16range_test_plugin_save\x18\x86\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_enabled\x18\x94\x01 \x01(\x08\x12\'\n\x1estore_forward_plugin_heartbeat\x18\x95\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_records\x18\x89\x01 \x01(\r\x12\x30\n\'store_forward_plugin_history_return_max\x18\x8a\x01 \x01(\r\x12\x33\n*store_forward_plugin_history_return_window\x18\x8b\x01 \x01(\r\x12=\n4environmental_measurement_plugin_measurement_enabled\x18\x8c\x01 \x01(\x08\x12\x38\n/environmental_measurement_plugin_screen_enabled\x18\x8d\x01 \x01(\x08\x12\x44\n;environmental_measurement_plugin_read_error_count_threshold\x18\x8e\x01 \x01(\r\x12\x39\n0environmental_measurement_plugin_update_interval\x18\x8f\x01 \x01(\r\x12;\n2environmental_measurement_plugin_recovery_interval\x18\x90\x01 \x01(\r\x12;\n2environmental_measurement_plugin_display_farenheit\x18\x91\x01 \x01(\x08\x12v\n,environmental_measurement_plugin_sensor_type\x18\x92\x01 \x01(\x0e\x32?.RadioConfig.UserPreferences.EnvironmentalMeasurementSensorType\x12\x34\n+environmental_measurement_plugin_sensor_pin\x18\x93\x01 \x01(\r\x12\x17\n\x0eposition_flags\x18\x96\x01 \x01(\r\x12\x1a\n\x11is_always_powered\x18\x97\x01 \x01(\x08\x12\"\n\x19\x61uto_screen_carousel_secs\x18\x98\x01 \x01(\r\"<\n\"EnvironmentalMeasurementSensorType\x12\t\n\x05\x44HT11\x10\x00\x12\x0b\n\x07\x44S18B20\x10\x01J\x06\x08\x88\x01\x10\x89\x01*f\n\nRegionCode\x12\t\n\x05Unset\x10\x00\x12\x06\n\x02US\x10\x01\x12\t\n\x05\x45U433\x10\x02\x12\t\n\x05\x45U865\x10\x03\x12\x06\n\x02\x43N\x10\x04\x12\x06\n\x02JP\x10\x05\x12\x07\n\x03\x41NZ\x10\x06\x12\x06\n\x02KR\x10\x07\x12\x06\n\x02TW\x10\x08\x12\x06\n\x02RU\x10\t*\xd1\x01\n\rChargeCurrent\x12\x0b\n\x07MAUnset\x10\x00\x12\t\n\x05MA100\x10\x01\x12\t\n\x05MA190\x10\x02\x12\t\n\x05MA280\x10\x03\x12\t\n\x05MA360\x10\x04\x12\t\n\x05MA450\x10\x05\x12\t\n\x05MA550\x10\x06\x12\t\n\x05MA630\x10\x07\x12\t\n\x05MA700\x10\x08\x12\t\n\x05MA780\x10\t\x12\t\n\x05MA880\x10\n\x12\t\n\x05MA960\x10\x0b\x12\n\n\x06MA1000\x10\x0c\x12\n\n\x06MA1080\x10\r\x12\n\n\x06MA1160\x10\x0e\x12\n\n\x06MA1240\x10\x0f\x12\n\n\x06MA1320\x10\x10*j\n\x0cGpsOperation\x12\x0e\n\nGpsOpUnset\x10\x00\x12\x13\n\x0fGpsOpStationary\x10\x01\x12\x0f\n\x0bGpsOpMobile\x10\x02\x12\x11\n\rGpsOpTimeOnly\x10\x03\x12\x11\n\rGpsOpDisabled\x10\x04*\x83\x01\n\x13GpsCoordinateFormat\x12\x10\n\x0cGpsFormatDec\x10\x00\x12\x10\n\x0cGpsFormatDMS\x10\x01\x12\x10\n\x0cGpsFormatUTM\x10\x02\x12\x11\n\rGpsFormatMGRS\x10\x03\x12\x10\n\x0cGpsFormatOLC\x10\x04\x12\x11\n\rGpsFormatOSGR\x10\x05*@\n\x0fLocationSharing\x12\x0c\n\x08LocUnset\x10\x00\x12\x0e\n\nLocEnabled\x10\x01\x12\x0f\n\x0bLocDisabled\x10\x02*\xbc\x01\n\rPositionFlags\x12\x11\n\rPOS_UNDEFINED\x10\x00\x12\x10\n\x0cPOS_ALTITUDE\x10\x01\x12\x0f\n\x0bPOS_ALT_MSL\x10\x02\x12\x0f\n\x0bPOS_GEO_SEP\x10\x04\x12\x0b\n\x07POS_DOP\x10\x08\x12\r\n\tPOS_HVDOP\x10\x10\x12\x0f\n\x0bPOS_BATTERY\x10 \x12\x11\n\rPOS_SATINVIEW\x10@\x12\x10\n\x0bPOS_SEQ_NOS\x10\x80\x01\x12\x12\n\rPOS_TIMESTAMP\x10\x80\x02\x42M\n\x13\x63om.geeksville.meshB\x11RadioConfigProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3'
            +  serialized_pb=b'\n\x11radioconfig.proto\"\xa3\x13\n\x0bRadioConfig\x12\x31\n\x0bpreferences\x18\x01 \x01(\x0b\x32\x1c.RadioConfig.UserPreferences\x1a\xe0\x12\n\x0fUserPreferences\x12\x1f\n\x17position_broadcast_secs\x18\x01 \x01(\r\x12 \n\x18position_broadcast_smart\x18\x11 \x01(\x08\x12\x1b\n\x13send_owner_interval\x18\x02 \x01(\r\x12\x1b\n\x13wait_bluetooth_secs\x18\x04 \x01(\r\x12\x16\n\x0escreen_on_secs\x18\x05 \x01(\r\x12\x1a\n\x12phone_timeout_secs\x18\x06 \x01(\r\x12\x1d\n\x15phone_sds_timeout_sec\x18\x07 \x01(\r\x12\x1d\n\x15mesh_sds_timeout_secs\x18\x08 \x01(\r\x12\x10\n\x08sds_secs\x18\t \x01(\r\x12\x0f\n\x07ls_secs\x18\n \x01(\r\x12\x15\n\rmin_wake_secs\x18\x0b \x01(\r\x12\x11\n\twifi_ssid\x18\x0c \x01(\t\x12\x15\n\rwifi_password\x18\r \x01(\t\x12\x14\n\x0cwifi_ap_mode\x18\x0e \x01(\x08\x12\x1b\n\x06region\x18\x0f \x01(\x0e\x32\x0b.RegionCode\x12&\n\x0e\x63harge_current\x18\x10 \x01(\x0e\x32\x0e.ChargeCurrent\x12\x11\n\tis_router\x18% \x01(\x08\x12\x14\n\x0cis_low_power\x18& \x01(\x08\x12\x16\n\x0e\x66ixed_position\x18\' \x01(\x08\x12\x17\n\x0fserial_disabled\x18( \x01(\x08\x12(\n\x0elocation_share\x18  \x01(\x0e\x32\x10.LocationSharing\x12$\n\rgps_operation\x18! \x01(\x0e\x32\r.GpsOperation\x12\x1b\n\x13gps_update_interval\x18\" \x01(\r\x12\x18\n\x10gps_attempt_time\x18$ \x01(\r\x12\x15\n\rgps_accept_2d\x18- \x01(\x08\x12\x13\n\x0bgps_max_dop\x18. \x01(\r\x12\x18\n\x10\x66requency_offset\x18) \x01(\x02\x12\x13\n\x0bmqtt_server\x18* \x01(\t\x12\x15\n\rmqtt_disabled\x18+ \x01(\x08\x12(\n\ngps_format\x18, \x01(\x0e\x32\x14.GpsCoordinateFormat\x12\x15\n\rfactory_reset\x18\x64 \x01(\x08\x12\x19\n\x11\x64\x65\x62ug_log_enabled\x18\x65 \x01(\x08\x12\x17\n\x0fignore_incoming\x18g \x03(\r\x12\x1c\n\x14serialplugin_enabled\x18x \x01(\x08\x12\x19\n\x11serialplugin_echo\x18y \x01(\x08\x12\x18\n\x10serialplugin_rxd\x18z \x01(\r\x12\x18\n\x10serialplugin_txd\x18{ \x01(\r\x12\x1c\n\x14serialplugin_timeout\x18| \x01(\r\x12\x19\n\x11serialplugin_mode\x18} \x01(\r\x12\'\n\x1f\x65xt_notification_plugin_enabled\x18~ \x01(\x08\x12)\n!ext_notification_plugin_output_ms\x18\x7f \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_output\x18\x80\x01 \x01(\r\x12\'\n\x1e\x65xt_notification_plugin_active\x18\x81\x01 \x01(\x08\x12.\n%ext_notification_plugin_alert_message\x18\x82\x01 \x01(\x08\x12+\n\"ext_notification_plugin_alert_bell\x18\x83\x01 \x01(\x08\x12\"\n\x19range_test_plugin_enabled\x18\x84\x01 \x01(\x08\x12!\n\x18range_test_plugin_sender\x18\x85\x01 \x01(\r\x12\x1f\n\x16range_test_plugin_save\x18\x86\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_enabled\x18\x94\x01 \x01(\x08\x12\'\n\x1estore_forward_plugin_heartbeat\x18\x95\x01 \x01(\x08\x12%\n\x1cstore_forward_plugin_records\x18\x89\x01 \x01(\r\x12\x30\n\'store_forward_plugin_history_return_max\x18\x8a\x01 \x01(\r\x12\x33\n*store_forward_plugin_history_return_window\x18\x8b\x01 \x01(\r\x12=\n4environmental_measurement_plugin_measurement_enabled\x18\x8c\x01 \x01(\x08\x12\x38\n/environmental_measurement_plugin_screen_enabled\x18\x8d\x01 \x01(\x08\x12\x44\n;environmental_measurement_plugin_read_error_count_threshold\x18\x8e\x01 \x01(\r\x12\x39\n0environmental_measurement_plugin_update_interval\x18\x8f\x01 \x01(\r\x12;\n2environmental_measurement_plugin_recovery_interval\x18\x90\x01 \x01(\r\x12;\n2environmental_measurement_plugin_display_farenheit\x18\x91\x01 \x01(\x08\x12v\n,environmental_measurement_plugin_sensor_type\x18\x92\x01 \x01(\x0e\x32?.RadioConfig.UserPreferences.EnvironmentalMeasurementSensorType\x12\x34\n+environmental_measurement_plugin_sensor_pin\x18\x93\x01 \x01(\r\x12\x17\n\x0eposition_flags\x18\x96\x01 \x01(\r\x12\x1a\n\x11is_always_powered\x18\x97\x01 \x01(\x08\x12\"\n\x19\x61uto_screen_carousel_secs\x18\x98\x01 \x01(\r\x12\'\n\x1eon_battery_shutdown_after_secs\x18\x99\x01 \x01(\r\"<\n\"EnvironmentalMeasurementSensorType\x12\t\n\x05\x44HT11\x10\x00\x12\x0b\n\x07\x44S18B20\x10\x01J\x06\x08\x88\x01\x10\x89\x01*f\n\nRegionCode\x12\t\n\x05Unset\x10\x00\x12\x06\n\x02US\x10\x01\x12\t\n\x05\x45U433\x10\x02\x12\t\n\x05\x45U865\x10\x03\x12\x06\n\x02\x43N\x10\x04\x12\x06\n\x02JP\x10\x05\x12\x07\n\x03\x41NZ\x10\x06\x12\x06\n\x02KR\x10\x07\x12\x06\n\x02TW\x10\x08\x12\x06\n\x02RU\x10\t*\xd1\x01\n\rChargeCurrent\x12\x0b\n\x07MAUnset\x10\x00\x12\t\n\x05MA100\x10\x01\x12\t\n\x05MA190\x10\x02\x12\t\n\x05MA280\x10\x03\x12\t\n\x05MA360\x10\x04\x12\t\n\x05MA450\x10\x05\x12\t\n\x05MA550\x10\x06\x12\t\n\x05MA630\x10\x07\x12\t\n\x05MA700\x10\x08\x12\t\n\x05MA780\x10\t\x12\t\n\x05MA880\x10\n\x12\t\n\x05MA960\x10\x0b\x12\n\n\x06MA1000\x10\x0c\x12\n\n\x06MA1080\x10\r\x12\n\n\x06MA1160\x10\x0e\x12\n\n\x06MA1240\x10\x0f\x12\n\n\x06MA1320\x10\x10*j\n\x0cGpsOperation\x12\x0e\n\nGpsOpUnset\x10\x00\x12\x13\n\x0fGpsOpStationary\x10\x01\x12\x0f\n\x0bGpsOpMobile\x10\x02\x12\x11\n\rGpsOpTimeOnly\x10\x03\x12\x11\n\rGpsOpDisabled\x10\x04*\x83\x01\n\x13GpsCoordinateFormat\x12\x10\n\x0cGpsFormatDec\x10\x00\x12\x10\n\x0cGpsFormatDMS\x10\x01\x12\x10\n\x0cGpsFormatUTM\x10\x02\x12\x11\n\rGpsFormatMGRS\x10\x03\x12\x10\n\x0cGpsFormatOLC\x10\x04\x12\x11\n\rGpsFormatOSGR\x10\x05*@\n\x0fLocationSharing\x12\x0c\n\x08LocUnset\x10\x00\x12\x0e\n\nLocEnabled\x10\x01\x12\x0f\n\x0bLocDisabled\x10\x02*\xbc\x01\n\rPositionFlags\x12\x11\n\rPOS_UNDEFINED\x10\x00\x12\x10\n\x0cPOS_ALTITUDE\x10\x01\x12\x0f\n\x0bPOS_ALT_MSL\x10\x02\x12\x0f\n\x0bPOS_GEO_SEP\x10\x04\x12\x0b\n\x07POS_DOP\x10\x08\x12\r\n\tPOS_HVDOP\x10\x10\x12\x0f\n\x0bPOS_BATTERY\x10 \x12\x11\n\rPOS_SATINVIEW\x10@\x12\x10\n\x0bPOS_SEQ_NOS\x10\x80\x01\x12\x12\n\rPOS_TIMESTAMP\x10\x80\x02\x42M\n\x13\x63om.geeksville.meshB\x11RadioConfigProtosH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3'
             )
             
             _REGIONCODE = _descriptor.EnumDescriptor(
            @@ -99,8 +99,8 @@ _REGIONCODE = _descriptor.EnumDescriptor(
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=2450,
            -  serialized_end=2552,
            +  serialized_start=2491,
            +  serialized_end=2593,
             )
             _sym_db.RegisterEnumDescriptor(_REGIONCODE)
             
            @@ -182,8 +182,8 @@ _CHARGECURRENT = _descriptor.EnumDescriptor(
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=2555,
            -  serialized_end=2764,
            +  serialized_start=2596,
            +  serialized_end=2805,
             )
             _sym_db.RegisterEnumDescriptor(_CHARGECURRENT)
             
            @@ -217,8 +217,8 @@ _GPSOPERATION = _descriptor.EnumDescriptor(
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=2766,
            -  serialized_end=2872,
            +  serialized_start=2807,
            +  serialized_end=2913,
             )
             _sym_db.RegisterEnumDescriptor(_GPSOPERATION)
             
            @@ -256,8 +256,8 @@ _GPSCOORDINATEFORMAT = _descriptor.EnumDescriptor(
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=2875,
            -  serialized_end=3006,
            +  serialized_start=2916,
            +  serialized_end=3047,
             )
             _sym_db.RegisterEnumDescriptor(_GPSCOORDINATEFORMAT)
             
            @@ -283,8 +283,8 @@ _LOCATIONSHARING = _descriptor.EnumDescriptor(
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=3008,
            -  serialized_end=3072,
            +  serialized_start=3049,
            +  serialized_end=3113,
             )
             _sym_db.RegisterEnumDescriptor(_LOCATIONSHARING)
             
            @@ -338,8 +338,8 @@ _POSITIONFLAGS = _descriptor.EnumDescriptor(
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=3075,
            -  serialized_end=3263,
            +  serialized_start=3116,
            +  serialized_end=3304,
             )
             _sym_db.RegisterEnumDescriptor(_POSITIONFLAGS)
             
            @@ -414,8 +414,8 @@ _RADIOCONFIG_USERPREFERENCES_ENVIRONMENTALMEASUREMENTSENSORTYPE = _descriptor.En
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=2380,
            -  serialized_end=2440,
            +  serialized_start=2421,
            +  serialized_end=2481,
             )
             _sym_db.RegisterEnumDescriptor(_RADIOCONFIG_USERPREFERENCES_ENVIRONMENTALMEASUREMENTSENSORTYPE)
             
            @@ -875,6 +875,13 @@ _RADIOCONFIG_USERPREFERENCES = _descriptor.Descriptor(
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
            +    _descriptor.FieldDescriptor(
            +      name='on_battery_shutdown_after_secs', full_name='RadioConfig.UserPreferences.on_battery_shutdown_after_secs', index=64,
            +      number=153, type=13, cpp_type=3, label=1,
            +      has_default_value=False, default_value=0,
            +      message_type=None, enum_type=None, containing_type=None,
            +      is_extension=False, extension_scope=None,
            +      serialized_options=None, file=DESCRIPTOR),
               ],
               extensions=[
               ],
            @@ -889,7 +896,7 @@ _RADIOCONFIG_USERPREFERENCES = _descriptor.Descriptor(
               oneofs=[
               ],
               serialized_start=89,
            -  serialized_end=2448,
            +  serialized_end=2489,
             )
             
             _RADIOCONFIG = _descriptor.Descriptor(
            @@ -919,7 +926,7 @@ _RADIOCONFIG = _descriptor.Descriptor(
               oneofs=[
               ],
               serialized_start=22,
            -  serialized_end=2448,
            +  serialized_end=2489,
             )
             
             _RADIOCONFIG_USERPREFERENCES.fields_by_name['region'].enum_type = _REGIONCODE
            diff --git a/docs/meshtastic/remote_hardware.html b/docs/meshtastic/remote_hardware.html
            index f059454..9e85b69 100644
            --- a/docs/meshtastic/remote_hardware.html
            +++ b/docs/meshtastic/remote_hardware.html
            @@ -26,8 +26,8 @@
             
             Expand source code
             
            -
            from . import portnums_pb2, remote_hardware_pb2
            -from pubsub import pub
            +
            from pubsub import pub
            +from . import portnums_pb2, remote_hardware_pb2
             
             
             def onGPIOreceive(packet, interface):
            @@ -40,7 +40,7 @@ def onGPIOreceive(packet, interface):
             
             class RemoteHardwareClient:
                 """
            -    This is the client code to control/monitor simple hardware built into the 
            +    This is the client code to control/monitor simple hardware built into the
                 meshtastic devices.  It is intended to be both a useful API/service and example
                 code for how you can connect to your own custom meshtastic services
                 """
            @@ -141,7 +141,7 @@ code for how you can connect to your own custom meshtastic services

            class RemoteHardwareClient:
                 """
            -    This is the client code to control/monitor simple hardware built into the 
            +    This is the client code to control/monitor simple hardware built into the
                 meshtastic devices.  It is intended to be both a useful API/service and example
                 code for how you can connect to your own custom meshtastic services
                 """
            diff --git a/docs/meshtastic/storeforward_pb2.html b/docs/meshtastic/storeforward_pb2.html
            index 0e162c9..c4fd22d 100644
            --- a/docs/meshtastic/storeforward_pb2.html
            +++ b/docs/meshtastic/storeforward_pb2.html
            @@ -46,14 +46,14 @@ DESCRIPTOR = _descriptor.FileDescriptor(
               package='',
               syntax='proto3',
               serialized_options=b'\n\023com.geeksville.meshB\017StoreAndForwardH\003Z!github.com/meshtastic/gomeshproto',
            -  serialized_pb=b'\n\x12storeforward.proto\"\x8d\x05\n\x16StoreAndForwardMessage\x12\x33\n\x02rr\x18\x01 \x01(\x0e\x32\'.StoreAndForwardMessage.RequestResponse\x12\x31\n\x05stats\x18\x02 \x01(\x0b\x32\".StoreAndForwardMessage.Statistics\x12\x30\n\x07history\x18\x03 \x01(\x0b\x32\x1f.StoreAndForwardMessage.History\x1a\xc6\x01\n\nStatistics\x12\x15\n\rMessagesTotal\x18\x01 \x01(\r\x12\x15\n\rMessagesSaved\x18\x02 \x01(\r\x12\x13\n\x0bMessagesMax\x18\x03 \x01(\r\x12\x0e\n\x06UpTime\x18\x04 \x01(\r\x12\x10\n\x08Requests\x18\x05 \x01(\r\x12\x17\n\x0fRequestsHistory\x18\x06 \x01(\r\x12\x11\n\tHeartbeat\x18\x07 \x01(\x08\x12\x11\n\tReturnMax\x18\x08 \x01(\r\x12\x14\n\x0cReturnWindow\x18\t \x01(\r\x1a\x32\n\x07History\x12\x17\n\x0fHistoryMessages\x18\x01 \x01(\r\x12\x0e\n\x06Window\x18\x02 \x01(\r\"\xdb\x01\n\x0fRequestResponse\x12\t\n\x05UNSET\x10\x00\x12\x10\n\x0cROUTER_ERROR\x10\x01\x12\x14\n\x10ROUTER_HEARTBEAT\x10\x02\x12\x0f\n\x0bROUTER_PING\x10\x03\x12\x0f\n\x0bROUTER_PONG\x10\x04\x12\x0f\n\x0bROUTER_BUSY\x10\x05\x12\x10\n\x0c\x43LIENT_ERROR\x10\x65\x12\x12\n\x0e\x43LIENT_HISTORY\x10\x66\x12\x10\n\x0c\x43LIENT_STATS\x10g\x12\x0f\n\x0b\x43LIENT_PING\x10h\x12\x0f\n\x0b\x43LIENT_PONG\x10i\x12\x08\n\x03MAX\x10\xff\x01\x42K\n\x13\x63om.geeksville.meshB\x0fStoreAndForwardH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3'
            +  serialized_pb=b'\n\x12storeforward.proto\"\xe7\x04\n\x0fStoreAndForward\x12,\n\x02rr\x18\x01 \x01(\x0e\x32 .StoreAndForward.RequestResponse\x12*\n\x05stats\x18\x02 \x01(\x0b\x32\x1b.StoreAndForward.Statistics\x12)\n\x07history\x18\x03 \x01(\x0b\x32\x18.StoreAndForward.History\x1a\xc6\x01\n\nStatistics\x12\x15\n\rMessagesTotal\x18\x01 \x01(\r\x12\x15\n\rMessagesSaved\x18\x02 \x01(\r\x12\x13\n\x0bMessagesMax\x18\x03 \x01(\r\x12\x0e\n\x06UpTime\x18\x04 \x01(\r\x12\x10\n\x08Requests\x18\x05 \x01(\r\x12\x17\n\x0fRequestsHistory\x18\x06 \x01(\r\x12\x11\n\tHeartbeat\x18\x07 \x01(\x08\x12\x11\n\tReturnMax\x18\x08 \x01(\r\x12\x14\n\x0cReturnWindow\x18\t \x01(\r\x1a\x32\n\x07History\x12\x17\n\x0fHistoryMessages\x18\x01 \x01(\r\x12\x0e\n\x06Window\x18\x02 \x01(\r\"\xd1\x01\n\x0fRequestResponse\x12\t\n\x05UNSET\x10\x00\x12\x10\n\x0cROUTER_ERROR\x10\x01\x12\x14\n\x10ROUTER_HEARTBEAT\x10\x02\x12\x0f\n\x0bROUTER_PING\x10\x03\x12\x0f\n\x0bROUTER_PONG\x10\x04\x12\x0f\n\x0bROUTER_BUSY\x10\x05\x12\x10\n\x0c\x43LIENT_ERROR\x10\x65\x12\x12\n\x0e\x43LIENT_HISTORY\x10\x66\x12\x10\n\x0c\x43LIENT_STATS\x10g\x12\x0f\n\x0b\x43LIENT_PING\x10h\x12\x0f\n\x0b\x43LIENT_PONG\x10iBK\n\x13\x63om.geeksville.meshB\x0fStoreAndForwardH\x03Z!github.com/meshtastic/gomeshprotob\x06proto3'
             )
             
             
             
            -_STOREANDFORWARDMESSAGE_REQUESTRESPONSE = _descriptor.EnumDescriptor(
            +_STOREANDFORWARD_REQUESTRESPONSE = _descriptor.EnumDescriptor(
               name='RequestResponse',
            -  full_name='StoreAndForwardMessage.RequestResponse',
            +  full_name='StoreAndForward.RequestResponse',
               filename=None,
               file=DESCRIPTOR,
               values=[
            @@ -101,84 +101,80 @@ _STOREANDFORWARDMESSAGE_REQUESTRESPONSE = _descriptor.EnumDescriptor(
                   name='CLIENT_PONG', index=10, number=105,
                   serialized_options=None,
                   type=None),
            -    _descriptor.EnumValueDescriptor(
            -      name='MAX', index=11, number=255,
            -      serialized_options=None,
            -      type=None),
               ],
               containing_type=None,
               serialized_options=None,
            -  serialized_start=457,
            -  serialized_end=676,
            +  serialized_start=429,
            +  serialized_end=638,
             )
            -_sym_db.RegisterEnumDescriptor(_STOREANDFORWARDMESSAGE_REQUESTRESPONSE)
            +_sym_db.RegisterEnumDescriptor(_STOREANDFORWARD_REQUESTRESPONSE)
             
             
            -_STOREANDFORWARDMESSAGE_STATISTICS = _descriptor.Descriptor(
            +_STOREANDFORWARD_STATISTICS = _descriptor.Descriptor(
               name='Statistics',
            -  full_name='StoreAndForwardMessage.Statistics',
            +  full_name='StoreAndForward.Statistics',
               filename=None,
               file=DESCRIPTOR,
               containing_type=None,
               fields=[
                 _descriptor.FieldDescriptor(
            -      name='MessagesTotal', full_name='StoreAndForwardMessage.Statistics.MessagesTotal', index=0,
            +      name='MessagesTotal', full_name='StoreAndForward.Statistics.MessagesTotal', index=0,
                   number=1, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='MessagesSaved', full_name='StoreAndForwardMessage.Statistics.MessagesSaved', index=1,
            +      name='MessagesSaved', full_name='StoreAndForward.Statistics.MessagesSaved', index=1,
                   number=2, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='MessagesMax', full_name='StoreAndForwardMessage.Statistics.MessagesMax', index=2,
            +      name='MessagesMax', full_name='StoreAndForward.Statistics.MessagesMax', index=2,
                   number=3, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='UpTime', full_name='StoreAndForwardMessage.Statistics.UpTime', index=3,
            +      name='UpTime', full_name='StoreAndForward.Statistics.UpTime', index=3,
                   number=4, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='Requests', full_name='StoreAndForwardMessage.Statistics.Requests', index=4,
            +      name='Requests', full_name='StoreAndForward.Statistics.Requests', index=4,
                   number=5, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='RequestsHistory', full_name='StoreAndForwardMessage.Statistics.RequestsHistory', index=5,
            +      name='RequestsHistory', full_name='StoreAndForward.Statistics.RequestsHistory', index=5,
                   number=6, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='Heartbeat', full_name='StoreAndForwardMessage.Statistics.Heartbeat', index=6,
            +      name='Heartbeat', full_name='StoreAndForward.Statistics.Heartbeat', index=6,
                   number=7, type=8, cpp_type=7, label=1,
                   has_default_value=False, default_value=False,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='ReturnMax', full_name='StoreAndForwardMessage.Statistics.ReturnMax', index=7,
            +      name='ReturnMax', full_name='StoreAndForward.Statistics.ReturnMax', index=7,
                   number=8, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='ReturnWindow', full_name='StoreAndForwardMessage.Statistics.ReturnWindow', index=8,
            +      name='ReturnWindow', full_name='StoreAndForward.Statistics.ReturnWindow', index=8,
                   number=9, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
            @@ -196,26 +192,26 @@ _STOREANDFORWARDMESSAGE_STATISTICS = _descriptor.Descriptor(
               extension_ranges=[],
               oneofs=[
               ],
            -  serialized_start=204,
            -  serialized_end=402,
            +  serialized_start=176,
            +  serialized_end=374,
             )
             
            -_STOREANDFORWARDMESSAGE_HISTORY = _descriptor.Descriptor(
            +_STOREANDFORWARD_HISTORY = _descriptor.Descriptor(
               name='History',
            -  full_name='StoreAndForwardMessage.History',
            +  full_name='StoreAndForward.History',
               filename=None,
               file=DESCRIPTOR,
               containing_type=None,
               fields=[
                 _descriptor.FieldDescriptor(
            -      name='HistoryMessages', full_name='StoreAndForwardMessage.History.HistoryMessages', index=0,
            +      name='HistoryMessages', full_name='StoreAndForward.History.HistoryMessages', index=0,
                   number=1, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='Window', full_name='StoreAndForwardMessage.History.Window', index=1,
            +      name='Window', full_name='StoreAndForward.History.Window', index=1,
                   number=2, type=13, cpp_type=3, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
            @@ -233,33 +229,33 @@ _STOREANDFORWARDMESSAGE_HISTORY = _descriptor.Descriptor(
               extension_ranges=[],
               oneofs=[
               ],
            -  serialized_start=404,
            -  serialized_end=454,
            +  serialized_start=376,
            +  serialized_end=426,
             )
             
            -_STOREANDFORWARDMESSAGE = _descriptor.Descriptor(
            -  name='StoreAndForwardMessage',
            -  full_name='StoreAndForwardMessage',
            +_STOREANDFORWARD = _descriptor.Descriptor(
            +  name='StoreAndForward',
            +  full_name='StoreAndForward',
               filename=None,
               file=DESCRIPTOR,
               containing_type=None,
               fields=[
                 _descriptor.FieldDescriptor(
            -      name='rr', full_name='StoreAndForwardMessage.rr', index=0,
            +      name='rr', full_name='StoreAndForward.rr', index=0,
                   number=1, type=14, cpp_type=8, label=1,
                   has_default_value=False, default_value=0,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='stats', full_name='StoreAndForwardMessage.stats', index=1,
            +      name='stats', full_name='StoreAndForward.stats', index=1,
                   number=2, type=11, cpp_type=10, label=1,
                   has_default_value=False, default_value=None,
                   message_type=None, enum_type=None, containing_type=None,
                   is_extension=False, extension_scope=None,
                   serialized_options=None, file=DESCRIPTOR),
                 _descriptor.FieldDescriptor(
            -      name='history', full_name='StoreAndForwardMessage.history', index=2,
            +      name='history', full_name='StoreAndForward.history', index=2,
                   number=3, type=11, cpp_type=10, label=1,
                   has_default_value=False, default_value=None,
                   message_type=None, enum_type=None, containing_type=None,
            @@ -268,9 +264,9 @@ _STOREANDFORWARDMESSAGE = _descriptor.Descriptor(
               ],
               extensions=[
               ],
            -  nested_types=[_STOREANDFORWARDMESSAGE_STATISTICS, _STOREANDFORWARDMESSAGE_HISTORY, ],
            +  nested_types=[_STOREANDFORWARD_STATISTICS, _STOREANDFORWARD_HISTORY, ],
               enum_types=[
            -    _STOREANDFORWARDMESSAGE_REQUESTRESPONSE,
            +    _STOREANDFORWARD_REQUESTRESPONSE,
               ],
               serialized_options=None,
               is_extendable=False,
            @@ -279,40 +275,40 @@ _STOREANDFORWARDMESSAGE = _descriptor.Descriptor(
               oneofs=[
               ],
               serialized_start=23,
            -  serialized_end=676,
            +  serialized_end=638,
             )
             
            -_STOREANDFORWARDMESSAGE_STATISTICS.containing_type = _STOREANDFORWARDMESSAGE
            -_STOREANDFORWARDMESSAGE_HISTORY.containing_type = _STOREANDFORWARDMESSAGE
            -_STOREANDFORWARDMESSAGE.fields_by_name['rr'].enum_type = _STOREANDFORWARDMESSAGE_REQUESTRESPONSE
            -_STOREANDFORWARDMESSAGE.fields_by_name['stats'].message_type = _STOREANDFORWARDMESSAGE_STATISTICS
            -_STOREANDFORWARDMESSAGE.fields_by_name['history'].message_type = _STOREANDFORWARDMESSAGE_HISTORY
            -_STOREANDFORWARDMESSAGE_REQUESTRESPONSE.containing_type = _STOREANDFORWARDMESSAGE
            -DESCRIPTOR.message_types_by_name['StoreAndForwardMessage'] = _STOREANDFORWARDMESSAGE
            +_STOREANDFORWARD_STATISTICS.containing_type = _STOREANDFORWARD
            +_STOREANDFORWARD_HISTORY.containing_type = _STOREANDFORWARD
            +_STOREANDFORWARD.fields_by_name['rr'].enum_type = _STOREANDFORWARD_REQUESTRESPONSE
            +_STOREANDFORWARD.fields_by_name['stats'].message_type = _STOREANDFORWARD_STATISTICS
            +_STOREANDFORWARD.fields_by_name['history'].message_type = _STOREANDFORWARD_HISTORY
            +_STOREANDFORWARD_REQUESTRESPONSE.containing_type = _STOREANDFORWARD
            +DESCRIPTOR.message_types_by_name['StoreAndForward'] = _STOREANDFORWARD
             _sym_db.RegisterFileDescriptor(DESCRIPTOR)
             
            -StoreAndForwardMessage = _reflection.GeneratedProtocolMessageType('StoreAndForwardMessage', (_message.Message,), {
            +StoreAndForward = _reflection.GeneratedProtocolMessageType('StoreAndForward', (_message.Message,), {
             
               'Statistics' : _reflection.GeneratedProtocolMessageType('Statistics', (_message.Message,), {
            -    'DESCRIPTOR' : _STOREANDFORWARDMESSAGE_STATISTICS,
            +    'DESCRIPTOR' : _STOREANDFORWARD_STATISTICS,
                 '__module__' : 'storeforward_pb2'
            -    # @@protoc_insertion_point(class_scope:StoreAndForwardMessage.Statistics)
            +    # @@protoc_insertion_point(class_scope:StoreAndForward.Statistics)
                 })
               ,
             
               'History' : _reflection.GeneratedProtocolMessageType('History', (_message.Message,), {
            -    'DESCRIPTOR' : _STOREANDFORWARDMESSAGE_HISTORY,
            +    'DESCRIPTOR' : _STOREANDFORWARD_HISTORY,
                 '__module__' : 'storeforward_pb2'
            -    # @@protoc_insertion_point(class_scope:StoreAndForwardMessage.History)
            +    # @@protoc_insertion_point(class_scope:StoreAndForward.History)
                 })
               ,
            -  'DESCRIPTOR' : _STOREANDFORWARDMESSAGE,
            +  'DESCRIPTOR' : _STOREANDFORWARD,
               '__module__' : 'storeforward_pb2'
            -  # @@protoc_insertion_point(class_scope:StoreAndForwardMessage)
            +  # @@protoc_insertion_point(class_scope:StoreAndForward)
               })
            -_sym_db.RegisterMessage(StoreAndForwardMessage)
            -_sym_db.RegisterMessage(StoreAndForwardMessage.Statistics)
            -_sym_db.RegisterMessage(StoreAndForwardMessage.History)
            +_sym_db.RegisterMessage(StoreAndForward)
            +_sym_db.RegisterMessage(StoreAndForward.Statistics)
            +_sym_db.RegisterMessage(StoreAndForward.History)
             
             
             DESCRIPTOR._options = None
            @@ -328,8 +324,8 @@ DESCRIPTOR._options = None
             

            Classes

            -
            -class StoreAndForwardMessage +
            +class StoreAndForward (**kwargs)
            @@ -344,35 +340,35 @@ shown below.

          Class variables

          -
          var CLIENT_ERROR
          +
          var CLIENT_ERROR
          -
          var CLIENT_HISTORY
          +
          var CLIENT_HISTORY
          -
          var CLIENT_PING
          +
          var CLIENT_PING
          -
          var CLIENT_PONG
          +
          var CLIENT_PONG
          -
          var CLIENT_STATS
          +
          var CLIENT_STATS
          -
          var DESCRIPTOR
          +
          var DESCRIPTOR
          -
          var HISTORY_FIELD_NUMBER
          +
          var HISTORY_FIELD_NUMBER
          -
          var History
          +
          var History

          Abstract base class for protocol messages.

          Protocol message classes are almost always generated by the protocol @@ -380,43 +376,39 @@ compiler. These generated types subclass Message and implement the methods shown below.

          -
          var MAX
          +
          var ROUTER_BUSY
          -
          var ROUTER_BUSY
          +
          var ROUTER_ERROR
          -
          var ROUTER_ERROR
          +
          var ROUTER_HEARTBEAT
          -
          var ROUTER_HEARTBEAT
          +
          var ROUTER_PING
          -
          var ROUTER_PING
          +
          var ROUTER_PONG
          -
          var ROUTER_PONG
          +
          var RR_FIELD_NUMBER
          -
          var RR_FIELD_NUMBER
          +
          var RequestResponse
          -
          var RequestResponse
          +
          var STATS_FIELD_NUMBER
          -
          var STATS_FIELD_NUMBER
          -
          -
          -
          -
          var Statistics
          +
          var Statistics

          Abstract base class for protocol messages.

          Protocol message classes are almost always generated by the protocol @@ -424,14 +416,14 @@ compiler. These generated types subclass Message and implement the methods shown below.

          -
          var UNSET
          +
          var UNSET

          Static methods

          -
          +
          def FromString(s)
          @@ -446,7 +438,7 @@ shown below.

          return message
          -
          +
          def RegisterExtension(extension_handle)
          @@ -466,7 +458,7 @@ shown below.

          Instance variables

          -
          var history
          +
          var history

          Getter for history.

          @@ -489,7 +481,7 @@ shown below.

          return field_value
          -
          var rr
          +
          var rr

          Getter for rr.

          @@ -502,7 +494,7 @@ shown below.

          return self._fields.get(field, default_value)
          -
          var stats
          +
          var stats

          Getter for stats.

          @@ -528,7 +520,7 @@ shown below.

          Methods

          -
          +
          def ByteSize(self)
          @@ -559,7 +551,7 @@ shown below.

          return size
          -
          +
          def Clear(self)
          @@ -581,7 +573,7 @@ shown below.

          self._Modified()
          -
          +
          def ClearField(self, field_name)
          @@ -624,7 +616,7 @@ shown below.

          self._Modified()
          -
          +
          def DiscardUnknownFields(self)
          @@ -649,7 +641,7 @@ shown below.

          value.DiscardUnknownFields()
          -
          +
          def FindInitializationErrors(self)
          @@ -707,7 +699,7 @@ the top-level message, e.g. "foo.bar[5].baz".

          return errors
          -
          +
          def HasField(self, field_name)
          @@ -735,7 +727,7 @@ the top-level message, e.g. "foo.bar[5].baz".

          return field in self._fields
          -
          +
          def IsInitialized(self, errors=None)
          @@ -792,7 +784,7 @@ paths of all missing required fields.
          return True
          -
          +
          def ListFields(self)
          @@ -807,7 +799,7 @@ paths of all missing required fields.
          return all_fields
      -
      +
      def MergeFrom(self, msg)
      @@ -859,7 +851,7 @@ paths of all missing required fields.
      self._unknown_field_set._extend(msg._unknown_field_set)
      -
      +
      def MergeFromString(self, serialized)
      @@ -884,7 +876,7 @@ paths of all missing required fields.
      return length # Return this for legacy reasons.
      -
      +
      def SerializePartialToString(self, **kwargs)
      @@ -899,7 +891,7 @@ paths of all missing required fields.
      return out.getvalue()
      -
      +
      def SerializeToString(self, **kwargs)
      @@ -917,7 +909,7 @@ paths of all missing required fields.
      return self.SerializePartialToString(**kwargs)
      -
      +
      def SetInParent(self)
      @@ -943,7 +935,7 @@ and propagates this to our listener iff this was a state change.

      self._listener.Modified()
      -
      +
      def UnknownFields(self)
      @@ -959,7 +951,7 @@ and propagates this to our listener iff this was a state change.

      return self._unknown_field_set # pylint: disable=protected-access
      -
      +
      def WhichOneof(self, oneof_name)
      @@ -1002,47 +994,46 @@ and propagates this to our listener iff this was a state change.

    • Classes

      diff --git a/docs/meshtastic/test.html b/docs/meshtastic/test.html index d2242c1..a6bd8f7 100644 --- a/docs/meshtastic/test.html +++ b/docs/meshtastic/test.html @@ -5,7 +5,7 @@ meshtastic.test API documentation - + @@ -22,18 +22,21 @@

      Module meshtastic.test

      +

      Testing

      Expand source code -
      import logging
      -from . import util
      -from . import SerialInterface, TCPInterface, BROADCAST_NUM
      -from pubsub import pub
      +
      """ Testing
      +"""
      +import logging
       import time
       import sys
      -import threading, traceback
      +import traceback
       from dotmap import DotMap
      +from pubsub import pub
      +from . import util
      +from . import SerialInterface, TCPInterface, BROADCAST_NUM
       
       """The interfaces we are using for our tests"""
       interfaces = None
      @@ -59,7 +62,7 @@ def onReceive(packet, interface):
       
               if p.decoded.portnum == "TEXT_MESSAGE_APP":
                   # We only care a about clear text packets
      -            if receivedPackets != None:
      +            if receivedPackets is not None:
                       receivedPackets.append(p)
       
       
      @@ -103,18 +106,19 @@ def testSend(fromInterface, toInterface, isBroadcast=False, asBinary=False, want
           else:
               fromInterface.sendData((f"Binary {testNumber}").encode(
                   "utf-8"), toNode, wantAck=wantAck)
      -    for sec in range(60):  # max of 60 secs before we timeout
      +    for _ in range(60):  # max of 60 secs before we timeout
               time.sleep(1)
      -        if (len(receivedPackets) >= 1):
      +        if  len(receivedPackets) >= 1:
                   return True
           return False  # Failed to send
       
       
       def runTests(numTests=50, wantAck=False, maxFailures=0):
      +    """Run the tests."""
           logging.info(f"Running {numTests} tests with wantAck={wantAck}")
           numFail = 0
           numSuccess = 0
      -    for i in range(numTests):
      +    for _ in range(numTests):
               global testNumber
               testNumber = testNumber + 1
               isBroadcast = True
      @@ -144,6 +148,7 @@ def runTests(numTests=50, wantAck=False, maxFailures=0):
       
       
       def testThread(numTests=50):
      +    """Test thread"""
           logging.info("Found devices, starting tests...")
           runTests(numTests, wantAck=True)
           # Allow a few dropped packets
      @@ -156,6 +161,7 @@ def onConnection(topic=pub.AUTO_TOPIC):
       
       
       def openDebugLog(portName):
      +    """Open the debug log file"""
           debugname = "log" + portName.replace("/", "_")
           logging.info(f"Writing serial debugging to {debugname}")
           return open(debugname, 'w+', buffering=1)
      @@ -169,7 +175,7 @@ def testAll():
               Exception: If not enough devices are found
           """
           ports = util.findPorts()
      -    if (len(ports) < 2):
      +    if len(ports) < 2:
               raise Exception("Must have at least two devices connected to USB")
       
           pub.subscribe(onConnection, "meshtastic.connection")
      @@ -272,7 +278,7 @@ def testSimulator():
       
               if p.decoded.portnum == "TEXT_MESSAGE_APP":
                   # We only care a about clear text packets
      -            if receivedPackets != None:
      +            if receivedPackets is not None:
                       receivedPackets.append(p)
    • @@ -280,12 +286,13 @@ def testSimulator(): def openDebugLog(portName)
      -
      +

      Open the debug log file

      Expand source code
      def openDebugLog(portName):
      +    """Open the debug log file"""
           debugname = "log" + portName.replace("/", "_")
           logging.info(f"Writing serial debugging to {debugname}")
           return open(debugname, 'w+', buffering=1)
      @@ -295,16 +302,17 @@ def testSimulator(): def runTests(numTests=50, wantAck=False, maxFailures=0)
      -
      +

      Run the tests.

      Expand source code
      def runTests(numTests=50, wantAck=False, maxFailures=0):
      +    """Run the tests."""
           logging.info(f"Running {numTests} tests with wantAck={wantAck}")
           numFail = 0
           numSuccess = 0
      -    for i in range(numTests):
      +    for _ in range(numTests):
               global testNumber
               testNumber = testNumber + 1
               isBroadcast = True
      @@ -370,7 +378,7 @@ def testSimulator():
               Exception: If not enough devices are found
           """
           ports = util.findPorts()
      -    if (len(ports) < 2):
      +    if len(ports) < 2:
               raise Exception("Must have at least two devices connected to USB")
       
           pub.subscribe(onConnection, "meshtastic.connection")
      @@ -429,9 +437,9 @@ toInterface {[type]} – [description]

      else: fromInterface.sendData((f"Binary {testNumber}").encode( "utf-8"), toNode, wantAck=wantAck) - for sec in range(60): # max of 60 secs before we timeout + for _ in range(60): # max of 60 secs before we timeout time.sleep(1) - if (len(receivedPackets) >= 1): + if len(receivedPackets) >= 1: return True return False # Failed to send
      @@ -478,12 +486,13 @@ python3 -c 'from meshtastic.test import testSimulator; testSimulator()'

      def testThread(numTests=50)
      -
      +

      Test thread

      Expand source code
      def testThread(numTests=50):
      +    """Test thread"""
           logging.info("Found devices, starting tests...")
           runTests(numTests, wantAck=True)
           # Allow a few dropped packets
      diff --git a/docs/meshtastic/tunnel.html b/docs/meshtastic/tunnel.html
      index d952a92..61e0224 100644
      --- a/docs/meshtastic/tunnel.html
      +++ b/docs/meshtastic/tunnel.html
      @@ -5,7 +5,7 @@
       
       
       meshtastic.tunnel API documentation
      -
      +
       
       
       
      @@ -22,11 +22,25 @@
       

      Module meshtastic.tunnel

      +

      Code for IP tunnel over a mesh

      +

      Note python-pytuntap was too buggy

      +

      using pip3 install pytap2

      +

      make sure to "sudo setcap cap_net_admin+eip /usr/bin/python3.8" so python can access tun device without being root

      +

      sudo ip tuntap del mode tun tun0

      +

      sudo bin/run.sh –port /dev/ttyUSB0 –setch-shortfast

      +

      sudo bin/run.sh –port /dev/ttyUSB0 –tunnel –debug

      +

      ssh -Y root@192.168.10.151 (or dietpi), default password p

      +

      ncat -e /bin/cat -k -u -l 1235

      +

      ncat -u 10.115.64.152 1235

      +

      ping -c 1 -W 20 10.115.64.152

      +

      ping -i 30 -W 30 10.115.64.152

      +

      FIXME: use a more optimal MTU

      Expand source code -
      # code for IP tunnel over a mesh
      +
      """ Code for IP tunnel over a mesh
      +
       # Note python-pytuntap was too buggy
       # using pip3 install pytap2
       # make sure to "sudo setcap cap_net_admin+eip /usr/bin/python3.8" so python can access tun device without being root
      @@ -40,11 +54,12 @@
       # ping -i 30 -W 30 10.115.64.152
       
       # FIXME: use a more optimal MTU
      +"""
       
      -from . import portnums_pb2
      -from pubsub import pub
       import logging
       import threading
      +from pubsub import pub
      +from . import portnums_pb2
       
       # A new non standard log level that is lower level than DEBUG
       LOG_TRACE = 5
      @@ -545,7 +560,20 @@ subnet is used to construct our network number (normally 10.115.x.x)