I2C code testing

Dependencies:   FreescaleIAP SimpleDMA mbed-rtos mbed

Fork of COM_MNG_TMTC_SIMPLE_pl123 by Siva ram

Revision:
26:5fbb71ac7127
Parent:
25:60964ad4f13b
Child:
27:f408ea06fcab
--- a/COM_SND_TM.h	Sat Jan 02 05:43:22 2016 +0000
+++ b/COM_SND_TM.h	Sat Jan 02 14:37:59 2016 +0000
@@ -63,7 +63,7 @@
         Base_tm*head = head_ptr;
         type0_no = 0;
         type1_no = 0;
-        while(head->next_TM != NULL){
+        while(head != NULL){
             switch( GETshort_or_long_tm(head->fields) ){
                 case 0:
                     type0_no++;
@@ -86,7 +86,7 @@
         }
         else segment_r = 0;
         TOTAL_SEGMENT_NO -= SEGMENT_NO;
-        LAST_SEGMENT_SIZE = total_frames*2%ISR;
+        LAST_SEGMENT_SIZE = total_frames*2%ISR?total_frames*2%ISR:ISR;
     }
  
 #define next_type_structure(ptr){\