StdPJ/Core/Src/APP/BSP/ug96/ug96.c
/**
  * @brief  Parses and returns .
  * @param  ptr: pointer to string
  * @retval The number of unread data in modem TX buffer.
  */
@brief  Parses and returns .
@param  ptr: pointer to string
@retval The number of unread data in modem TX buffer.
@brief Parses and returns . @param ptr : pointer to string @retval The number of unread data in modem TX buffer .
static void  ParseQISEND(char* ptr, uint32_t* unackedbytes)
{
  uint8_t hexnum = 0, hexcnt;
  uint32_t temp = 0;
  while(*ptr) {
    hexcnt = 1;
    if(*ptr != ',')
    {
      temp = (uint32_t) ParseNumber(ptr, &hexcnt);
      hexnum++;
      if (hexnum == 3)
      {
        *unackedbytes  = temp;
      }
    }
    ptr = ptr + hexcnt;
    if((*ptr == '\r') || (hexnum == 3))
    {
      return;
    }
  }
}
static void ParseQISEND ( char * ptr , uint32_t * unackedbytes ) { uint8_t hexnum = 0 , hexcnt ; uint32_t temp = 0 ; while ( * ptr ) { hexcnt = 1 ; if ( * ptr != ' ' ) { temp = ( uint32_t ) ParseNumber ( ptr , & hexcnt ) ; hexnum ++ ; if ( hexnum == 3 ) { * unackedbytes = temp ; } } ptr = ptr + hexcnt ; if ( ( * ptr == ' \r ' ) || ( hexnum == 3 ) ) { return ; } } }
@brief  Parses and returns .
@brief Parses and returns .
/* QISEND Response contains 3 kind of information
   * <total_send_length>,<ackedbytes>,<unackedbytes>
   * we're only interested to the 3rd one, unackedbytes for now */ /* Count up the number we've retrieved */