SYNOPSIS

#include <netax25/ax25.h>

int ax25_aton(const char *cp, struct full_sockaddr_ax25 *fsap);

int ax25_aton_arglist(const char **cp, struct full_sockaddr_ax25 *fsap);

int ax25_aton_entry(const char *cp, char *axp);

char *ax25_ntoa(ax25_address *axp);

int ax25_cmp(ax25_address *ax1, ax25_address *ax2);

int ax25_validate(char *axp);

char *ax25_config_file(const char *filename);

DESCRIPTION

ax25_aton() takes the ASCII string cp that is in the format callsign [[V|VIA]callsign...] and stores it in fsap in network format.

ax25_aton_entry() takes the ASCII string of a callsign cp and stores it in network format in axp.

The ax25_aton_arglist() takes a NULL terminated array of strings cp and stores it in fsap in network format.

The ax25_ntoa() takes a network format address axp and returns the ASCII representation. The string is returned in a statically allocated buffer, which subsequent calls will overwrite.

The ax25_cmp() function compares the two ax25 addresses, ax1 and ax2, that are in network format and determines wether they are identical, differ only by their SSIDs or are different.

The ax25_validate() function checks to see if the address axp in network format is a correctly formatted address.

RETURN VALUE

The ax25_aton()and ax25_aton_arglist() functions return -1 if an error occurs otherwise the length of the returned structure.

The ax25_aton_entry() function returns -1 if an error occurs otherwise zero.

The ax25_cmp() function returns 0 if the two addresses are identical, 1 if they are different or 2 is only the SSIDs are different.

The ax25_validate() function returns TRUE if the callsign is valid or FALSE if it is not.

RELATED TO ax25_cmp…