cake
/
libp7
Archived
1
0
Fork 1
This repository has been archived on 2024-03-16. You can view files and clone it, but cannot push or open issues or pull requests.
libp7/src/packet/send_ack.c

41 lines
1.3 KiB
C

/* ************************************************************************** */
/* _____ _ */
/* packet/send_ack.c |_ _|__ _ _| |__ ___ _ _ */
/* | Project: libp7 | |/ _ \| | | | '_ \ / _ \ | | | */
/* | | (_) | |_| | | | | __/ |_| | */
/* By: thomas <thomas@touhey.fr> |_|\___/ \__,_|_| |_|\___|\__, |.fr */
/* Last updated: 2016/10/13 07:33:17 |___/ */
/* */
/* ************************************************************************** */
#include <libp7/internals.h>
/**
* p7_send_ack:
* Send basic command acknowledge.
*
* Default response at successful packet reception.
*
* @arg handle the libp7 handle
* @arg resp get response or not
* @return if it worked
*/
int p7_send_ack(p7_handle_t *handle, int resp)
{
return (p7_send_basic(handle, p7_pt_ack, 0x00, resp));
}
/**
* p7_send_ack_confirm_ow:
* Sends overwrite confirmation.
*
* @arg handle the libp7 handle
* @return if it worked
*/
int p7_send_ack_confirm_ow(p7_handle_t *handle)
{
/* send packet */
return (p7_send_basic(handle, p7_pt_ack, 0x01, 1));
}