examples/multipath/udpserver/udp-server.c
/*---------------------------------------------------------------------------*/
// function to encode incoming control string to condensed form
function to encode incoming control string to condensed form
function to encode incoming control string to condensed form
void encoding(const uint8_t *data, const uint8_t i)
{
    printf("data:%s\n",data);
    strcat(long_str,data);   
    strcat(long_str," a ");
    strcat(long_str,addr_str);            
    strcat(long_str,"|");
    long_str[strlen(long_str)]='\0';
    printf("encoding %s\n",long_str);
}
void encoding ( const uint8_t * data , const uint8_t i ) { printf ( " \n " , data ) ; strcat ( long_str , data ) ; strcat ( long_str , " " ) ; strcat ( long_str , addr_str ) ; strcat ( long_str , " " ) ; long_str [ strlen ( long_str ) ] = ' \0 ' ; printf ( " \n " , long_str ) ; }
function to encode incoming control string to condensed form
function to encode incoming control string to condensed form
// Example // Input: r -76 f fe80::212:7401:1:101 t 164 p  // Output: 05-761164; // 05 -- from 5th anchor node // 76 -- RSSI value // 1 -- mobile node // 164 -- sequence number