libfap Documentation

0.6

Abstract

This documentation describes briefly libfap, an APRS parser made by porting most important parts of the Ham::APRS::FAP - Finnish APRS Parser (Fabulous APRS Parser) perl module into C.

API of the parser has been declared in the fap.h file, others are listed here for those who are interested in internal operation of the parser.

Usage example

#include <fap.h>

int main()
{
        char* input;
        unsigned int input_len;
        fap_packet_t* packet;

        fap_init();

        // Read TNC2-formatted input for example from APRS-IS.

        packet = fap_parseaprs(input, input_len, 0);
        if ( packet->error_code )
        {
                printf("Failed to parse packet (%s): %s\n", input, fap_explain_error(*packet->error_code));
        }
        else if ( packet->src_callsign )
        {
                printf("Got packet from %s.\n", packet->src_callsign);
        }
        
        fap_cleanup();
        
        return EXIT_SUCCESS;
}

Generated on Fri Dec 11 22:10:33 2009 for libfap by  doxygen 1.5.6