FM

Dependencies:   SimpleDMA eeprom mbed-rtos mbed FreescaleIAP

Fork of CDMS_CODE by shubham c

Revision:
99:efde3df6cd94
Parent:
98:fd99ddc0e0a1
Child:
101:bece931236a2
--- a/main.cpp	Tue Jan 26 10:05:19 2016 +0000
+++ b/main.cpp	Tue Jan 26 12:18:53 2016 +0000
@@ -2,12 +2,7 @@
 
 #include "mbed.h"
 
-//#define DEBUG_DEF 1
-//
-//#define DEBUF_PRINT(x) \
-//    #ifdef DEBUG_DEF \
-//    gPC.puts(x);\
-//    #endif
+#define DEBUG 1
 
 #include "rtos.h"
 #include "mbed_debug.h"
@@ -17,11 +12,9 @@
 #include "crc.h"
 #include "COM_SND_TM_functions.h"
 #include "COM_SND_TM.h"
-//#include "SDCread.h"
-//#include "cdms_sd.h"
+#include "cdms_sd.h"
 #include "OBSRS.h"
 #include "adf.h"
-//#include "SDC_init.h"
 #include "COM_RCV_TC.h"
 #include "COM_MNG_TMTC.h"
 #include "COM_POWER_ON_TX.h"
@@ -29,8 +22,6 @@
 #include "Compression.h"
 #include "ThreadsAndFunctions.h"
 
-InterruptIn inr(PTA13);
-
 void set_sig(){gSCIENCE_THREAD->signal_set(SCIENCE_SIGNAL);}
 int main()
 {
@@ -60,7 +51,7 @@
     gCS_ADF = 1;
     
     //FCTN_CDMS_INIT_RTC();/* rtc initialization*/
-//    FCTN_CDMS_SD_INIT();/* sd card initialization*/
+    FCTN_CDMS_SD_INIT();/* sd card initialization*/
     
     // initialise_card();
     // int result= initialise_card();
@@ -74,11 +65,15 @@
     // COM_MNG_TMTC THREAD
     gCOM_MNG_TMTC_THREAD = new Thread(COM_MNG_TMTC_FUN);
     gCOM_MNG_TMTC_THREAD->set_priority(osPriorityAboveNormal);
+    #if DEBUG
     gPC.puts("allocating threads\r\n");
+    #endif
     gSCIENCE_THREAD = new Thread(SCIENCE_FUN);
    // gPC.puts("step one complete\r\n");
     gSCIENCE_THREAD->set_priority(osPriorityBelowNormal);
+    #if DEBUG
     gPC.puts("competed allocating threads\r\n");
+    #endif
     // *******************INITIALISATIONS END********************
     
     /*starting the thread with signal*/