import_private_key

This commit is contained in:
Florent
2025-12-07 17:41:37 +01:00
parent 01661a9654
commit 6579efe6b4
2 changed files with 6 additions and 1 deletions

View File

@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
[project] [project]
name = "meshcore" name = "meshcore"
version = "2.2.2" version = "2.2.3"
authors = [ authors = [
{ name="Florent de Lamotte", email="florent@frizoncorrea.fr" }, { name="Florent de Lamotte", email="florent@frizoncorrea.fr" },
{ name="Alex Wolden", email="awolden@gmail.com" }, { name="Alex Wolden", email="awolden@gmail.com" },

View File

@@ -206,6 +206,11 @@ class DeviceCommands(CommandHandlerBase):
logger.debug("Requesting private key export") logger.debug("Requesting private key export")
return await self.send(b"\x17", [EventType.PRIVATE_KEY, EventType.DISABLED, EventType.ERROR]) return await self.send(b"\x17", [EventType.PRIVATE_KEY, EventType.DISABLED, EventType.ERROR])
async def import_private_key(self, key) -> Event:
logger.debug("Requesting private key import")
data = b"\x18" + key
return await self.send(data, [EventType.OK, EventType.ERROR])
async def get_stats_core(self) -> Event: async def get_stats_core(self) -> Event:
logger.debug("Getting core statistics") logger.debug("Getting core statistics")
# CMD_GET_STATS (56) + STATS_TYPE_CORE (0) # CMD_GET_STATS (56) + STATS_TYPE_CORE (0)