bump tmtccmd
This commit is contained in:
parent
556060a3f3
commit
57f2143d79
@ -10,6 +10,8 @@ list yields a list of all related PRs for each release.
|
|||||||
|
|
||||||
# [unreleased]
|
# [unreleased]
|
||||||
|
|
||||||
|
tmtccmd version 4.0.0
|
||||||
|
|
||||||
# [v2.12.7] 2023-02-17
|
# [v2.12.7] 2023-02-17
|
||||||
|
|
||||||
- Re-run generators
|
- Re-run generators
|
||||||
|
@ -4,3 +4,4 @@ from .test import add_test_defs
|
|||||||
from .time import add_time_cmds
|
from .time import add_time_cmds
|
||||||
from .health import add_health_cmd_defs
|
from .health import add_health_cmd_defs
|
||||||
from .system import add_system_cmd_defs
|
from .system import add_system_cmd_defs
|
||||||
|
from .tm_store import add_persistent_tm_store_cmd_defs
|
||||||
|
@ -1,8 +1,55 @@
|
|||||||
|
import struct
|
||||||
|
|
||||||
from eive_tmtc.config.definitions import CustomServiceList
|
from eive_tmtc.config.definitions import CustomServiceList
|
||||||
|
from tmtccmd.config import TmtcDefinitionWrapper
|
||||||
|
from tmtccmd.config.tmtc import tmtc_definitions_provider, OpCodeEntry
|
||||||
from tmtccmd.tc import service_provider
|
from tmtccmd.tc import service_provider
|
||||||
from tmtccmd.tc.decorator import ServiceProviderParams
|
from tmtccmd.tc.decorator import ServiceProviderParams
|
||||||
|
from dateutil.parser import parse
|
||||||
|
|
||||||
|
|
||||||
|
class OpCode:
|
||||||
|
DUMP = "dump"
|
||||||
|
DELETE = "delete"
|
||||||
|
|
||||||
|
|
||||||
|
class Info:
|
||||||
|
DUMP = "Dump Telemetry Packets"
|
||||||
|
DELETE = "Delete Telemetry Packets"
|
||||||
|
|
||||||
|
|
||||||
@service_provider(CustomServiceList.TM_STORE)
|
@service_provider(CustomServiceList.TM_STORE)
|
||||||
def pack_tm_store_commands(p: ServiceProviderParams):
|
def pack_tm_store_commands(p: ServiceProviderParams):
|
||||||
pass
|
q = p.queue_helper
|
||||||
|
o = p.op_code
|
||||||
|
if o == OpCode.DELETE:
|
||||||
|
q.add_log_cmd(Info.DELETE)
|
||||||
|
delete_start_time = parse(
|
||||||
|
input(
|
||||||
|
"Please enter delete start time in UTC ISO format (YYYY-MM-DDThh:mm:ssZ"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
delete_end_time = parse(
|
||||||
|
input(
|
||||||
|
"Please enter delete end time in UTC ISO format (YYYY-MM-DDThh:mm:ssZ"
|
||||||
|
)
|
||||||
|
)
|
||||||
|
start_stamp = delete_start_time.timestamp()
|
||||||
|
end_stamp = delete_end_time.timestamp()
|
||||||
|
app_data = bytearray(struct.pack("!I", start_stamp))
|
||||||
|
app_data.extend(struct.pack("!I", end_stamp))
|
||||||
|
|
||||||
|
pass
|
||||||
|
elif o == OpCode.DUMP:
|
||||||
|
q.add_log_cmd(Info.DUMP)
|
||||||
|
pass
|
||||||
|
|
||||||
|
|
||||||
|
@tmtc_definitions_provider
|
||||||
|
def add_persistent_tm_store_cmd_defs(defs: TmtcDefinitionWrapper):
|
||||||
|
oce = OpCodeEntry()
|
||||||
|
oce.add(keys=OpCode.DELETE, info=Info.DELETE)
|
||||||
|
oce.add(keys=OpCode.DUMP, info=Info.DUMP)
|
||||||
|
defs.add_service(
|
||||||
|
CustomServiceList.TM_STORE, "Persistent TM Store", op_code_entry=oce
|
||||||
|
)
|
||||||
|
@ -27,7 +27,8 @@ classifiers =
|
|||||||
|
|
||||||
[options]
|
[options]
|
||||||
install_requires =
|
install_requires =
|
||||||
tmtccmd @ git+https://github.com/robamu-org/tmtccmd@v4.0.0rc2
|
tmtccmd ~= 4.0
|
||||||
|
python-dateutil ~= 2.8
|
||||||
# tmtccmd @ git+https://github.com/robamu-org/tmtccmd@<gitRev>#egg=tmtccmd
|
# tmtccmd @ git+https://github.com/robamu-org/tmtccmd@<gitRev>#egg=tmtccmd
|
||||||
packages = find:
|
packages = find:
|
||||||
python_requires = >=3.10
|
python_requires = >=3.10
|
||||||
|
Loading…
Reference in New Issue
Block a user