Compare commits
8 Commits
Author | SHA1 | Date | |
---|---|---|---|
24a4fcdeaf | |||
30216bcd1b | |||
8a600f9d2b | |||
68e3203540 | |||
16e4853582 | |||
140c827ce7 | |||
c421f3f5d7 | |||
4cfd2d684a |
@ -8,6 +8,14 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/).
|
|||||||
The [milestone](https://egit.irs.uni-stuttgart.de/eive/eive-obsw/milestones)
|
The [milestone](https://egit.irs.uni-stuttgart.de/eive/eive-obsw/milestones)
|
||||||
list yields a list of all related PRs for each release.
|
list yields a list of all related PRs for each release.
|
||||||
|
|
||||||
|
# [v2.0.2] 01.12.2022
|
||||||
|
|
||||||
|
- Bumped dependencies, small fix to allow working script if PyQt is not installed
|
||||||
|
|
||||||
|
# [v2.0.1] 29.11.2022
|
||||||
|
|
||||||
|
- Minor bugfix
|
||||||
|
|
||||||
# [v2.0.0] 29.11.2022
|
# [v2.0.0] 29.11.2022
|
||||||
|
|
||||||
- The tmtc program is installable now, which allow re-using it in other Python applications
|
- The tmtc program is installable now, which allow re-using it in other Python applications
|
||||||
|
2
deps/spacepackets
vendored
2
deps/spacepackets
vendored
Submodule deps/spacepackets updated: 84f1af27d4...83622451c3
2
deps/tmtccmd
vendored
2
deps/tmtccmd
vendored
Submodule deps/tmtccmd updated: ad8f049d66...4ecbaee2a7
@ -1,6 +1,11 @@
|
|||||||
|
from pathlib import Path
|
||||||
|
|
||||||
SW_NAME = "eive-tmtc"
|
SW_NAME = "eive-tmtc"
|
||||||
VERSION_MAJOR = 2
|
VERSION_MAJOR = 2
|
||||||
VERSION_MINOR = 0
|
VERSION_MINOR = 0
|
||||||
VERSION_SUBMINOR = 0
|
VERSION_REVISION = 2
|
||||||
|
|
||||||
__version__ = "2.0.0"
|
__version__ = "2.0.2"
|
||||||
|
|
||||||
|
EIVE_TMTC_ROOT = Path(__file__).parent
|
||||||
|
PACKAGE_ROOT = EIVE_TMTC_ROOT.parent
|
||||||
|
@ -9,6 +9,8 @@ import enum
|
|||||||
from spacepackets import PacketType
|
from spacepackets import PacketType
|
||||||
from spacepackets.ccsds import PacketId
|
from spacepackets.ccsds import PacketId
|
||||||
from spacepackets.util import UnsignedByteField
|
from spacepackets.util import UnsignedByteField
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
|
|
||||||
PUS_APID = 0x65
|
PUS_APID = 0x65
|
||||||
CFDP_APID = 0x66
|
CFDP_APID = 0x66
|
||||||
|
21
eive_tmtc/config/events.py
Normal file
21
eive_tmtc/config/events.py
Normal file
@ -0,0 +1,21 @@
|
|||||||
|
import os
|
||||||
|
|
||||||
|
from eive_tmtc import EIVE_TMTC_ROOT
|
||||||
|
from tmtccmd import get_console_logger
|
||||||
|
from tmtccmd.fsfw import parse_fsfw_events_csv
|
||||||
|
from tmtccmd.pus.pus_5_event import EventDictT
|
||||||
|
|
||||||
|
LOGGER = get_console_logger()
|
||||||
|
DEFAULT_EVENTS_CSV_PATH = EIVE_TMTC_ROOT / "/config/events.csv"
|
||||||
|
__EVENT_DICT = None
|
||||||
|
|
||||||
|
|
||||||
|
def get_event_dict() -> EventDictT:
|
||||||
|
global __EVENT_DICT
|
||||||
|
if __EVENT_DICT is None:
|
||||||
|
if os.path.exists(DEFAULT_EVENTS_CSV_PATH):
|
||||||
|
__EVENT_DICT = parse_fsfw_events_csv(DEFAULT_EVENTS_CSV_PATH)
|
||||||
|
else:
|
||||||
|
LOGGER.warning(f"No Event CSV file found at {DEFAULT_EVENTS_CSV_PATH}")
|
||||||
|
__EVENT_DICT = dict()
|
||||||
|
return __EVENT_DICT
|
@ -4,13 +4,15 @@
|
|||||||
it to your needs.
|
it to your needs.
|
||||||
"""
|
"""
|
||||||
import os.path
|
import os.path
|
||||||
|
|
||||||
|
from eive_tmtc import EIVE_TMTC_ROOT
|
||||||
from tmtccmd.util.obj_id import ObjectIdDictT
|
from tmtccmd.util.obj_id import ObjectIdDictT
|
||||||
from tmtccmd.fsfw import parse_fsfw_objects_csv
|
from tmtccmd.fsfw import parse_fsfw_objects_csv
|
||||||
from tmtccmd.logging import get_console_logger
|
from tmtccmd.logging import get_console_logger
|
||||||
|
|
||||||
|
|
||||||
LOGGER = get_console_logger()
|
LOGGER = get_console_logger()
|
||||||
DEFAULT_OBJECTS_CSV_PATH = "config/objects.csv"
|
DEFAULT_OBJECTS_CSV_PATH = EIVE_TMTC_ROOT / "config/objects.csv"
|
||||||
__OBJECT_ID_DICT = None
|
__OBJECT_ID_DICT = None
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,8 +1,10 @@
|
|||||||
import os
|
import os
|
||||||
|
|
||||||
|
from eive_tmtc import EIVE_TMTC_ROOT
|
||||||
from tmtccmd.fsfw import parse_fsfw_returnvalues_csv, RetvalDictT
|
from tmtccmd.fsfw import parse_fsfw_returnvalues_csv, RetvalDictT
|
||||||
from tmtccmd.logging import get_console_logger
|
from tmtccmd.logging import get_console_logger
|
||||||
|
|
||||||
DEFAULT_RETVAL_CSV_NAME = "config/returnvalues.csv"
|
DEFAULT_RETVAL_CSV_NAME = EIVE_TMTC_ROOT / "config/returnvalues.csv"
|
||||||
__RETVAL_DICT = None
|
__RETVAL_DICT = None
|
||||||
LOGGER = get_console_logger()
|
LOGGER = get_console_logger()
|
||||||
|
|
||||||
|
@ -7,10 +7,6 @@ from tmtccmd.util import ObjectIdU32, ObjectIdBase
|
|||||||
from eive_tmtc.tmtc.common import pack_mode_cmd_with_info
|
from eive_tmtc.tmtc.common import pack_mode_cmd_with_info
|
||||||
import eive_tmtc.config.object_ids as obj_ids
|
import eive_tmtc.config.object_ids as obj_ids
|
||||||
|
|
||||||
from eive_tmtc.pus_tc.prompt_parameters import (
|
|
||||||
prompt_parameters_cli,
|
|
||||||
prompt_parameters_gui,
|
|
||||||
)
|
|
||||||
|
|
||||||
|
|
||||||
class OpCodes:
|
class OpCodes:
|
||||||
@ -26,11 +22,15 @@ class Info:
|
|||||||
def pack_cmd_ctrl_to_prompted_mode(
|
def pack_cmd_ctrl_to_prompted_mode(
|
||||||
q: DefaultPusQueueHelper, object_id: ObjectIdU32, gui: bool
|
q: DefaultPusQueueHelper, object_id: ObjectIdU32, gui: bool
|
||||||
):
|
):
|
||||||
|
from eive_tmtc.pus_tc.prompt_parameters import (
|
||||||
|
prompt_parameters_cli,
|
||||||
|
)
|
||||||
param_list = [
|
param_list = [
|
||||||
{"name": "Mode", "defaultValue": "2"},
|
{"name": "Mode", "defaultValue": "2"},
|
||||||
{"name": "Submode", "defaultValue": "0"},
|
{"name": "Submode", "defaultValue": "0"},
|
||||||
]
|
]
|
||||||
if gui:
|
if gui:
|
||||||
|
from eive_tmtc.pus_tc.prompt_parameters import prompt_parameters_gui
|
||||||
parameters = prompt_parameters_gui(param_list)
|
parameters = prompt_parameters_gui(param_list)
|
||||||
else:
|
else:
|
||||||
parameters = prompt_parameters_cli(param_list)
|
parameters = prompt_parameters_cli(param_list)
|
||||||
|
@ -10,6 +10,7 @@ from tmtccmd.config import TmtcDefinitionWrapper, OpCodeEntry
|
|||||||
from tmtccmd.config.tmtc import tmtc_definitions_provider
|
from tmtccmd.config.tmtc import tmtc_definitions_provider
|
||||||
|
|
||||||
from tmtccmd.tc import DefaultPusQueueHelper
|
from tmtccmd.tc import DefaultPusQueueHelper
|
||||||
|
from tmtccmd.tc.decorator import ServiceProviderParams
|
||||||
from tmtccmd.tc.pus_11_tc_sched import (
|
from tmtccmd.tc.pus_11_tc_sched import (
|
||||||
generate_time_tagged_cmd,
|
generate_time_tagged_cmd,
|
||||||
generate_enable_tc_sched_cmd,
|
generate_enable_tc_sched_cmd,
|
||||||
@ -32,7 +33,11 @@ from eive_tmtc.pus_tc.devs.gps import SetIds as GpsSetIds
|
|||||||
from eive_tmtc.tmtc.acs.imtq import ImtqSetIds
|
from eive_tmtc.tmtc.acs.imtq import ImtqSetIds
|
||||||
from eive_tmtc.pus_tc.devs.sus import SetIds
|
from eive_tmtc.pus_tc.devs.sus import SetIds
|
||||||
from eive_tmtc.pus_tc.devs.star_tracker import SetIds as StrSetIds
|
from eive_tmtc.pus_tc.devs.star_tracker import SetIds as StrSetIds
|
||||||
from eive_tmtc.tmtc.acs.reaction_wheels import RwSetIds, rw_speed_up_cmd_consec
|
from eive_tmtc.tmtc.acs.reaction_wheels import (
|
||||||
|
RwSetIds,
|
||||||
|
rw_speed_up_cmd_consec,
|
||||||
|
rw_speed_down_cmd_consec,
|
||||||
|
)
|
||||||
from eive_tmtc.pus_tc.system.controllers import (
|
from eive_tmtc.pus_tc.system.controllers import (
|
||||||
pack_cmd_ctrl_to_off,
|
pack_cmd_ctrl_to_off,
|
||||||
pack_cmd_ctrl_to_nml,
|
pack_cmd_ctrl_to_nml,
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import logging
|
|
||||||
import os.path
|
|
||||||
from datetime import datetime
|
from datetime import datetime
|
||||||
|
|
||||||
|
from eive_tmtc.config.events import get_event_dict
|
||||||
from eive_tmtc.config.object_ids import get_object_ids
|
from eive_tmtc.config.object_ids import get_object_ids
|
||||||
from eive_tmtc.pus_tm.defs import PrintWrapper
|
from eive_tmtc.pus_tm.defs import PrintWrapper
|
||||||
from eive_tmtc.pus_tm.verification_handler import generic_retval_printout
|
from eive_tmtc.pus_tm.verification_handler import generic_retval_printout
|
||||||
@ -10,23 +10,9 @@ from tmtccmd.tc.pus_200_fsfw_modes import Modes
|
|||||||
from tmtccmd.tm import Service5Tm
|
from tmtccmd.tm import Service5Tm
|
||||||
from tmtccmd.logging import get_console_logger
|
from tmtccmd.logging import get_console_logger
|
||||||
from tmtccmd.util.tmtc_printer import FsfwTmTcPrinter
|
from tmtccmd.util.tmtc_printer import FsfwTmTcPrinter
|
||||||
from tmtccmd.fsfw import parse_fsfw_events_csv, EventDictT, EventInfo
|
from tmtccmd.fsfw import EventInfo
|
||||||
|
|
||||||
|
|
||||||
LOGGER = get_console_logger()
|
LOGGER = get_console_logger()
|
||||||
DEFAULT_EVENTS_CSV_PATH = "config/events.csv"
|
|
||||||
__EVENT_DICT = None
|
|
||||||
|
|
||||||
|
|
||||||
def get_event_dict() -> EventDictT:
|
|
||||||
global __EVENT_DICT
|
|
||||||
if __EVENT_DICT is None:
|
|
||||||
if os.path.exists(DEFAULT_EVENTS_CSV_PATH):
|
|
||||||
__EVENT_DICT = parse_fsfw_events_csv(DEFAULT_EVENTS_CSV_PATH)
|
|
||||||
else:
|
|
||||||
LOGGER.warning(f"No Event CSV file found at {DEFAULT_EVENTS_CSV_PATH}")
|
|
||||||
__EVENT_DICT = dict()
|
|
||||||
return __EVENT_DICT
|
|
||||||
|
|
||||||
|
|
||||||
def handle_event_packet(raw_tm: bytes, printer: FsfwTmTcPrinter):
|
def handle_event_packet(raw_tm: bytes, printer: FsfwTmTcPrinter):
|
||||||
|
@ -6,7 +6,7 @@ from tmtccmd.config.tmtc import (
|
|||||||
TmtcDefinitionWrapper,
|
TmtcDefinitionWrapper,
|
||||||
OpCodeEntry,
|
OpCodeEntry,
|
||||||
)
|
)
|
||||||
from tmtccmd.tc import service_provider
|
from tmtccmd.tc import service_provider, DefaultPusQueueHelper
|
||||||
from tmtccmd.tc.decorator import ServiceProviderParams
|
from tmtccmd.tc.decorator import ServiceProviderParams
|
||||||
from tmtccmd.tc.pus_200_fsfw_modes import Modes
|
from tmtccmd.tc.pus_200_fsfw_modes import Modes
|
||||||
from eive_tmtc.config.object_ids import ACS_BOARD_ASS_ID
|
from eive_tmtc.config.object_ids import ACS_BOARD_ASS_ID
|
||||||
@ -30,10 +30,7 @@ class DualSideSubmodes(enum.IntEnum):
|
|||||||
DUAL_SIDE = 2
|
DUAL_SIDE = 2
|
||||||
|
|
||||||
|
|
||||||
@service_provider(CustomServiceList.ACS_BRD_ASS)
|
def pack_acs_command(q: DefaultPusQueueHelper, op_code: str):
|
||||||
def pack_acs_command(p: ServiceProviderParams):
|
|
||||||
op_code = p.op_code
|
|
||||||
q = p.queue_helper
|
|
||||||
if op_code in AcsOpCodes.ACS_ASS_A_SIDE:
|
if op_code in AcsOpCodes.ACS_ASS_A_SIDE:
|
||||||
pack_mode_cmd_with_info(
|
pack_mode_cmd_with_info(
|
||||||
object_id=ACS_BOARD_ASS_ID,
|
object_id=ACS_BOARD_ASS_ID,
|
||||||
@ -92,6 +89,13 @@ def pack_acs_command(p: ServiceProviderParams):
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
@service_provider(CustomServiceList.ACS_BRD_ASS)
|
||||||
|
def pack_acs_command_provider(p: ServiceProviderParams):
|
||||||
|
op_code = p.op_code
|
||||||
|
q = p.queue_helper
|
||||||
|
pack_acs_command(q, op_code)
|
||||||
|
|
||||||
|
|
||||||
@tmtc_definitions_provider
|
@tmtc_definitions_provider
|
||||||
def add_acs_board_cmds(defs: TmtcDefinitionWrapper):
|
def add_acs_board_cmds(defs: TmtcDefinitionWrapper):
|
||||||
oce = OpCodeEntry()
|
oce = OpCodeEntry()
|
||||||
|
@ -7,7 +7,7 @@ from tmtccmd.config.tmtc import (
|
|||||||
TmtcDefinitionWrapper,
|
TmtcDefinitionWrapper,
|
||||||
OpCodeEntry,
|
OpCodeEntry,
|
||||||
)
|
)
|
||||||
from tmtccmd.tc import service_provider
|
from tmtccmd.tc import service_provider, DefaultPusQueueHelper
|
||||||
from tmtccmd.tc.decorator import ServiceProviderParams
|
from tmtccmd.tc.decorator import ServiceProviderParams
|
||||||
from tmtccmd.tc.pus_200_fsfw_modes import Modes
|
from tmtccmd.tc.pus_200_fsfw_modes import Modes
|
||||||
|
|
||||||
@ -19,10 +19,7 @@ class SusOpCodes:
|
|||||||
SUS_ASS_OFF = ["3", "off"]
|
SUS_ASS_OFF = ["3", "off"]
|
||||||
|
|
||||||
|
|
||||||
@service_provider(CustomServiceList.SUS_BRD_ASS)
|
def pack_sus_cmds(q: DefaultPusQueueHelper, op_code: str):
|
||||||
def pack_sus_cmds(p: ServiceProviderParams):
|
|
||||||
op_code = p.op_code
|
|
||||||
q = p.queue_helper
|
|
||||||
if op_code in SusOpCodes.SUS_ASS_NOM_SIDE:
|
if op_code in SusOpCodes.SUS_ASS_NOM_SIDE:
|
||||||
pack_mode_cmd_with_info(
|
pack_mode_cmd_with_info(
|
||||||
object_id=SUS_BOARD_ASS_ID,
|
object_id=SUS_BOARD_ASS_ID,
|
||||||
@ -57,6 +54,13 @@ def pack_sus_cmds(p: ServiceProviderParams):
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
@service_provider(CustomServiceList.SUS_BRD_ASS)
|
||||||
|
def pack_sus_cmds_prvoider(p: ServiceProviderParams):
|
||||||
|
op_code = p.op_code
|
||||||
|
q = p.queue_helper
|
||||||
|
pack_sus_cmds(q, op_code)
|
||||||
|
|
||||||
|
|
||||||
@tmtc_definitions_provider
|
@tmtc_definitions_provider
|
||||||
def add_sus_board_cmds(defs: TmtcDefinitionWrapper):
|
def add_sus_board_cmds(defs: TmtcDefinitionWrapper):
|
||||||
oce = OpCodeEntry()
|
oce = OpCodeEntry()
|
||||||
|
@ -27,7 +27,7 @@ classifiers =
|
|||||||
|
|
||||||
[options]
|
[options]
|
||||||
install_requires =
|
install_requires =
|
||||||
tmtccmd >= 3.0.0rc2
|
tmtccmd >= 3.0.0rc3
|
||||||
packages = find:
|
packages = find:
|
||||||
python_requires = >=3.8
|
python_requires = >=3.8
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user