• 大小: 0.75M
    文件类型: .zip
    金币: 1
    下载: 1 次
    发布日期: 2024-05-03
  • 语言: C#
  • 标签: 串口助手  助手  串口  

资源简介


资源截图

代码片段和文件信息

/*
 *
 * NMEA library
 * URL: http://nmea.sourceforge.net
 * Author: Tim (xtimor@gmail.com)
 * Licence: http://www.gnu.org/licenses/lgpl.html
 * $Id: context.c 17 2008-03-11 11:56:11Z xtimor $
 *
 */

#include “nmea/context.h“

#include 
#include 
#include 

nmeaPROPERTY * nmea_property()
{
    static nmeaPROPERTY prop = {
        0 0 NMEA_DEF_PARSEBUFF
        };

    return ∝
}

void nmea_trace(const char *str ...)
{
    int size;
    va_list arg_list;
    char buff[NMEA_DEF_PARSEBUFF];
    nmeaTraceFunc func = nmea_property()->trace_func;

    if(func)
    {
        va_start(arg_list str);
        size = NMEA_POSIX(vsnprintf)(&buff[0] NMEA_DEF_PARSEBUFF - 1 str arg_list);
        va_end(arg_list);

        if(size > 0)
            (*func)(&buff[0] size);
    }
}

void nmea_trace_buff(const char *buff int buff_size)
{
    nmeaTraceFunc func = nmea_property()->trace_func;
    if(func && buff_size)
        (*func)(buff buff_size);
}

void nmea_error(const char *str ...)
{
    int size;
    va_list arg_list;
    char buff[NMEA_DEF_PARSEBUFF];
    nmeaErrorFunc func = nmea_property()->error_func;

    if(func)
    {
        va_start(arg_list str);
        size = NMEA_POSIX(vsnprintf)(&buff[0] NMEA_DEF_PARSEBUFF - 1 str arg_list);
        va_end(arg_list);

        if(size > 0)
            (*func)(&buff[0] size);
    }
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2016-04-25 03:13  CSharp-Client\
     文件        2420  2016-04-25 03:13  CSharp-Client\.gitignore
     文件       35114  2016-04-25 03:13  CSharp-Client\LICENSE
     目录           0  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\
     目录           0  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\
     目录           0  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\
     目录           0  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\
     目录           0  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\
     文件        1074  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\config.h
     文件         891  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\context.h
     文件        1311  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\generate.h
     文件        1903  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\generator.h
     文件        2403  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\gmath.h
     文件        3410  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\info.h
     文件         485  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\nmea.h
     文件          97  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\nmeaLib.h
     文件        1117  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\parse.h
     文件        1226  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\parser.h
     文件        4933  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\sentence.h
     文件        1358  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\stdafx.h
     文件         988  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\time.h
     文件         672  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\tok.h
     文件         726  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\include\nmea\units.h
     文件        5393  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\nmeaLib.vcxproj
     文件        3319  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\nmeaLib.vcxproj.filters
     目录           0  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\src\
     文件        1390  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\src\context.c
     文件        6935  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\src\generate.c
     文件        9023  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\src\generator.c
     文件       11989  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\src\gmath.c
     文件        5274  2016-04-25 03:13  CSharp-Client\多功能串口调试助手\wildfire_MultiFuctionalSerial_assistant\nmeaLib\src\info.c
............此处省略298个文件信息

评论

共有 条评论