@@ -1,11 +1,11 | |||
|
1 | 1 | <?xml version="1.0" encoding="UTF-8" standalone="yes" ?> |
|
2 | 2 | <CodeBlocks_layout_file> |
|
3 | 3 | <ActiveTarget name="Debug" /> |
|
4 |
<File name="../header/ccsds_types.h" open=" |
|
|
5 |
<Cursor position=" |
|
|
4 | <File name="../header/ccsds_types.h" open="1" top="0" tabpos="2"> | |
|
5 | <Cursor position="553" topLine="24" /> | |
|
6 | 6 | </File> |
|
7 | 7 | <File name="../header/fsw_init.h" open="0" top="0" tabpos="3"> |
|
8 |
<Cursor position=" |
|
|
8 | <Cursor position="1521" topLine="15" /> | |
|
9 | 9 | </File> |
|
10 | 10 | <File name="../header/fsw_misc.h" open="0" top="0" tabpos="0"> |
|
11 | 11 | <Cursor position="114" topLine="0" /> |
@@ -29,7 +29,7 | |||
|
29 | 29 | <Cursor position="378" topLine="1" /> |
|
30 | 30 | </File> |
|
31 | 31 | <File name="../src/fsw_init.c" open="1" top="0" tabpos="1"> |
|
32 |
<Cursor position=" |
|
|
32 | <Cursor position="10747" topLine="81" /> | |
|
33 | 33 | </File> |
|
34 | 34 | <File name="../src/fsw_misc.c" open="0" top="0" tabpos="2"> |
|
35 | 35 | <Cursor position="475" topLine="0" /> |
@@ -37,8 +37,8 | |||
|
37 | 37 | <File name="../src/fsw_processing.c" open="0" top="0" tabpos="0"> |
|
38 | 38 | <Cursor position="1696" topLine="59" /> |
|
39 | 39 | </File> |
|
40 |
<File name="../src/tc_handler.c" open="1" top="1" tabpos=" |
|
|
41 |
<Cursor position="1 |
|
|
40 | <File name="../src/tc_handler.c" open="1" top="1" tabpos="3"> | |
|
41 | <Cursor position="11453" topLine="39" /> | |
|
42 | 42 | </File> |
|
43 | 43 | <File name="../src/wf_handler.c" open="0" top="0" tabpos="4"> |
|
44 | 44 | <Cursor position="1660" topLine="24" /> |
|
1 | NO CONTENT: modified file, binary diff hidden |
@@ -8,7 +8,8 | |||
|
8 | 8 | #define CCSDS_TC_TM_PACKET_OFFSET 7 |
|
9 | 9 | #define CCSDS_PROCESS_ID 76 |
|
10 | 10 | #define CCSDS_PACKET_CATEGORY 12 |
|
11 | #define CCSDS_DESTINATION_ID 0x21 | |
|
11 | #define CCSDS_NODE_ADDRESS 0x01 // SY_DPU_LFR_LA 1 is not allowed by the StarDundee brick, use 101 instead 0x65 | |
|
12 | #define CCSDS_DESTINATION_ID 0x02 // SY_LFR_DPU_LA 2 is not allowed by the StarDundee brick, use 102 instead 0x66 | |
|
12 | 13 | #define CCSDS_PROTOCOLE_ID 0x02 |
|
13 | 14 | #define CCSDS_USER_APP 0x00 |
|
14 | 15 |
@@ -74,7 +74,7 rtems_task Init( rtems_task_argument ign | |||
|
74 | 74 | IRQ_SPARC_WF, waveforms_isr ); |
|
75 | 75 | |
|
76 | 76 | // irq handling of the time management unit |
|
77 |
|
|
|
77 | status = rtems_interrupt_catch( commutation_isr1, | |
|
78 | 78 | IRQ_SPARC_TIME1, |
|
79 | 79 | &old_isr_handler) ; // see sparcv8.pdf p.76 for interrupt levels |
|
80 | 80 | if (status==RTEMS_SUCCESSFUL) |
@@ -87,7 +87,7 rtems_task Init( rtems_task_argument ign | |||
|
87 | 87 | PRINTF("commutation_isr2 *** rtems_interrupt_catch successfullly configured\n") |
|
88 | 88 | |
|
89 | 89 | LEON_Unmask_interrupt( IRQ_TIME1 ); |
|
90 |
|
|
|
90 | LEON_Unmask_interrupt( IRQ_TIME2 ); | |
|
91 | 91 | |
|
92 | 92 | status = rtems_task_delete(RTEMS_SELF); |
|
93 | 93 | } |
@@ -146,7 +146,7 int create_all_tasks() | |||
|
146 | 146 | Task_name[6] = rtems_build_name( 'A', 'V', 'F', '0' ); |
|
147 | 147 | Task_name[7] = rtems_build_name( 'B', 'P', 'F', '0' ); |
|
148 | 148 | Task_name[8] = rtems_build_name( 'W', 'F', 'R', 'M' ); |
|
149 |
|
|
|
149 | Task_name[9] = rtems_build_name( 'D', 'U', 'M', 'B' ); | |
|
150 | 150 | |
|
151 | 151 | // RECV |
|
152 | 152 | status = rtems_task_create( |
@@ -197,11 +197,11 int create_all_tasks() | |||
|
197 | 197 | RTEMS_DEFAULT_ATTRIBUTES | RTEMS_FLOATING_POINT, &Task_id[8] |
|
198 | 198 | ); |
|
199 | 199 | // DUMB |
|
200 |
|
|
|
200 | status = rtems_task_create( | |
|
201 | 201 | Task_name[9], 200, RTEMS_MINIMUM_STACK_SIZE * 2, |
|
202 | 202 | RTEMS_DEFAULT_MODES, |
|
203 | 203 | RTEMS_DEFAULT_ATTRIBUTES, &Task_id[9] |
|
204 |
|
|
|
204 | ); | |
|
205 | 205 | |
|
206 | 206 | return 0; |
|
207 | 207 | } |
@@ -234,8 +234,8 int start_all_tasks() | |||
|
234 | 234 | status = rtems_task_start( Task_id[8], wfrm_task, 1 ); |
|
235 | 235 | if (status!=RTEMS_SUCCESSFUL) PRINTF("In INIT *** Error starting TASK_WFRM\n") |
|
236 | 236 | |
|
237 |
|
|
|
238 |
|
|
|
237 | status = rtems_task_start( Task_id[9], dumb_task, 1 ); | |
|
238 | if (status!=RTEMS_SUCCESSFUL) PRINTF("In INIT *** Error starting TASK_DUMB\n") | |
|
239 | 239 | |
|
240 | 240 | return 0; |
|
241 | 241 | } |
@@ -275,10 +275,15 int configure_spw_link() | |||
|
275 | 275 | |
|
276 | 276 | status = ioctl(fdSPW, SPACEWIRE_IOCTRL_SET_TXBLOCK_ON_FULL, 1); // sets the link-error interrupt bit |
|
277 | 277 | if (status!=RTEMS_SUCCESSFUL) PRINTF("In RECV *** Error SPACEWIRE_IOCTRL_SET_TXBLOCK_ON_FULL\n") |
|
278 | // | |
|
279 |
|
|
|
280 | //if (status!=RTEMS_SUCCESSFUL) PRINTF("In RECV *** Error SPACEWIRE_IOCTRL_SET_LINK_ERR_IRQ\n") | |
|
281 | // | |
|
278 | ||
|
279 | status = ioctl(fdSPW, SPACEWIRE_IOCTRL_SET_DESTKEY, CCSDS_DESTINATION_ID); // sets the destination key | |
|
280 | PRINTF1("destination address set to: %d\n", CCSDS_DESTINATION_ID) | |
|
281 | if (status!=RTEMS_SUCCESSFUL) PRINTF("In RECV *** Error SPACEWIRE_IOCTRL_SET_LINK_ERR_IRQ\n") | |
|
282 | ||
|
283 | status = ioctl(fdSPW, SPACEWIRE_IOCTRL_SET_NODEADDR, CCSDS_NODE_ADDRESS); // sets the destination key | |
|
284 | PRINTF1("node address set to: %d\n", CCSDS_NODE_ADDRESS) | |
|
285 | if (status!=RTEMS_SUCCESSFUL) PRINTF("In RECV *** Error SPACEWIRE_IOCTRL_SET_LINK_ERR_IRQ\n") | |
|
286 | ||
|
282 | 287 | PRINTF("In configure_spw_link *** "GRSPW_DEVICE_NAME" configured successfully\n") |
|
283 | 288 | |
|
284 | 289 | return RTEMS_SUCCESSFUL; |
@@ -289,7 +289,7 rtems_task recv_task( rtems_task_argumen | |||
|
289 | 289 | PRINTF("In RECV *** Error: rtems_task_suspend(RTEMS_SELF)\n") |
|
290 | 290 | } |
|
291 | 291 | else { |
|
292 |
PRINTF1(" |
|
|
292 | PRINTF1("Got pck of length %d\n", len+1) | |
|
293 | 293 | currentTC_LEN_RCV[0] = 0x00; |
|
294 | 294 | currentTC_LEN_RCV[1] = (unsigned char) len - CCSDS_TC_TM_PACKET_OFFSET - 3; // build the corresponding packet size field |
|
295 | 295 | currentTC_LEN_RCV_AsUnsignedInt = (unsigned int) len - CCSDS_TC_TM_PACKET_OFFSET - 3; // => -3 is for Prot ID, Reserved and User App bytes |
General Comments 0
You need to be logged in to leave comments.
Login now