mirror of
https://github.com/meshtastic/python.git
synced 2026-01-22 06:38:04 -05:00
Compare commits
4 Commits
1.3.34alph
...
1.3.36
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a74ec12445 | ||
|
|
262e921a81 | ||
|
|
0c7b9e10f4 | ||
|
|
ab8b930365 |
@@ -285,6 +285,10 @@ def onConnected(interface):
|
|||||||
closeNow = True
|
closeNow = True
|
||||||
interface.getNode(args.dest).factoryReset()
|
interface.getNode(args.dest).factoryReset()
|
||||||
|
|
||||||
|
if args.reset_nodedb:
|
||||||
|
closeNow = True
|
||||||
|
interface.getNode(args.dest).resetNodeDb()
|
||||||
|
|
||||||
if args.sendtext:
|
if args.sendtext:
|
||||||
closeNow = True
|
closeNow = True
|
||||||
channelIndex = 0
|
channelIndex = 0
|
||||||
@@ -876,6 +880,9 @@ def initParser():
|
|||||||
|
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
"--factory-reset", help="Tell the destination node to install the default config", action="store_true")
|
"--factory-reset", help="Tell the destination node to install the default config", action="store_true")
|
||||||
|
|
||||||
|
parser.add_argument(
|
||||||
|
"--reset-nodedb", help="Tell the destination node clear its list of nodes", action="store_true")
|
||||||
|
|
||||||
parser.add_argument(
|
parser.add_argument(
|
||||||
"--reply", help="Reply to received messages",
|
"--reply", help="Reply to received messages",
|
||||||
|
|||||||
@@ -482,6 +482,14 @@ class Node:
|
|||||||
|
|
||||||
return self._sendAdmin(p)
|
return self._sendAdmin(p)
|
||||||
|
|
||||||
|
def resetNodeDb(self):
|
||||||
|
"""Tell the node to reset its list of nodes."""
|
||||||
|
p = admin_pb2.AdminMessage()
|
||||||
|
p.nodedb_reset = True
|
||||||
|
logging.info(f"Telling node to reset the NodeDB")
|
||||||
|
|
||||||
|
return self._sendAdmin(p)
|
||||||
|
|
||||||
def _fixupChannels(self):
|
def _fixupChannels(self):
|
||||||
"""Fixup indexes and add disabled channels as needed"""
|
"""Fixup indexes and add disabled channels as needed"""
|
||||||
|
|
||||||
|
|||||||
2
setup.py
2
setup.py
@@ -12,7 +12,7 @@ with open("README.md", "r") as fh:
|
|||||||
# This call to setup() does all the work
|
# This call to setup() does all the work
|
||||||
setup(
|
setup(
|
||||||
name="meshtastic",
|
name="meshtastic",
|
||||||
version="1.3.33alpha",
|
version="1.3.35",
|
||||||
description="Python API & client shell for talking to Meshtastic devices",
|
description="Python API & client shell for talking to Meshtastic devices",
|
||||||
long_description=long_description,
|
long_description=long_description,
|
||||||
long_description_content_type="text/markdown",
|
long_description_content_type="text/markdown",
|
||||||
|
|||||||
Reference in New Issue
Block a user