June 30

Dependencies:   FreescaleIAP SimpleDMA mbed-rtos mbed

Fork of CDMS_CODE by shubham c

Files at this revision

API Documentation at this revision

Comitter:
ee12b079
Date:
Sun Apr 10 06:40:40 2016 +0000
Parent:
150:fa3940954b1e
Commit message:
Corrected FMS MMS TC, OBSRS TM to be checked.

Changed in this revision

COM_MNG_TMTC.h Show annotated file Show diff for this revision Revisions of this file
--- a/COM_MNG_TMTC.h	Wed Apr 06 13:11:15 2016 +0000
+++ b/COM_MNG_TMTC.h	Sun Apr 10 06:40:40 2016 +0000
@@ -196,7 +196,7 @@
 
 // CDMS TEAM CODE START
 inline Base_tm* FCTN_CDMS_RLY_TMTC(Base_tc *tc_ptr){
-    uint8_t ACKCODE = 0x00;
+    uint8_t ACKCODE = 0xB0;
     //printf("\rTC execution in progress\r\n");
     Base_tm *tm_pointer = new Long_tm;
     Base_tm *tm_ptr = tm_pointer;
@@ -299,9 +299,9 @@
                                     //Data[0] = FCTN_CDMS_RD_FLASH(0);
                                     //Data[1] = FCTN_CDMS_RD_FLASH(1);                                                                                             
                                     //tm_pointer = new Long_tm;
-                                    tm_pointer->TM_string[0] = 0x30;
+                                    tm_pointer->TM_string[0] = 0xB0;
                                     tm_pointer->TM_string[1] = GETpacket_seq_count(tc_ptr);
-                                    tm_pointer->TM_string[2] = (uint8_t)(flash_counter);
+                                    tm_pointer->TM_string[2] = ACKCODE;
                                     for(uint8_t i=0;i<4;i++)
                                     {
                                         tm_pointer->TM_string[3+i] = (uint8_t)((Data[0]>>(8*i))&0x00FF);
@@ -310,7 +310,7 @@
                                     {
                                         tm_pointer->TM_string[3+i] = (uint8_t)((Data[1]>>(8*i))&0x00FF);
                                     }
-                                    crc16 = crc16_gen(tm_ptr->TM_string,9);
+                                    crc16 = crc16_gen(tm_ptr->TM_string,11);
                                     tm_pointer->TM_string[11] = (uint8_t)((crc16&0xFF00)>>8);
                                     tm_pointer->TM_string[12] = (uint8_t)(crc16&0x00FF);
                                 tm_pointer->next_TM = NULL;                 return tm_ptr;