##// END OF EJS Templates
one constant removed, RID_ME_LFR_BUFFER not used
paul -
r42:b0e42058c39c default
parent child
Show More
@@ -1,771 +1,770
1 #ifndef CCSDS_TYPES_H_INCLUDED
1 #ifndef CCSDS_TYPES_H_INCLUDED
2 #define CCSDS_TYPES_H_INCLUDED
2 #define CCSDS_TYPES_H_INCLUDED
3
3
4 #define CCSDS_PROTOCOLE_EXTRA_BYTES 4
4 #define CCSDS_PROTOCOLE_EXTRA_BYTES 4
5 #define CCSDS_TC_TM_PACKET_OFFSET 7
5 #define CCSDS_TC_TM_PACKET_OFFSET 7
6 #define CCSDS_TELEMETRY_HEADER_LENGTH 16+4
6 #define CCSDS_TELEMETRY_HEADER_LENGTH 16+4
7 #define CCSDS_TM_PKT_MAX_SIZE 4412
7 #define CCSDS_TM_PKT_MAX_SIZE 4412
8 #define CCSDS_TELECOMMAND_HEADER_LENGTH 10+4
8 #define CCSDS_TELECOMMAND_HEADER_LENGTH 10+4
9 #define CCSDS_TC_PKT_MAX_SIZE 256
9 #define CCSDS_TC_PKT_MAX_SIZE 256
10 #define CCSDS_TC_PKT_MIN_SIZE 16
10 #define CCSDS_TC_PKT_MIN_SIZE 16
11 #define CCSDS_PROCESS_ID 76
11 #define CCSDS_PROCESS_ID 76
12 #define CCSDS_PACKET_CATEGORY 12
12 #define CCSDS_PACKET_CATEGORY 12
13 #define CCSDS_NODE_ADDRESS 0xfe
13 #define CCSDS_NODE_ADDRESS 0xfe
14 #define CCSDS_USER_APP 0x00
14 #define CCSDS_USER_APP 0x00
15
15
16 #define DEFAULT_SPARE1_PUSVERSION_SPARE2 0x10
16 #define DEFAULT_SPARE1_PUSVERSION_SPARE2 0x10
17 #define DEFAULT_RESERVED 0x00
17 #define DEFAULT_RESERVED 0x00
18 #define DEFAULT_HKBIA 0x1e // 0001 1110
18 #define DEFAULT_HKBIA 0x1e // 0001 1110
19
19
20 // PACKET ID
20 // PACKET ID
21 #define TM_PACKET_PID_DEFAULT 76
21 #define TM_PACKET_PID_DEFAULT 76
22 #define TM_PACKET_PID_BURST_SBM1_SBM2 79
22 #define TM_PACKET_PID_BURST_SBM1_SBM2 79
23 #define APID_TM_TC_EXE 0x0cc1 // PID 76 CAT 1
23 #define APID_TM_TC_EXE 0x0cc1 // PID 76 CAT 1
24 #define APID_TM_HK 0x0cc4 // PID 76 CAT 4
24 #define APID_TM_HK 0x0cc4 // PID 76 CAT 4
25 #define APID_TM_SCIENCE_NORMAL_BURST 0x0ccc // PID 76 CAT 12
25 #define APID_TM_SCIENCE_NORMAL_BURST 0x0ccc // PID 76 CAT 12
26 #define APID_TM_SCIENCE_SBM1_SBM2 0x0cfc // PID 79 CAT 12
26 #define APID_TM_SCIENCE_SBM1_SBM2 0x0cfc // PID 79 CAT 12
27 #define APID_TM_PARAMETER_DUMP 0x0cc6 // PID 76 CAT 6
27 #define APID_TM_PARAMETER_DUMP 0x0cc6 // PID 76 CAT 6
28 #define APID_TM_KCOEFFICIENTS_DUMP 0x0cc6 // PID 76 CAT 6
28 #define APID_TM_KCOEFFICIENTS_DUMP 0x0cc6 // PID 76 CAT 6
29 // PACKET CAT
29 // PACKET CAT
30 #define TM_PACKET_CAT_TC_EXE 1
30 #define TM_PACKET_CAT_TC_EXE 1
31 #define TM_PACKET_CAT_HK 4
31 #define TM_PACKET_CAT_HK 4
32 #define TM_PACKET_CAT_SCIENCE 12
32 #define TM_PACKET_CAT_SCIENCE 12
33 #define TM_PACKET_CAT_DUMP 6
33 #define TM_PACKET_CAT_DUMP 6
34
34
35 // PACKET SEQUENCE CONTROL
35 // PACKET SEQUENCE CONTROL
36 #define TM_PACKET_SEQ_CTRL_CONTINUATION 0x00 // [0000 0000]
36 #define TM_PACKET_SEQ_CTRL_CONTINUATION 0x00 // [0000 0000]
37 #define TM_PACKET_SEQ_CTRL_FIRST 0x40 // [0100 0000]
37 #define TM_PACKET_SEQ_CTRL_FIRST 0x40 // [0100 0000]
38 #define TM_PACKET_SEQ_CTRL_LAST 0x80 // [1000 0000]
38 #define TM_PACKET_SEQ_CTRL_LAST 0x80 // [1000 0000]
39 #define TM_PACKET_SEQ_CTRL_STANDALONE 0xc0 // [1100 0000]
39 #define TM_PACKET_SEQ_CTRL_STANDALONE 0xc0 // [1100 0000]
40 #define TM_PACKET_SEQ_CNT_DEFAULT 0x00 // [0000 0000]
40 #define TM_PACKET_SEQ_CNT_DEFAULT 0x00 // [0000 0000]
41
41
42 // DESTINATION ID
42 // DESTINATION ID
43 #define TM_DESTINATION_ID_GROUND 0
43 #define TM_DESTINATION_ID_GROUND 0
44 #define TM_DESTINATION_ID_MISSION_TIMELINE 110
44 #define TM_DESTINATION_ID_MISSION_TIMELINE 110
45 #define TM_DESTINATION_ID_TC_SEQUENCES 111
45 #define TM_DESTINATION_ID_TC_SEQUENCES 111
46 #define TM_DESTINATION_ID_RECOVERY_ACTION_COMMAND 112
46 #define TM_DESTINATION_ID_RECOVERY_ACTION_COMMAND 112
47 #define TM_DESTINATION_ID_BACKUP_MISSION_TIMELINE 113
47 #define TM_DESTINATION_ID_BACKUP_MISSION_TIMELINE 113
48 #define TM_DESTINATION_ID_DIRECT_CMD 120
48 #define TM_DESTINATION_ID_DIRECT_CMD 120
49 #define TM_DESTINATION_ID_SPARE_GRD_SRC1 121
49 #define TM_DESTINATION_ID_SPARE_GRD_SRC1 121
50 #define TM_DESTINATION_ID_SPARE_GRD_SRC2 122
50 #define TM_DESTINATION_ID_SPARE_GRD_SRC2 122
51 #define TM_DESTINATION_ID_OBCP 15
51 #define TM_DESTINATION_ID_OBCP 15
52 #define TM_DESTINATION_ID_SYSTEM_CONTROL 14
52 #define TM_DESTINATION_ID_SYSTEM_CONTROL 14
53 #define TM_DESTINATION_ID_AOCS 11
53 #define TM_DESTINATION_ID_AOCS 11
54
54
55 //*********************************************************
55 //*********************************************************
56 //*** /!\ change CCSDS_DESTINATION_ID before flight /!\ ***
56 //*** /!\ change CCSDS_DESTINATION_ID before flight /!\ ***
57 //*********************************************************
57 //*********************************************************
58 #ifdef LPP_DPU_DESTID
58 #ifdef LPP_DPU_DESTID
59 #define CCSDS_DESTINATION_ID 32
59 #define CCSDS_DESTINATION_ID 32
60 #else
60 #else
61 #define CCSDS_DESTINATION_ID 0x01
61 #define CCSDS_DESTINATION_ID 0x01
62 #endif
62 #endif
63 #define CCSDS_PROTOCOLE_ID 0x02
63 #define CCSDS_PROTOCOLE_ID 0x02
64 #define CCSDS_RESERVED 0x00
64 #define CCSDS_RESERVED 0x00
65 #define CCSDS_USER_APP 0x00
65 #define CCSDS_USER_APP 0x00
66
66
67 #define SIZE_TM_LFR_TC_EXE_NOT_IMPLEMENTED 24
67 #define SIZE_TM_LFR_TC_EXE_NOT_IMPLEMENTED 24
68 #define SIZE_TM_LFR_TC_EXE_CORRUPTED 32
68 #define SIZE_TM_LFR_TC_EXE_CORRUPTED 32
69 #define SIZE_HK_PARAMETERS 112
69 #define SIZE_HK_PARAMETERS 112
70
70
71 // TC TYPES
71 // TC TYPES
72 #define TC_TYPE_GEN 181
72 #define TC_TYPE_GEN 181
73 #define TC_TYPE_TIME 9
73 #define TC_TYPE_TIME 9
74
74
75 // TC SUBTYPES
75 // TC SUBTYPES
76 #define TC_SUBTYPE_RESET 1
76 #define TC_SUBTYPE_RESET 1
77 #define TC_SUBTYPE_LOAD_COMM 11
77 #define TC_SUBTYPE_LOAD_COMM 11
78 #define TC_SUBTYPE_LOAD_NORM 13
78 #define TC_SUBTYPE_LOAD_NORM 13
79 #define TC_SUBTYPE_LOAD_BURST 19
79 #define TC_SUBTYPE_LOAD_BURST 19
80 #define TC_SUBTYPE_LOAD_SBM1 25
80 #define TC_SUBTYPE_LOAD_SBM1 25
81 #define TC_SUBTYPE_LOAD_SBM2 27
81 #define TC_SUBTYPE_LOAD_SBM2 27
82 #define TC_SUBTYPE_DUMP 31
82 #define TC_SUBTYPE_DUMP 31
83 #define TC_SUBTYPE_ENTER 41
83 #define TC_SUBTYPE_ENTER 41
84 #define TC_SUBTYPE_UPDT_INFO 51
84 #define TC_SUBTYPE_UPDT_INFO 51
85 #define TC_SUBTYPE_EN_CAL 61
85 #define TC_SUBTYPE_EN_CAL 61
86 #define TC_SUBTYPE_DIS_CAL 63
86 #define TC_SUBTYPE_DIS_CAL 63
87 #define TC_SUBTYPE_LOAD_K 93
87 #define TC_SUBTYPE_LOAD_K 93
88 #define TC_SUBTYPE_DUMP_K 95
88 #define TC_SUBTYPE_DUMP_K 95
89 #define TC_SUBTYPE_LOAD_FBINS 91
89 #define TC_SUBTYPE_LOAD_FBINS 91
90 #define TC_SUBTYPE_UPDT_TIME 129
90 #define TC_SUBTYPE_UPDT_TIME 129
91
91
92 // TC LEN
92 // TC LEN
93 #define TC_LEN_RESET 12
93 #define TC_LEN_RESET 12
94 #define TC_LEN_LOAD_COMM 14
94 #define TC_LEN_LOAD_COMM 14
95 #define TC_LEN_LOAD_NORM 22
95 #define TC_LEN_LOAD_NORM 22
96 #define TC_LEN_LOAD_BURST 14
96 #define TC_LEN_LOAD_BURST 14
97 #define TC_LEN_LOAD_SBM1 14
97 #define TC_LEN_LOAD_SBM1 14
98 #define TC_LEN_LOAD_SBM2 14
98 #define TC_LEN_LOAD_SBM2 14
99 #define TC_LEN_DUMP 12
99 #define TC_LEN_DUMP 12
100 #define TC_LEN_ENTER 20
100 #define TC_LEN_ENTER 20
101 #define TC_LEN_UPDT_INFO 110
101 #define TC_LEN_UPDT_INFO 110
102 #define TC_LEN_EN_CAL 12
102 #define TC_LEN_EN_CAL 12
103 #define TC_LEN_DIS_CAL 12
103 #define TC_LEN_DIS_CAL 12
104 #define TC_LEN_LOAD_K 142
104 #define TC_LEN_LOAD_K 142
105 #define TC_LEN_DUMP_K 12
105 #define TC_LEN_DUMP_K 12
106 #define TC_LEN_LOAD_FBINS 60
106 #define TC_LEN_LOAD_FBINS 60
107 #define TC_LEN_UPDT_TIME 18
107 #define TC_LEN_UPDT_TIME 18
108
108
109 // PACKET CODES
109 // PACKET CODES
110 #define TM_CODE_K_DUMP 0xb5600b00 // 181 (0xb5) ** 96 (0x60) ** 11 (0x0b) ** 0 (0x00)
110 #define TM_CODE_K_DUMP 0xb5600b00 // 181 (0xb5) ** 96 (0x60) ** 11 (0x0b) ** 0 (0x00)
111
111
112 // TM TYPES
112 // TM TYPES
113 #define TM_TYPE_TC_EXE 1
113 #define TM_TYPE_TC_EXE 1
114 #define TM_TYPE_HK 3
114 #define TM_TYPE_HK 3
115 #define TM_TYPE_LFR_SCIENCE 21
115 #define TM_TYPE_LFR_SCIENCE 21
116 #define TM_TYPE_PARAMETER_DUMP 181
116 #define TM_TYPE_PARAMETER_DUMP 181
117 #define TM_TYPE_K_DUMP 181
117 #define TM_TYPE_K_DUMP 181
118
118
119 // TM SUBTYPES
119 // TM SUBTYPES
120 #define TM_SUBTYPE_EXE_OK 7
120 #define TM_SUBTYPE_EXE_OK 7
121 #define TM_SUBTYPE_EXE_NOK 8
121 #define TM_SUBTYPE_EXE_NOK 8
122 #define TM_SUBTYPE_HK 25
122 #define TM_SUBTYPE_HK 25
123 #define TM_SUBTYPE_LFR_SCIENCE_3 3 // TM packets with fixed size
123 #define TM_SUBTYPE_LFR_SCIENCE_3 3 // TM packets with fixed size
124 #define TM_SUBTYPE_LFR_SCIENCE_6 6 // TM packets with variable size
124 #define TM_SUBTYPE_LFR_SCIENCE_6 6 // TM packets with variable size
125 #define TM_SUBTYPE_PARAMETER_DUMP 32
125 #define TM_SUBTYPE_PARAMETER_DUMP 32
126 #define TM_SUBTYPE_K_DUMP 96
126 #define TM_SUBTYPE_K_DUMP 96
127
127
128 // FAILURE CODES
128 // FAILURE CODES
129 #define ILLEGAL_APID 0
129 #define ILLEGAL_APID 0
130 #define WRONG_LEN_PKT 1
130 #define WRONG_LEN_PKT 1
131 #define INCOR_CHECKSUM 2
131 #define INCOR_CHECKSUM 2
132 #define ILL_TYPE 3
132 #define ILL_TYPE 3
133 #define ILL_SUBTYPE 4
133 #define ILL_SUBTYPE 4
134 #define WRONG_APP_DATA 5 // 0x00 0x05
134 #define WRONG_APP_DATA 5 // 0x00 0x05
135 #define TC_NOT_EXE 42000 // 0xa4 0x10
135 #define TC_NOT_EXE 42000 // 0xa4 0x10
136 #define WRONG_SRC_ID 42001 // 0xa4 0x11
136 #define WRONG_SRC_ID 42001 // 0xa4 0x11
137 #define FUNCT_NOT_IMPL 42002 // 0xa4 0x12
137 #define FUNCT_NOT_IMPL 42002 // 0xa4 0x12
138 #define FAIL_DETECTED 42003 // 0xa4 0x13
138 #define FAIL_DETECTED 42003 // 0xa4 0x13
139 #define NOT_ALLOWED 42004 // 0xa4 0x14
139 #define NOT_ALLOWED 42004 // 0xa4 0x14
140 #define CORRUPTED 42005 // 0xa4 0x15
140 #define CORRUPTED 42005 // 0xa4 0x15
141 #define CCSDS_TM_VALID 7
141 #define CCSDS_TM_VALID 7
142
142
143 // HK_LFR_LAST_ER_RID
143 // HK_LFR_LAST_ER_RID
144 #define RID_LE_LFR_TIME 42119
144 #define RID_LE_LFR_TIME 42119
145 #define RID_LE_LFR_DPU_SPW 42128
145 #define RID_LE_LFR_DPU_SPW 42128
146 #define RID_LE_LFR_TIMEC 42129
146 #define RID_LE_LFR_TIMEC 42129
147 #define RID_ME_LFR_DPU_SPW 42338
147 #define RID_ME_LFR_DPU_SPW 42338
148 #define RID_ME_LFR_BUFFER 42339
149 // HK_LFR_LAST_ER_CODE
148 // HK_LFR_LAST_ER_CODE
150 #define CODE_PARITY 1
149 #define CODE_PARITY 1
151 #define CODE_DISCONNECT 2
150 #define CODE_DISCONNECT 2
152 #define CODE_ESCAPE 3
151 #define CODE_ESCAPE 3
153 #define CODE_CREDIT 4
152 #define CODE_CREDIT 4
154 #define CODE_WRITE_SYNC 5
153 #define CODE_WRITE_SYNC 5
155 #define CODE_EARLY_EOP_EEP 6
154 #define CODE_EARLY_EOP_EEP 6
156 #define CODE_INVALID_ADDRESS 7
155 #define CODE_INVALID_ADDRESS 7
157 #define CODE_EEP 8
156 #define CODE_EEP 8
158 #define CODE_RX_TOO_BIG 9
157 #define CODE_RX_TOO_BIG 9
159 #define CODE_HEADER_CRC 16
158 #define CODE_HEADER_CRC 16
160 #define CODE_DATA_CRC 17
159 #define CODE_DATA_CRC 17
161 #define CODE_ERRONEOUS 20
160 #define CODE_ERRONEOUS 20
162 #define CODE_MISSING 21
161 #define CODE_MISSING 21
163 #define CODE_INVALID 22
162 #define CODE_INVALID 22
164 #define CODE_TIMECODE_IT 24
163 #define CODE_TIMECODE_IT 24
165 #define CODE_NOT_SYNCHRO 25
164 #define CODE_NOT_SYNCHRO 25
166 #define CODE_TIMECODE_CTR 26
165 #define CODE_TIMECODE_CTR 26
167
166
168 // TC SID
167 // TC SID
169 #define SID_TC_GROUND 0
168 #define SID_TC_GROUND 0
170 #define SID_TC_MISSION_TIMELINE 110
169 #define SID_TC_MISSION_TIMELINE 110
171 #define SID_TC_TC_SEQUENCES 111
170 #define SID_TC_TC_SEQUENCES 111
172 #define SID_TC_RECOVERY_ACTION_CMD 112
171 #define SID_TC_RECOVERY_ACTION_CMD 112
173 #define SID_TC_BACKUP_MISSION_TIMELINE 113
172 #define SID_TC_BACKUP_MISSION_TIMELINE 113
174 #define SID_TC_DIRECT_CMD 120
173 #define SID_TC_DIRECT_CMD 120
175 #define SID_TC_SPARE_GRD_SRC1 121
174 #define SID_TC_SPARE_GRD_SRC1 121
176 #define SID_TC_SPARE_GRD_SRC2 122
175 #define SID_TC_SPARE_GRD_SRC2 122
177 #define SID_TC_OBCP 15
176 #define SID_TC_OBCP 15
178 #define SID_TC_SYSTEM_CONTROL 14
177 #define SID_TC_SYSTEM_CONTROL 14
179 #define SID_TC_AOCS 11
178 #define SID_TC_AOCS 11
180 #define SID_TC_RPW_INTERNAL 254
179 #define SID_TC_RPW_INTERNAL 254
181
180
182 enum apid_destid{
181 enum apid_destid{
183 GROUND,
182 GROUND,
184 MISSION_TIMELINE,
183 MISSION_TIMELINE,
185 TC_SEQUENCES,
184 TC_SEQUENCES,
186 RECOVERY_ACTION_CMD,
185 RECOVERY_ACTION_CMD,
187 BACKUP_MISSION_TIMELINE,
186 BACKUP_MISSION_TIMELINE,
188 DIRECT_CMD,
187 DIRECT_CMD,
189 SPARE_GRD_SRC1,
188 SPARE_GRD_SRC1,
190 SPARE_GRD_SRC2,
189 SPARE_GRD_SRC2,
191 OBCP,
190 OBCP,
192 SYSTEM_CONTROL,
191 SYSTEM_CONTROL,
193 AOCS,
192 AOCS,
194 RPW_INTERNAL
193 RPW_INTERNAL
195 };
194 };
196 // SEQUENCE COUNTERS
195 // SEQUENCE COUNTERS
197 #define SEQ_CNT_MAX 16383
196 #define SEQ_CNT_MAX 16383
198 #define SEQ_CNT_NB_DEST_ID 12
197 #define SEQ_CNT_NB_DEST_ID 12
199
198
200 // TM SID
199 // TM SID
201 #define SID_HK 1
200 #define SID_HK 1
202
201
203 #define SID_NORM_SWF_F0 3
202 #define SID_NORM_SWF_F0 3
204 #define SID_NORM_SWF_F1 4
203 #define SID_NORM_SWF_F1 4
205 #define SID_NORM_SWF_F2 5
204 #define SID_NORM_SWF_F2 5
206 #define SID_NORM_CWF_F3 1
205 #define SID_NORM_CWF_F3 1
207 #define SID_BURST_CWF_F2 2
206 #define SID_BURST_CWF_F2 2
208 #define SID_SBM1_CWF_F1 24
207 #define SID_SBM1_CWF_F1 24
209 #define SID_SBM2_CWF_F2 25
208 #define SID_SBM2_CWF_F2 25
210 #define SID_NORM_ASM_F0 11
209 #define SID_NORM_ASM_F0 11
211 #define SID_NORM_ASM_F1 12
210 #define SID_NORM_ASM_F1 12
212 #define SID_NORM_ASM_F2 13
211 #define SID_NORM_ASM_F2 13
213 #define SID_NORM_BP1_F0 14
212 #define SID_NORM_BP1_F0 14
214 #define SID_NORM_BP1_F1 15
213 #define SID_NORM_BP1_F1 15
215 #define SID_NORM_BP1_F2 16
214 #define SID_NORM_BP1_F2 16
216 #define SID_NORM_BP2_F0 19
215 #define SID_NORM_BP2_F0 19
217 #define SID_NORM_BP2_F1 20
216 #define SID_NORM_BP2_F1 20
218 #define SID_NORM_BP2_F2 21
217 #define SID_NORM_BP2_F2 21
219 #define SID_BURST_BP1_F0 17
218 #define SID_BURST_BP1_F0 17
220 #define SID_BURST_BP2_F0 22
219 #define SID_BURST_BP2_F0 22
221 #define SID_BURST_BP1_F1 18
220 #define SID_BURST_BP1_F1 18
222 #define SID_BURST_BP2_F1 23
221 #define SID_BURST_BP2_F1 23
223 #define SID_SBM1_BP1_F0 28
222 #define SID_SBM1_BP1_F0 28
224 #define SID_SBM1_BP2_F0 31
223 #define SID_SBM1_BP2_F0 31
225 #define SID_SBM2_BP1_F0 29
224 #define SID_SBM2_BP1_F0 29
226 #define SID_SBM2_BP2_F0 32
225 #define SID_SBM2_BP2_F0 32
227 #define SID_SBM2_BP1_F1 30
226 #define SID_SBM2_BP1_F1 30
228 #define SID_SBM2_BP2_F1 33
227 #define SID_SBM2_BP2_F1 33
229 #define SID_NORM_CWF_LONG_F3 34
228 #define SID_NORM_CWF_LONG_F3 34
230
229
231 #define SID_PARAMETER_DUMP 10
230 #define SID_PARAMETER_DUMP 10
232 #define SID_K_DUMP 11
231 #define SID_K_DUMP 11
233
232
234 // HEADER_LENGTH
233 // HEADER_LENGTH
235 //#define TM_HEADER_LEN 16
234 //#define TM_HEADER_LEN 16
236 #define HEADER_LENGTH_TM_LFR_SCIENCE_CWF 32
235 #define HEADER_LENGTH_TM_LFR_SCIENCE_CWF 32
237 #define HEADER_LENGTH_TM_LFR_SCIENCE_SWF 34
236 #define HEADER_LENGTH_TM_LFR_SCIENCE_SWF 34
238 #define HEADER_LENGTH_TM_LFR_SCIENCE_ASM 34
237 #define HEADER_LENGTH_TM_LFR_SCIENCE_ASM 34
239 // PACKET_LENGTH
238 // PACKET_LENGTH
240 #define PACKET_LENGTH_TC_EXE_SUCCESS (20 - CCSDS_TC_TM_PACKET_OFFSET)
239 #define PACKET_LENGTH_TC_EXE_SUCCESS (20 - CCSDS_TC_TM_PACKET_OFFSET)
241 #define PACKET_LENGTH_TC_EXE_INCONSISTENT (26 - CCSDS_TC_TM_PACKET_OFFSET)
240 #define PACKET_LENGTH_TC_EXE_INCONSISTENT (26 - CCSDS_TC_TM_PACKET_OFFSET)
242 #define PACKET_LENGTH_TC_EXE_NOT_EXECUTABLE (26 - CCSDS_TC_TM_PACKET_OFFSET)
241 #define PACKET_LENGTH_TC_EXE_NOT_EXECUTABLE (26 - CCSDS_TC_TM_PACKET_OFFSET)
243 #define PACKET_LENGTH_TC_EXE_NOT_IMPLEMENTED (24 - CCSDS_TC_TM_PACKET_OFFSET)
242 #define PACKET_LENGTH_TC_EXE_NOT_IMPLEMENTED (24 - CCSDS_TC_TM_PACKET_OFFSET)
244 #define PACKET_LENGTH_TC_EXE_ERROR (24 - CCSDS_TC_TM_PACKET_OFFSET)
243 #define PACKET_LENGTH_TC_EXE_ERROR (24 - CCSDS_TC_TM_PACKET_OFFSET)
245 #define PACKET_LENGTH_TC_EXE_CORRUPTED (32 - CCSDS_TC_TM_PACKET_OFFSET)
244 #define PACKET_LENGTH_TC_EXE_CORRUPTED (32 - CCSDS_TC_TM_PACKET_OFFSET)
246 #define PACKET_LENGTH_HK (136 - CCSDS_TC_TM_PACKET_OFFSET)
245 #define PACKET_LENGTH_HK (136 - CCSDS_TC_TM_PACKET_OFFSET)
247 #define PACKET_LENGTH_PARAMETER_DUMP (84 - CCSDS_TC_TM_PACKET_OFFSET)
246 #define PACKET_LENGTH_PARAMETER_DUMP (84 - CCSDS_TC_TM_PACKET_OFFSET)
248 #define PACKET_LENGTH_K_DUMP (3920 - CCSDS_TC_TM_PACKET_OFFSET)
247 #define PACKET_LENGTH_K_DUMP (3920 - CCSDS_TC_TM_PACKET_OFFSET)
249 // SCIENCE ASM
248 // SCIENCE ASM
250 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F0_1 (3230 - CCSDS_TC_TM_PACKET_OFFSET) // 32 * 25 * 4 + 30 => 32 bins (32 + 32 + 24 ), 3 packets
249 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F0_1 (3230 - CCSDS_TC_TM_PACKET_OFFSET) // 32 * 25 * 4 + 30 => 32 bins (32 + 32 + 24 ), 3 packets
251 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F0_2 (2430 - CCSDS_TC_TM_PACKET_OFFSET) // 24 * 25 * 4 + 30 => 24 bins (32 + 32 + 24 ), 3 packets
250 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F0_2 (2430 - CCSDS_TC_TM_PACKET_OFFSET) // 24 * 25 * 4 + 30 => 24 bins (32 + 32 + 24 ), 3 packets
252 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F1_1 (3630 - CCSDS_TC_TM_PACKET_OFFSET) // 36 * 25 * 4 + 30 => 36 bins (36 + 36 + 32 ), 3 packets
251 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F1_1 (3630 - CCSDS_TC_TM_PACKET_OFFSET) // 36 * 25 * 4 + 30 => 36 bins (36 + 36 + 32 ), 3 packets
253 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F1_2 (3230 - CCSDS_TC_TM_PACKET_OFFSET) // 32 * 25 * 4 + 30 => 32 bins (36 + 36 + 32 ), 3 packets
252 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F1_2 (3230 - CCSDS_TC_TM_PACKET_OFFSET) // 32 * 25 * 4 + 30 => 32 bins (36 + 36 + 32 ), 3 packets
254 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F2 (3230 - CCSDS_TC_TM_PACKET_OFFSET) // 32 * 25 * 4 + 30 => 96 bins (32 + 32 + 32 ), 3 packets
253 #define PACKET_LENGTH_TM_LFR_SCIENCE_ASM_F2 (3230 - CCSDS_TC_TM_PACKET_OFFSET) // 32 * 25 * 4 + 30 => 96 bins (32 + 32 + 32 ), 3 packets
255 // SCIENCE NORM
254 // SCIENCE NORM
256 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F0 (150 - CCSDS_TC_TM_PACKET_OFFSET) // 11 * 11 + 29 (1 spare byte in the header)
255 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F0 (150 - CCSDS_TC_TM_PACKET_OFFSET) // 11 * 11 + 29 (1 spare byte in the header)
257 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F1 (172 - CCSDS_TC_TM_PACKET_OFFSET) // 13 * 11 + 29 (1 spare byte in the header)
256 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F1 (172 - CCSDS_TC_TM_PACKET_OFFSET) // 13 * 11 + 29 (1 spare byte in the header)
258 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F2 (160 - CCSDS_TC_TM_PACKET_OFFSET) // 12 * 11 + 28
257 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP1_F2 (160 - CCSDS_TC_TM_PACKET_OFFSET) // 12 * 11 + 28
259 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F0 (358 - CCSDS_TC_TM_PACKET_OFFSET) // 11 * 30 + 28
258 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F0 (358 - CCSDS_TC_TM_PACKET_OFFSET) // 11 * 30 + 28
260 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F1 (418 - CCSDS_TC_TM_PACKET_OFFSET) // 13 * 30 + 28
259 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F1 (418 - CCSDS_TC_TM_PACKET_OFFSET) // 13 * 30 + 28
261 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F2 (388 - CCSDS_TC_TM_PACKET_OFFSET) // 12 * 30 + 28
260 #define PACKET_LENGTH_TM_LFR_SCIENCE_NORM_BP2_F2 (388 - CCSDS_TC_TM_PACKET_OFFSET) // 12 * 30 + 28
262 // SCIENCE SBM
261 // SCIENCE SBM
263 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP1_F0 (270 - CCSDS_TC_TM_PACKET_OFFSET) // 22 * 11 + 28
262 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP1_F0 (270 - CCSDS_TC_TM_PACKET_OFFSET) // 22 * 11 + 28
264 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP2_F0 (688 - CCSDS_TC_TM_PACKET_OFFSET) // 22 * 30 + 28
263 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP2_F0 (688 - CCSDS_TC_TM_PACKET_OFFSET) // 22 * 30 + 28
265 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP1_F1 (314 - CCSDS_TC_TM_PACKET_OFFSET) // 26 * 11 + 28
264 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP1_F1 (314 - CCSDS_TC_TM_PACKET_OFFSET) // 26 * 11 + 28
266 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP2_F1 (808 - CCSDS_TC_TM_PACKET_OFFSET) // 26 * 30 + 28
265 #define PACKET_LENGTH_TM_LFR_SCIENCE_SBM_BP2_F1 (808 - CCSDS_TC_TM_PACKET_OFFSET) // 26 * 30 + 28
267
266
268 #define PACKET_LENGTH_DELTA 11 // 7 + 4
267 #define PACKET_LENGTH_DELTA 11 // 7 + 4
269
268
270 #define SPARE1_PUSVERSION_SPARE2 0x10
269 #define SPARE1_PUSVERSION_SPARE2 0x10
271
270
272 // R3
271 // R3
273 // one snapshot = 2048 samples = 6 packets * 304 + 224
272 // one snapshot = 2048 samples = 6 packets * 304 + 224
274 #define TM_LEN_SCI_SWF_304 (3678 - CCSDS_TC_TM_PACKET_OFFSET) // 304 * 12 + 30
273 #define TM_LEN_SCI_SWF_304 (3678 - CCSDS_TC_TM_PACKET_OFFSET) // 304 * 12 + 30
275 #define TM_LEN_SCI_SWF_224 (2718 - CCSDS_TC_TM_PACKET_OFFSET) // 224 * 12 + 30
274 #define TM_LEN_SCI_SWF_224 (2718 - CCSDS_TC_TM_PACKET_OFFSET) // 224 * 12 + 30
276 // one continuous buffer = 2688 samples = 8 packets * 336
275 // one continuous buffer = 2688 samples = 8 packets * 336
277 #define TM_LEN_SCI_CWF_336 (4060 - CCSDS_TC_TM_PACKET_OFFSET) // 336 * 12 + 28
276 #define TM_LEN_SCI_CWF_336 (4060 - CCSDS_TC_TM_PACKET_OFFSET) // 336 * 12 + 28
278 #define TM_LEN_SCI_CWF_672 (4060 - CCSDS_TC_TM_PACKET_OFFSET) // 672 * 6 + 28
277 #define TM_LEN_SCI_CWF_672 (4060 - CCSDS_TC_TM_PACKET_OFFSET) // 672 * 6 + 28
279 //
278 //
280 #define DEFAULT_PKTCNT 0x07
279 #define DEFAULT_PKTCNT 0x07
281 #define BLK_NR_304 0x0130
280 #define BLK_NR_304 0x0130
282 #define BLK_NR_224 0x00e0
281 #define BLK_NR_224 0x00e0
283 #define BLK_NR_CWF 0x0150 // 336
282 #define BLK_NR_CWF 0x0150 // 336
284 #define BLK_NR_CWF_SHORT_F3 0x02a0 // 672
283 #define BLK_NR_CWF_SHORT_F3 0x02a0 // 672
285
284
286 enum TM_TYPE{
285 enum TM_TYPE{
287 TM_LFR_TC_EXE_OK,
286 TM_LFR_TC_EXE_OK,
288 TM_LFR_TC_EXE_ERR,
287 TM_LFR_TC_EXE_ERR,
289 TM_LFR_HK,
288 TM_LFR_HK,
290 TM_LFR_SCI,
289 TM_LFR_SCI,
291 TM_LFR_SCI_SBM,
290 TM_LFR_SCI_SBM,
292 TM_LFR_PAR_DUMP
291 TM_LFR_PAR_DUMP
293 };
292 };
294
293
295 typedef struct {
294 typedef struct {
296 unsigned char targetLogicalAddress;
295 unsigned char targetLogicalAddress;
297 unsigned char protocolIdentifier;
296 unsigned char protocolIdentifier;
298 unsigned char reserved;
297 unsigned char reserved;
299 unsigned char userApplication;
298 unsigned char userApplication;
300 // PACKET HEADER
299 // PACKET HEADER
301 unsigned char packetID[2];
300 unsigned char packetID[2];
302 unsigned char packetSequenceControl[2];
301 unsigned char packetSequenceControl[2];
303 unsigned char packetLength[2];
302 unsigned char packetLength[2];
304 // DATA FIELD HEADER
303 // DATA FIELD HEADER
305 unsigned char spare1_pusVersion_spare2;
304 unsigned char spare1_pusVersion_spare2;
306 unsigned char serviceType;
305 unsigned char serviceType;
307 unsigned char serviceSubType;
306 unsigned char serviceSubType;
308 unsigned char destinationID;
307 unsigned char destinationID;
309 unsigned char time[6];
308 unsigned char time[6];
310 //
309 //
311 unsigned char telecommand_pkt_id[2];
310 unsigned char telecommand_pkt_id[2];
312 unsigned char pkt_seq_control[2];
311 unsigned char pkt_seq_control[2];
313 } Packet_TM_LFR_TC_EXE_SUCCESS_t;
312 } Packet_TM_LFR_TC_EXE_SUCCESS_t;
314
313
315 typedef struct {
314 typedef struct {
316 unsigned char targetLogicalAddress;
315 unsigned char targetLogicalAddress;
317 unsigned char protocolIdentifier;
316 unsigned char protocolIdentifier;
318 unsigned char reserved;
317 unsigned char reserved;
319 unsigned char userApplication;
318 unsigned char userApplication;
320 // PACKET HEADER
319 // PACKET HEADER
321 unsigned char packetID[2];
320 unsigned char packetID[2];
322 unsigned char packetSequenceControl[2];
321 unsigned char packetSequenceControl[2];
323 unsigned char packetLength[2];
322 unsigned char packetLength[2];
324 // DATA FIELD HEADER
323 // DATA FIELD HEADER
325 unsigned char spare1_pusVersion_spare2;
324 unsigned char spare1_pusVersion_spare2;
326 unsigned char serviceType;
325 unsigned char serviceType;
327 unsigned char serviceSubType;
326 unsigned char serviceSubType;
328 unsigned char destinationID;
327 unsigned char destinationID;
329 unsigned char time[6];
328 unsigned char time[6];
330 //
329 //
331 unsigned char telecommand_pkt_id[2];
330 unsigned char telecommand_pkt_id[2];
332 unsigned char pkt_seq_control[2];
331 unsigned char pkt_seq_control[2];
333 unsigned char tc_failure_code[2];
332 unsigned char tc_failure_code[2];
334 unsigned char tc_service;
333 unsigned char tc_service;
335 unsigned char tc_subtype;
334 unsigned char tc_subtype;
336 unsigned char byte_position;
335 unsigned char byte_position;
337 unsigned char rcv_value;
336 unsigned char rcv_value;
338 } Packet_TM_LFR_TC_EXE_INCONSISTENT_t;
337 } Packet_TM_LFR_TC_EXE_INCONSISTENT_t;
339
338
340 typedef struct {
339 typedef struct {
341 unsigned char targetLogicalAddress;
340 unsigned char targetLogicalAddress;
342 unsigned char protocolIdentifier;
341 unsigned char protocolIdentifier;
343 unsigned char reserved;
342 unsigned char reserved;
344 unsigned char userApplication;
343 unsigned char userApplication;
345 // PACKET HEADER
344 // PACKET HEADER
346 unsigned char packetID[2];
345 unsigned char packetID[2];
347 unsigned char packetSequenceControl[2];
346 unsigned char packetSequenceControl[2];
348 unsigned char packetLength[2];
347 unsigned char packetLength[2];
349 // DATA FIELD HEADER
348 // DATA FIELD HEADER
350 unsigned char spare1_pusVersion_spare2;
349 unsigned char spare1_pusVersion_spare2;
351 unsigned char serviceType;
350 unsigned char serviceType;
352 unsigned char serviceSubType;
351 unsigned char serviceSubType;
353 unsigned char destinationID;
352 unsigned char destinationID;
354 unsigned char time[6];
353 unsigned char time[6];
355 //
354 //
356 unsigned char telecommand_pkt_id[2];
355 unsigned char telecommand_pkt_id[2];
357 unsigned char pkt_seq_control[2];
356 unsigned char pkt_seq_control[2];
358 unsigned char tc_failure_code[2];
357 unsigned char tc_failure_code[2];
359 unsigned char tc_service;
358 unsigned char tc_service;
360 unsigned char tc_subtype;
359 unsigned char tc_subtype;
361 unsigned char lfr_status_word[2];
360 unsigned char lfr_status_word[2];
362 } Packet_TM_LFR_TC_EXE_NOT_EXECUTABLE_t;
361 } Packet_TM_LFR_TC_EXE_NOT_EXECUTABLE_t;
363
362
364 typedef struct {
363 typedef struct {
365 unsigned char targetLogicalAddress;
364 unsigned char targetLogicalAddress;
366 unsigned char protocolIdentifier;
365 unsigned char protocolIdentifier;
367 unsigned char reserved;
366 unsigned char reserved;
368 unsigned char userApplication;
367 unsigned char userApplication;
369 // PACKET HEADER
368 // PACKET HEADER
370 unsigned char packetID[2];
369 unsigned char packetID[2];
371 unsigned char packetSequenceControl[2];
370 unsigned char packetSequenceControl[2];
372 unsigned char packetLength[2];
371 unsigned char packetLength[2];
373 // DATA FIELD HEADER
372 // DATA FIELD HEADER
374 unsigned char spare1_pusVersion_spare2;
373 unsigned char spare1_pusVersion_spare2;
375 unsigned char serviceType;
374 unsigned char serviceType;
376 unsigned char serviceSubType;
375 unsigned char serviceSubType;
377 unsigned char destinationID;
376 unsigned char destinationID;
378 unsigned char time[6];
377 unsigned char time[6];
379 //
378 //
380 unsigned char telecommand_pkt_id[2];
379 unsigned char telecommand_pkt_id[2];
381 unsigned char pkt_seq_control[2];
380 unsigned char pkt_seq_control[2];
382 unsigned char tc_failure_code[2];
381 unsigned char tc_failure_code[2];
383 unsigned char tc_service;
382 unsigned char tc_service;
384 unsigned char tc_subtype;
383 unsigned char tc_subtype;
385 } Packet_TM_LFR_TC_EXE_NOT_IMPLEMENTED_t;
384 } Packet_TM_LFR_TC_EXE_NOT_IMPLEMENTED_t;
386
385
387 typedef struct {
386 typedef struct {
388 unsigned char targetLogicalAddress;
387 unsigned char targetLogicalAddress;
389 unsigned char protocolIdentifier;
388 unsigned char protocolIdentifier;
390 unsigned char reserved;
389 unsigned char reserved;
391 unsigned char userApplication;
390 unsigned char userApplication;
392 // PACKET HEADER
391 // PACKET HEADER
393 unsigned char packetID[2];
392 unsigned char packetID[2];
394 unsigned char packetSequenceControl[2];
393 unsigned char packetSequenceControl[2];
395 unsigned char packetLength[2];
394 unsigned char packetLength[2];
396 // DATA FIELD HEADER
395 // DATA FIELD HEADER
397 unsigned char spare1_pusVersion_spare2;
396 unsigned char spare1_pusVersion_spare2;
398 unsigned char serviceType;
397 unsigned char serviceType;
399 unsigned char serviceSubType;
398 unsigned char serviceSubType;
400 unsigned char destinationID;
399 unsigned char destinationID;
401 unsigned char time[6];
400 unsigned char time[6];
402 //
401 //
403 unsigned char telecommand_pkt_id[2];
402 unsigned char telecommand_pkt_id[2];
404 unsigned char pkt_seq_control[2];
403 unsigned char pkt_seq_control[2];
405 unsigned char tc_failure_code[2];
404 unsigned char tc_failure_code[2];
406 unsigned char tc_service;
405 unsigned char tc_service;
407 unsigned char tc_subtype;
406 unsigned char tc_subtype;
408 } Packet_TM_LFR_TC_EXE_ERROR_t;
407 } Packet_TM_LFR_TC_EXE_ERROR_t;
409
408
410 typedef struct {
409 typedef struct {
411 unsigned char targetLogicalAddress;
410 unsigned char targetLogicalAddress;
412 unsigned char protocolIdentifier;
411 unsigned char protocolIdentifier;
413 unsigned char reserved;
412 unsigned char reserved;
414 unsigned char userApplication;
413 unsigned char userApplication;
415 // PACKET HEADER
414 // PACKET HEADER
416 unsigned char packetID[2];
415 unsigned char packetID[2];
417 unsigned char packetSequenceControl[2];
416 unsigned char packetSequenceControl[2];
418 unsigned char packetLength[2];
417 unsigned char packetLength[2];
419 // DATA FIELD HEADER
418 // DATA FIELD HEADER
420 unsigned char spare1_pusVersion_spare2;
419 unsigned char spare1_pusVersion_spare2;
421 unsigned char serviceType;
420 unsigned char serviceType;
422 unsigned char serviceSubType;
421 unsigned char serviceSubType;
423 unsigned char destinationID;
422 unsigned char destinationID;
424 unsigned char time[6];
423 unsigned char time[6];
425 //
424 //
426 unsigned char telecommand_pkt_id[2];
425 unsigned char telecommand_pkt_id[2];
427 unsigned char pkt_seq_control[2];
426 unsigned char pkt_seq_control[2];
428 unsigned char tc_failure_code[2];
427 unsigned char tc_failure_code[2];
429 unsigned char tc_service;
428 unsigned char tc_service;
430 unsigned char tc_subtype;
429 unsigned char tc_subtype;
431 unsigned char pkt_len_rcv_value[2];
430 unsigned char pkt_len_rcv_value[2];
432 unsigned char pkt_datafieldsize_cnt[2];
431 unsigned char pkt_datafieldsize_cnt[2];
433 unsigned char rcv_crc[2];
432 unsigned char rcv_crc[2];
434 unsigned char computed_crc[2];
433 unsigned char computed_crc[2];
435 } Packet_TM_LFR_TC_EXE_CORRUPTED_t;
434 } Packet_TM_LFR_TC_EXE_CORRUPTED_t;
436
435
437 typedef struct {
436 typedef struct {
438 unsigned char targetLogicalAddress;
437 unsigned char targetLogicalAddress;
439 unsigned char protocolIdentifier;
438 unsigned char protocolIdentifier;
440 unsigned char reserved;
439 unsigned char reserved;
441 unsigned char userApplication;
440 unsigned char userApplication;
442 unsigned char packetID[2];
441 unsigned char packetID[2];
443 unsigned char packetSequenceControl[2];
442 unsigned char packetSequenceControl[2];
444 unsigned char packetLength[2];
443 unsigned char packetLength[2];
445 // DATA FIELD HEADER
444 // DATA FIELD HEADER
446 unsigned char spare1_pusVersion_spare2;
445 unsigned char spare1_pusVersion_spare2;
447 unsigned char serviceType;
446 unsigned char serviceType;
448 unsigned char serviceSubType;
447 unsigned char serviceSubType;
449 unsigned char destinationID;
448 unsigned char destinationID;
450 unsigned char time[6];
449 unsigned char time[6];
451 // AUXILIARY HEADER
450 // AUXILIARY HEADER
452 unsigned char sid;
451 unsigned char sid;
453 unsigned char hkBIA;
452 unsigned char hkBIA;
454 unsigned char sy_lfr_common_parameters_spare;
453 unsigned char sy_lfr_common_parameters_spare;
455 unsigned char sy_lfr_common_parameters;
454 unsigned char sy_lfr_common_parameters;
456 unsigned char pktCnt;
455 unsigned char pktCnt;
457 unsigned char pktNr;
456 unsigned char pktNr;
458 unsigned char acquisitionTime[6];
457 unsigned char acquisitionTime[6];
459 unsigned char blkNr[2];
458 unsigned char blkNr[2];
460 } Header_TM_LFR_SCIENCE_SWF_t;
459 } Header_TM_LFR_SCIENCE_SWF_t;
461
460
462 typedef struct {
461 typedef struct {
463 unsigned char targetLogicalAddress;
462 unsigned char targetLogicalAddress;
464 unsigned char protocolIdentifier;
463 unsigned char protocolIdentifier;
465 unsigned char reserved;
464 unsigned char reserved;
466 unsigned char userApplication;
465 unsigned char userApplication;
467 unsigned char packetID[2];
466 unsigned char packetID[2];
468 unsigned char packetSequenceControl[2];
467 unsigned char packetSequenceControl[2];
469 unsigned char packetLength[2];
468 unsigned char packetLength[2];
470 // DATA FIELD HEADER
469 // DATA FIELD HEADER
471 unsigned char spare1_pusVersion_spare2;
470 unsigned char spare1_pusVersion_spare2;
472 unsigned char serviceType;
471 unsigned char serviceType;
473 unsigned char serviceSubType;
472 unsigned char serviceSubType;
474 unsigned char destinationID;
473 unsigned char destinationID;
475 unsigned char time[6];
474 unsigned char time[6];
476 // AUXILIARY DATA HEADER
475 // AUXILIARY DATA HEADER
477 unsigned char sid;
476 unsigned char sid;
478 unsigned char hkBIA;
477 unsigned char hkBIA;
479 unsigned char sy_lfr_common_parameters_spare;
478 unsigned char sy_lfr_common_parameters_spare;
480 unsigned char sy_lfr_common_parameters;
479 unsigned char sy_lfr_common_parameters;
481 unsigned char acquisitionTime[6];
480 unsigned char acquisitionTime[6];
482 unsigned char blkNr[2];
481 unsigned char blkNr[2];
483 } Header_TM_LFR_SCIENCE_CWF_t;
482 } Header_TM_LFR_SCIENCE_CWF_t;
484
483
485 typedef struct {
484 typedef struct {
486 unsigned char targetLogicalAddress;
485 unsigned char targetLogicalAddress;
487 unsigned char protocolIdentifier;
486 unsigned char protocolIdentifier;
488 unsigned char reserved;
487 unsigned char reserved;
489 unsigned char userApplication;
488 unsigned char userApplication;
490 unsigned char packetID[2];
489 unsigned char packetID[2];
491 unsigned char packetSequenceControl[2];
490 unsigned char packetSequenceControl[2];
492 unsigned char packetLength[2];
491 unsigned char packetLength[2];
493 // DATA FIELD HEADER
492 // DATA FIELD HEADER
494 unsigned char spare1_pusVersion_spare2;
493 unsigned char spare1_pusVersion_spare2;
495 unsigned char serviceType;
494 unsigned char serviceType;
496 unsigned char serviceSubType;
495 unsigned char serviceSubType;
497 unsigned char destinationID;
496 unsigned char destinationID;
498 unsigned char time[6];
497 unsigned char time[6];
499 // AUXILIARY HEADER
498 // AUXILIARY HEADER
500 unsigned char sid;
499 unsigned char sid;
501 unsigned char biaStatusInfo;
500 unsigned char biaStatusInfo;
502 unsigned char sy_lfr_common_parameters_spare;
501 unsigned char sy_lfr_common_parameters_spare;
503 unsigned char sy_lfr_common_parameters;
502 unsigned char sy_lfr_common_parameters;
504 unsigned char pa_lfr_pkt_cnt_asm;
503 unsigned char pa_lfr_pkt_cnt_asm;
505 unsigned char pa_lfr_pkt_nr_asm;
504 unsigned char pa_lfr_pkt_nr_asm;
506 unsigned char acquisitionTime[6];
505 unsigned char acquisitionTime[6];
507 unsigned char pa_lfr_asm_blk_nr[2];
506 unsigned char pa_lfr_asm_blk_nr[2];
508 } Header_TM_LFR_SCIENCE_ASM_t;
507 } Header_TM_LFR_SCIENCE_ASM_t;
509
508
510 typedef struct {
509 typedef struct {
511 unsigned char targetLogicalAddress;
510 unsigned char targetLogicalAddress;
512 unsigned char protocolIdentifier;
511 unsigned char protocolIdentifier;
513 unsigned char reserved;
512 unsigned char reserved;
514 unsigned char userApplication;
513 unsigned char userApplication;
515 unsigned char packetID[2];
514 unsigned char packetID[2];
516 unsigned char packetSequenceControl[2];
515 unsigned char packetSequenceControl[2];
517 unsigned char packetLength[2];
516 unsigned char packetLength[2];
518 // DATA FIELD HEADER
517 // DATA FIELD HEADER
519 unsigned char spare1_pusVersion_spare2;
518 unsigned char spare1_pusVersion_spare2;
520 unsigned char serviceType;
519 unsigned char serviceType;
521 unsigned char serviceSubType;
520 unsigned char serviceSubType;
522 unsigned char destinationID;
521 unsigned char destinationID;
523 unsigned char time[6];
522 unsigned char time[6];
524 // AUXILIARY HEADER
523 // AUXILIARY HEADER
525 unsigned char sid;
524 unsigned char sid;
526 unsigned char biaStatusInfo;
525 unsigned char biaStatusInfo;
527 unsigned char sy_lfr_common_parameters_spare;
526 unsigned char sy_lfr_common_parameters_spare;
528 unsigned char sy_lfr_common_parameters;
527 unsigned char sy_lfr_common_parameters;
529 unsigned char acquisitionTime[6];
528 unsigned char acquisitionTime[6];
530 unsigned char source_data_spare;
529 unsigned char source_data_spare;
531 unsigned char pa_lfr_bp_blk_nr[2];
530 unsigned char pa_lfr_bp_blk_nr[2];
532 } Header_TM_LFR_SCIENCE_BP_with_spare_t;
531 } Header_TM_LFR_SCIENCE_BP_with_spare_t;
533
532
534 typedef struct {
533 typedef struct {
535 unsigned char targetLogicalAddress;
534 unsigned char targetLogicalAddress;
536 unsigned char protocolIdentifier;
535 unsigned char protocolIdentifier;
537 unsigned char reserved;
536 unsigned char reserved;
538 unsigned char userApplication;
537 unsigned char userApplication;
539 unsigned char packetID[2];
538 unsigned char packetID[2];
540 unsigned char packetSequenceControl[2];
539 unsigned char packetSequenceControl[2];
541 unsigned char packetLength[2];
540 unsigned char packetLength[2];
542 // DATA FIELD HEADER
541 // DATA FIELD HEADER
543 unsigned char spare1_pusVersion_spare2;
542 unsigned char spare1_pusVersion_spare2;
544 unsigned char serviceType;
543 unsigned char serviceType;
545 unsigned char serviceSubType;
544 unsigned char serviceSubType;
546 unsigned char destinationID;
545 unsigned char destinationID;
547 unsigned char time[6];
546 unsigned char time[6];
548 // AUXILIARY HEADER
547 // AUXILIARY HEADER
549 unsigned char sid;
548 unsigned char sid;
550 unsigned char biaStatusInfo;
549 unsigned char biaStatusInfo;
551 unsigned char sy_lfr_common_parameters_spare;
550 unsigned char sy_lfr_common_parameters_spare;
552 unsigned char sy_lfr_common_parameters;
551 unsigned char sy_lfr_common_parameters;
553 unsigned char acquisitionTime[6];
552 unsigned char acquisitionTime[6];
554 unsigned char pa_lfr_bp_blk_nr[2];
553 unsigned char pa_lfr_bp_blk_nr[2];
555 } Header_TM_LFR_SCIENCE_BP_t;
554 } Header_TM_LFR_SCIENCE_BP_t;
556
555
557 typedef struct {
556 typedef struct {
558 //targetLogicalAddress is removed by the grspw module
557 //targetLogicalAddress is removed by the grspw module
559 unsigned char protocolIdentifier;
558 unsigned char protocolIdentifier;
560 unsigned char reserved;
559 unsigned char reserved;
561 unsigned char userApplication;
560 unsigned char userApplication;
562 unsigned char packetID[2];
561 unsigned char packetID[2];
563 unsigned char packetSequenceControl[2];
562 unsigned char packetSequenceControl[2];
564 unsigned char packetLength[2];
563 unsigned char packetLength[2];
565 // DATA FIELD HEADER
564 // DATA FIELD HEADER
566 unsigned char headerFlag_pusVersion_Ack;
565 unsigned char headerFlag_pusVersion_Ack;
567 unsigned char serviceType;
566 unsigned char serviceType;
568 unsigned char serviceSubType;
567 unsigned char serviceSubType;
569 unsigned char sourceID;
568 unsigned char sourceID;
570 unsigned char dataAndCRC[CCSDS_TC_PKT_MAX_SIZE-10];
569 unsigned char dataAndCRC[CCSDS_TC_PKT_MAX_SIZE-10];
571 } ccsdsTelecommandPacket_t;
570 } ccsdsTelecommandPacket_t;
572
571
573 typedef struct {
572 typedef struct {
574 unsigned char targetLogicalAddress;
573 unsigned char targetLogicalAddress;
575 unsigned char protocolIdentifier;
574 unsigned char protocolIdentifier;
576 unsigned char reserved;
575 unsigned char reserved;
577 unsigned char userApplication;
576 unsigned char userApplication;
578 unsigned char packetID[2];
577 unsigned char packetID[2];
579 unsigned char packetSequenceControl[2];
578 unsigned char packetSequenceControl[2];
580 unsigned char packetLength[2];
579 unsigned char packetLength[2];
581 unsigned char spare1_pusVersion_spare2;
580 unsigned char spare1_pusVersion_spare2;
582 unsigned char serviceType;
581 unsigned char serviceType;
583 unsigned char serviceSubType;
582 unsigned char serviceSubType;
584 unsigned char destinationID;
583 unsigned char destinationID;
585 unsigned char time[6];
584 unsigned char time[6];
586 unsigned char sid;
585 unsigned char sid;
587
586
588 //**************
587 //**************
589 // HK PARAMETERS
588 // HK PARAMETERS
590 unsigned char lfr_status_word[2];
589 unsigned char lfr_status_word[2];
591 unsigned char lfr_sw_version[4];
590 unsigned char lfr_sw_version[4];
592 unsigned char lfr_fpga_version[3];
591 unsigned char lfr_fpga_version[3];
593 // ressource statistics
592 // ressource statistics
594 unsigned char hk_lfr_cpu_load;
593 unsigned char hk_lfr_cpu_load;
595 unsigned char hk_lfr_cpu_load_max;
594 unsigned char hk_lfr_cpu_load_max;
596 unsigned char hk_lfr_cpu_load_aver;
595 unsigned char hk_lfr_cpu_load_aver;
597 unsigned char hk_lfr_q_sd_fifo_size_max;
596 unsigned char hk_lfr_q_sd_fifo_size_max;
598 unsigned char hk_lfr_q_sd_fifo_size;
597 unsigned char hk_lfr_q_sd_fifo_size;
599 unsigned char hk_lfr_q_rv_fifo_size_max;
598 unsigned char hk_lfr_q_rv_fifo_size_max;
600 unsigned char hk_lfr_q_rv_fifo_size;
599 unsigned char hk_lfr_q_rv_fifo_size;
601 unsigned char hk_lfr_q_p0_fifo_size_max;
600 unsigned char hk_lfr_q_p0_fifo_size_max;
602 unsigned char hk_lfr_q_p0_fifo_size;
601 unsigned char hk_lfr_q_p0_fifo_size;
603 unsigned char hk_lfr_q_p1_fifo_size_max;
602 unsigned char hk_lfr_q_p1_fifo_size_max;
604 unsigned char hk_lfr_q_p1_fifo_size;
603 unsigned char hk_lfr_q_p1_fifo_size;
605 unsigned char hk_lfr_q_p2_fifo_size_max;
604 unsigned char hk_lfr_q_p2_fifo_size_max;
606 unsigned char hk_lfr_q_p2_fifo_size;
605 unsigned char hk_lfr_q_p2_fifo_size;
607 // tc statistics
606 // tc statistics
608 unsigned char hk_lfr_update_info_tc_cnt[2];
607 unsigned char hk_lfr_update_info_tc_cnt[2];
609 unsigned char hk_lfr_update_time_tc_cnt[2];
608 unsigned char hk_lfr_update_time_tc_cnt[2];
610 unsigned char hk_lfr_exe_tc_cnt[2];
609 unsigned char hk_lfr_exe_tc_cnt[2];
611 unsigned char hk_lfr_rej_tc_cnt[2];
610 unsigned char hk_lfr_rej_tc_cnt[2];
612 unsigned char hk_lfr_last_exe_tc_id[2];
611 unsigned char hk_lfr_last_exe_tc_id[2];
613 unsigned char hk_lfr_last_exe_tc_type[2];
612 unsigned char hk_lfr_last_exe_tc_type[2];
614 unsigned char hk_lfr_last_exe_tc_subtype[2];
613 unsigned char hk_lfr_last_exe_tc_subtype[2];
615 unsigned char hk_lfr_last_exe_tc_time[6];
614 unsigned char hk_lfr_last_exe_tc_time[6];
616 unsigned char hk_lfr_last_rej_tc_id[2];
615 unsigned char hk_lfr_last_rej_tc_id[2];
617 unsigned char hk_lfr_last_rej_tc_type[2];
616 unsigned char hk_lfr_last_rej_tc_type[2];
618 unsigned char hk_lfr_last_rej_tc_subtype[2];
617 unsigned char hk_lfr_last_rej_tc_subtype[2];
619 unsigned char hk_lfr_last_rej_tc_time[6];
618 unsigned char hk_lfr_last_rej_tc_time[6];
620 // anomaly statistics
619 // anomaly statistics
621 unsigned char hk_lfr_le_cnt[2];
620 unsigned char hk_lfr_le_cnt[2];
622 unsigned char hk_lfr_me_cnt[2];
621 unsigned char hk_lfr_me_cnt[2];
623 unsigned char hk_lfr_he_cnt[2];
622 unsigned char hk_lfr_he_cnt[2];
624 unsigned char hk_lfr_last_er_rid[2];
623 unsigned char hk_lfr_last_er_rid[2];
625 unsigned char hk_lfr_last_er_code;
624 unsigned char hk_lfr_last_er_code;
626 unsigned char hk_lfr_last_er_time[6];
625 unsigned char hk_lfr_last_er_time[6];
627 // vhdl_blk_status
626 // vhdl_blk_status
628 unsigned char hk_lfr_vhdl_aa_sm;
627 unsigned char hk_lfr_vhdl_aa_sm;
629 unsigned char hk_lfr_vhdl_fft_sr;
628 unsigned char hk_lfr_vhdl_fft_sr;
630 unsigned char hk_lfr_vhdl_cic_hk;
629 unsigned char hk_lfr_vhdl_cic_hk;
631 unsigned char hk_lfr_vhdl_iir_cal;
630 unsigned char hk_lfr_vhdl_iir_cal;
632 // spacewire_if_statistics
631 // spacewire_if_statistics
633 unsigned char hk_lfr_dpu_spw_pkt_rcv_cnt[2];
632 unsigned char hk_lfr_dpu_spw_pkt_rcv_cnt[2];
634 unsigned char hk_lfr_dpu_spw_pkt_sent_cnt[2];
633 unsigned char hk_lfr_dpu_spw_pkt_sent_cnt[2];
635 unsigned char hk_lfr_dpu_spw_tick_out_cnt;
634 unsigned char hk_lfr_dpu_spw_tick_out_cnt;
636 unsigned char hk_lfr_dpu_spw_last_timc;
635 unsigned char hk_lfr_dpu_spw_last_timc;
637 // ahb error statistics
636 // ahb error statistics
638 unsigned char hk_lfr_last_fail_addr[4];
637 unsigned char hk_lfr_last_fail_addr[4];
639 // temperatures
638 // temperatures
640 unsigned char hk_lfr_temp_scm[2];
639 unsigned char hk_lfr_temp_scm[2];
641 unsigned char hk_lfr_temp_pcb[2];
640 unsigned char hk_lfr_temp_pcb[2];
642 unsigned char hk_lfr_temp_fpga[2];
641 unsigned char hk_lfr_temp_fpga[2];
643 // spacecraft potential
642 // spacecraft potential
644 unsigned char hk_lfr_sc_v_f3[2];
643 unsigned char hk_lfr_sc_v_f3[2];
645 unsigned char hk_lfr_sc_e1_f3[2];
644 unsigned char hk_lfr_sc_e1_f3[2];
646 unsigned char hk_lfr_sc_e2_f3[2];
645 unsigned char hk_lfr_sc_e2_f3[2];
647 // lfr common parameters
646 // lfr common parameters
648 unsigned char sy_lfr_common_parameters_spare;
647 unsigned char sy_lfr_common_parameters_spare;
649 unsigned char sy_lfr_common_parameters;
648 unsigned char sy_lfr_common_parameters;
650 // error counters
649 // error counters
651 unsigned char hk_lfr_dpu_spw_parity;
650 unsigned char hk_lfr_dpu_spw_parity;
652 unsigned char hk_lfr_dpu_spw_disconnect;
651 unsigned char hk_lfr_dpu_spw_disconnect;
653 unsigned char hk_lfr_dpu_spw_escape;
652 unsigned char hk_lfr_dpu_spw_escape;
654 unsigned char hk_lfr_dpu_spw_credit;
653 unsigned char hk_lfr_dpu_spw_credit;
655 unsigned char hk_lfr_dpu_spw_write_sync;
654 unsigned char hk_lfr_dpu_spw_write_sync;
656 unsigned char hk_lfr_dpu_spw_rx_ahb;
655 unsigned char hk_lfr_dpu_spw_rx_ahb;
657 unsigned char hk_lfr_dpu_spw_tx_ahb;
656 unsigned char hk_lfr_dpu_spw_tx_ahb;
658 unsigned char hk_lfr_dpu_spw_early_eop;
657 unsigned char hk_lfr_dpu_spw_early_eop;
659 unsigned char hk_lfr_dpu_spw_invalid_addr;
658 unsigned char hk_lfr_dpu_spw_invalid_addr;
660 unsigned char hk_lfr_dpu_spw_eep;
659 unsigned char hk_lfr_dpu_spw_eep;
661 unsigned char hk_lfr_dpu_spw_rx_too_big;
660 unsigned char hk_lfr_dpu_spw_rx_too_big;
662 // timecode
661 // timecode
663 unsigned char hk_lfr_timecode_erroneous;
662 unsigned char hk_lfr_timecode_erroneous;
664 unsigned char hk_lfr_timecode_missing;
663 unsigned char hk_lfr_timecode_missing;
665 unsigned char hk_lfr_timecode_invalid;
664 unsigned char hk_lfr_timecode_invalid;
666 // time
665 // time
667 unsigned char hk_lfr_time_timecode_it;
666 unsigned char hk_lfr_time_timecode_it;
668 unsigned char hk_lfr_time_not_synchro;
667 unsigned char hk_lfr_time_not_synchro;
669 unsigned char hk_lfr_time_timecode_ctr;
668 unsigned char hk_lfr_time_timecode_ctr;
670 // hk_lfr_buffer_dpu_
669 // hk_lfr_buffer_dpu_
671 unsigned char hk_lfr_buffer_dpu_tc_fifo;
670 unsigned char hk_lfr_buffer_dpu_tc_fifo;
672 unsigned char hk_lfr_buffer_dpu_tm_fifo;
671 unsigned char hk_lfr_buffer_dpu_tm_fifo;
673 // hk_lfr_ahb_
672 // hk_lfr_ahb_
674 unsigned char hk_lfr_ahb_correctable;
673 unsigned char hk_lfr_ahb_correctable;
675 unsigned char hk_lfr_ahb_uncorrectable;
674 unsigned char hk_lfr_ahb_uncorrectable;
676 // spare
675 // spare
677 unsigned char parameters_spare;
676 unsigned char parameters_spare;
678 } Packet_TM_LFR_HK_t;
677 } Packet_TM_LFR_HK_t;
679
678
680 typedef struct {
679 typedef struct {
681 unsigned char targetLogicalAddress;
680 unsigned char targetLogicalAddress;
682 unsigned char protocolIdentifier;
681 unsigned char protocolIdentifier;
683 unsigned char reserved;
682 unsigned char reserved;
684 unsigned char userApplication;
683 unsigned char userApplication;
685 unsigned char packetID[2];
684 unsigned char packetID[2];
686 unsigned char packetSequenceControl[2];
685 unsigned char packetSequenceControl[2];
687 unsigned char packetLength[2];
686 unsigned char packetLength[2];
688 // DATA FIELD HEADER
687 // DATA FIELD HEADER
689 unsigned char spare1_pusVersion_spare2;
688 unsigned char spare1_pusVersion_spare2;
690 unsigned char serviceType;
689 unsigned char serviceType;
691 unsigned char serviceSubType;
690 unsigned char serviceSubType;
692 unsigned char destinationID;
691 unsigned char destinationID;
693 unsigned char time[6];
692 unsigned char time[6];
694 unsigned char sid;
693 unsigned char sid;
695
694
696 //******************
695 //******************
697 // COMMON PARAMETERS
696 // COMMON PARAMETERS
698 unsigned char sy_lfr_common_parameters_spare;
697 unsigned char sy_lfr_common_parameters_spare;
699 unsigned char sy_lfr_common_parameters;
698 unsigned char sy_lfr_common_parameters;
700
699
701 //******************
700 //******************
702 // NORMAL PARAMETERS
701 // NORMAL PARAMETERS
703 unsigned char sy_lfr_n_swf_l[2];
702 unsigned char sy_lfr_n_swf_l[2];
704 unsigned char sy_lfr_n_swf_p[2];
703 unsigned char sy_lfr_n_swf_p[2];
705 unsigned char sy_lfr_n_asm_p[2];
704 unsigned char sy_lfr_n_asm_p[2];
706 unsigned char sy_lfr_n_bp_p0;
705 unsigned char sy_lfr_n_bp_p0;
707 unsigned char sy_lfr_n_bp_p1;
706 unsigned char sy_lfr_n_bp_p1;
708 unsigned char sy_lfr_n_cwf_long_f3;
707 unsigned char sy_lfr_n_cwf_long_f3;
709 unsigned char lfr_normal_parameters_spare;
708 unsigned char lfr_normal_parameters_spare;
710
709
711 //*****************
710 //*****************
712 // BURST PARAMETERS
711 // BURST PARAMETERS
713 unsigned char sy_lfr_b_bp_p0;
712 unsigned char sy_lfr_b_bp_p0;
714 unsigned char sy_lfr_b_bp_p1;
713 unsigned char sy_lfr_b_bp_p1;
715
714
716 //****************
715 //****************
717 // SBM1 PARAMETERS
716 // SBM1 PARAMETERS
718 unsigned char sy_lfr_s1_bp_p0;
717 unsigned char sy_lfr_s1_bp_p0;
719 unsigned char sy_lfr_s1_bp_p1;
718 unsigned char sy_lfr_s1_bp_p1;
720
719
721 //****************
720 //****************
722 // SBM2 PARAMETERS
721 // SBM2 PARAMETERS
723 unsigned char sy_lfr_s2_bp_p0;
722 unsigned char sy_lfr_s2_bp_p0;
724 unsigned char sy_lfr_s2_bp_p1;
723 unsigned char sy_lfr_s2_bp_p1;
725
724
726 // mask F0
725 // mask F0
727 unsigned char sy_lfr_fbins_f0_word1[4];
726 unsigned char sy_lfr_fbins_f0_word1[4];
728 unsigned char sy_lfr_fbins_f0_word2[4];
727 unsigned char sy_lfr_fbins_f0_word2[4];
729 unsigned char sy_lfr_fbins_f0_word3[4];
728 unsigned char sy_lfr_fbins_f0_word3[4];
730 unsigned char sy_lfr_fbins_f0_word4[4];
729 unsigned char sy_lfr_fbins_f0_word4[4];
731 // mask F1
730 // mask F1
732 unsigned char sy_lfr_fbins_f1_word1[4];
731 unsigned char sy_lfr_fbins_f1_word1[4];
733 unsigned char sy_lfr_fbins_f1_word2[4];
732 unsigned char sy_lfr_fbins_f1_word2[4];
734 unsigned char sy_lfr_fbins_f1_word3[4];
733 unsigned char sy_lfr_fbins_f1_word3[4];
735 unsigned char sy_lfr_fbins_f1_word4[4];
734 unsigned char sy_lfr_fbins_f1_word4[4];
736 // mask F2
735 // mask F2
737 unsigned char sy_lfr_fbins_f2_word1[4];
736 unsigned char sy_lfr_fbins_f2_word1[4];
738 unsigned char sy_lfr_fbins_f2_word2[4];
737 unsigned char sy_lfr_fbins_f2_word2[4];
739 unsigned char sy_lfr_fbins_f2_word3[4];
738 unsigned char sy_lfr_fbins_f2_word3[4];
740 unsigned char sy_lfr_fbins_f2_word4[4];
739 unsigned char sy_lfr_fbins_f2_word4[4];
741
740
742 // SPARE
741 // SPARE
743 unsigned char source_data_spare;
742 unsigned char source_data_spare;
744 } Packet_TM_LFR_PARAMETER_DUMP_t;
743 } Packet_TM_LFR_PARAMETER_DUMP_t;
745
744
746 typedef struct {
745 typedef struct {
747 unsigned char targetLogicalAddress;
746 unsigned char targetLogicalAddress;
748 unsigned char protocolIdentifier;
747 unsigned char protocolIdentifier;
749 unsigned char reserved;
748 unsigned char reserved;
750 unsigned char userApplication;
749 unsigned char userApplication;
751 unsigned char packetID[2];
750 unsigned char packetID[2];
752 unsigned char packetSequenceControl[2];
751 unsigned char packetSequenceControl[2];
753 unsigned char packetLength[2];
752 unsigned char packetLength[2];
754 // DATA FIELD HEADER
753 // DATA FIELD HEADER
755 unsigned char spare1_pusVersion_spare2;
754 unsigned char spare1_pusVersion_spare2;
756 unsigned char serviceType;
755 unsigned char serviceType;
757 unsigned char serviceSubType;
756 unsigned char serviceSubType;
758 unsigned char destinationID;
757 unsigned char destinationID;
759 unsigned char time[6];
758 unsigned char time[6];
760 unsigned char sid;
759 unsigned char sid;
761 unsigned char pkt_cnt;
760 unsigned char pkt_cnt;
762 unsigned char pkt_nr;
761 unsigned char pkt_nr;
763 unsigned char blk_nr;
762 unsigned char blk_nr;
764
763
765 //******************
764 //******************
766 // SOURCE DATA repeated N times with N in [0 .. PA_LFR_KCOEFF_BLK_NR]
765 // SOURCE DATA repeated N times with N in [0 .. PA_LFR_KCOEFF_BLK_NR]
767 unsigned char kcoeff_blks[3900]; // one blk is 2 + 4 * 32 = 130 bytes, 30 blks max in one packet (30 * 130 = 3900)
766 unsigned char kcoeff_blks[3900]; // one blk is 2 + 4 * 32 = 130 bytes, 30 blks max in one packet (30 * 130 = 3900)
768
767
769 } Packet_TM_LFR_KCOEFFICIENTS_DUMP_t;
768 } Packet_TM_LFR_KCOEFFICIENTS_DUMP_t;
770
769
771 #endif // CCSDS_TYPES_H_INCLUDED
770 #endif // CCSDS_TYPES_H_INCLUDED
General Comments 0
You need to be logged in to leave comments. Login now