owlps/libowlps-client/owlps-client.h

35 lines
1.3 KiB
C

/*
* This library contains code used to send positioning requests (normal,
* calibration or autocalibration) to the aggregaton server.
*/
#ifndef _LIBOWLPS_CLIENT_
#define _LIBOWLPS_CLIENT_
#include <owlps.h>
/* Error codes */
#define ERR_CREATING_SOCKET 151 // Error when creating output socket
#define ERR_SENDING_INFO 152 // Error sending a localisation request
/* Function headers */
int owlclient_create_trx_socket(const char *const dest_ip,
const uint_fast16_t dest_port,
struct sockaddr_in *const server,
const char *const iface) ;
void owlclient_use_iface(const int sockfd, const char *const iface) ;
void owlclient_send_request(const int sockfd,
const struct sockaddr_in *const server,
const void *const packet,
const uint_fast16_t packet_size,
const uint_fast16_t nb_pkt,
const uint_fast32_t delay) ;
void owlclient_send_packet(const int sockfd,
const struct sockaddr_in *const server,
const void *const packet,
const uint_fast16_t packet_size) ;
#endif // _LIBOWLPS_CLIENT_