/* Add a specified length protocal header to the end of data buffer hold by specified rtk_buffer. This function extends used data area of the buffer at the buffer end.  */
uint8_t* RtbAddTail(RTK_BUFFER *RtkBuffer, uint32_t Length)
/* Add a specified length protocal header to the end of data buffer hold by specified rtk_buffer. This function extends used data area of the buffer at the buffer end.  */
uint8_t* RtbAddTail(RTK_BUFFER *RtkBuffer, uint32_t Length)
{
    if ((uint32_t)(RtkBuffer->Tail - RtkBuffer->End) >= Length)
    {
        uint8_t* Tmp = RtkBuffer->End;
        RtkBuffer->End += Length;
        RtkBuffer->Length += Length;
        return Tmp;
    }
    return NULL;
}