xbee_err xbee_conGetTypes(struct xbee *xbee, char ***retList);
xbee_conGetTypes() allows you to retrieve a list of connection types that are provided by the given libxbee instance's mode. Once you have used the returned array, you should free() the pointer to avoid memory leaks. The last item in the array is set to NULL to mark the end.
For a list of connection types generally avaliable, please see xbee_conNew(3).
#include <xbee.h> struct xbee *xbee; char **types; int i; /* initialize xbee, using xbee_setup() */ if (xbee_conGetTypes(xbee, &types) != XBEE_ENONE) return; for (i = 0; types[i]; i++) { printf("type %d: %s\n", i, types[i]); } free(types);