2022-11-29 16:53:29 +01:00
|
|
|
from eive_tmtc.gomspace.gomspace_common import TableEntry
|
2020-12-29 11:29:03 +01:00
|
|
|
|
|
|
|
|
2022-08-11 14:45:24 +02:00
|
|
|
class PduConfigTable:
|
2022-09-01 16:58:31 +02:00
|
|
|
out_en_0 = TableEntry(bytes([0x00, 0x48]), TableEntry.uint8_size)
|
|
|
|
out_en_1 = TableEntry(bytes([0x00, 0x49]), TableEntry.uint8_size)
|
|
|
|
out_en_2 = TableEntry(bytes([0x00, 0x4A]), TableEntry.uint8_size)
|
|
|
|
out_en_3 = TableEntry(bytes([0x00, 0x4B]), TableEntry.uint8_size)
|
|
|
|
out_en_4 = TableEntry(bytes([0x00, 0x4C]), TableEntry.uint8_size)
|
|
|
|
out_en_5 = TableEntry(bytes([0x00, 0x4D]), TableEntry.uint8_size)
|
|
|
|
out_en_6 = TableEntry(bytes([0x00, 0x4E]), TableEntry.uint8_size)
|
|
|
|
out_en_7 = TableEntry(bytes([0x00, 0x4F]), TableEntry.uint8_size)
|
|
|
|
out_en_8 = TableEntry(bytes([0x00, 0x50]), TableEntry.uint8_size)
|
|
|
|
|
|
|
|
# When channel consumes more than cur_lu_lim, channel is turned off immediately
|
2020-12-29 11:29:03 +01:00
|
|
|
cur_lu_lim_0 = TableEntry(bytearray([0x00, 0xB8]), TableEntry.uint16_size)
|
2022-09-01 16:58:31 +02:00
|
|
|
INIT_OUT_SAFE_CH_0 = TableEntry(bytes([0x00, 0x80]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_1 = TableEntry(bytes([0x00, 0x80 + 1]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_2 = TableEntry(bytes([0x00, 0x80 + 2]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_3 = TableEntry(bytes([0x00, 0x80 + 3]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_4 = TableEntry(bytes([0x00, 0x80 + 4]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_5 = TableEntry(bytes([0x00, 0x80 + 5]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_6 = TableEntry(bytes([0x00, 0x80 + 6]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_7 = TableEntry(bytes([0x00, 0x80 + 7]), TableEntry.uint8_size)
|
|
|
|
INIT_OUT_SAFE_CH_8 = TableEntry(bytes([0x00, 0x80 + 8]), TableEntry.uint8_size)
|
2020-12-29 11:29:03 +01:00
|
|
|
|
|
|
|
|
2022-09-01 16:58:31 +02:00
|
|
|
OUT_ENABLE_LIST = [
|
2022-08-11 14:45:24 +02:00
|
|
|
PduConfigTable.out_en_0,
|
|
|
|
PduConfigTable.out_en_1,
|
|
|
|
PduConfigTable.out_en_2,
|
|
|
|
PduConfigTable.out_en_3,
|
|
|
|
PduConfigTable.out_en_4,
|
|
|
|
PduConfigTable.out_en_5,
|
|
|
|
PduConfigTable.out_en_6,
|
|
|
|
PduConfigTable.out_en_7,
|
2022-08-11 18:10:15 +02:00
|
|
|
PduConfigTable.out_en_8,
|
2022-08-11 14:45:24 +02:00
|
|
|
]
|
|
|
|
|
|
|
|
|
|
|
|
class PduHkTable:
|
2020-12-29 11:29:03 +01:00
|
|
|
temperature = TableEntry(bytearray([0x00, 0x28]), TableEntry.uint16_size)
|
|
|
|
# Ground WDT value (remaining seconds until reboot)
|
2021-02-03 14:14:54 +01:00
|
|
|
wdt_gnd_left = TableEntry(bytearray([0x00, 0x80]), TableEntry.uint32_size)
|