CoAP observe. More...
#include <stdlib.h>
#include "core/net.h"
#include "coap/coap_client.h"
#include "coap/coap_client_observe.h"
#include "coap/coap_client_misc.h"
#include "debug.h"
Go to the source code of this file.
Macros | |
#define | TRACE_LEVEL COAP_TRACE_LEVEL |
Functions | |
error_t | coapClientProcessNotification (CoapClientRequest *request, const CoapMessage *response) |
Process notification response. More... | |
bool_t | coapClientCheckSequenceNumber (CoapClientRequest *request, uint32_t v2, systime_t t2) |
Check the order of arrival for incoming notification. More... | |
Detailed Description
CoAP observe.
License
SPDX-License-Identifier: GPL-2.0-or-later
Copyright (C) 2010-2024 Oryx Embedded SARL. All rights reserved.
This file is part of CycloneTCP Open.
This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
- Version
- 2.4.4
Definition in file coap_client_observe.c.
Macro Definition Documentation
◆ TRACE_LEVEL
#define TRACE_LEVEL COAP_TRACE_LEVEL |
Definition at line 32 of file coap_client_observe.c.
Function Documentation
◆ coapClientCheckSequenceNumber()
bool_t coapClientCheckSequenceNumber | ( | CoapClientRequest * | request, |
uint32_t | v2, | ||
systime_t | t2 | ||
) |
Check the order of arrival for incoming notification.
- Parameters
-
[in] request CoAP request handle [in] v2 Value of the Observe option in the incoming notification [in] t2 Client-local timestamp for the incoming notification
- Returns
- TRUE if the incoming notification was sent more recently than the freshest notification so far. Otherwise FALSE is returned
Definition at line 132 of file coap_client_observe.c.
◆ coapClientProcessNotification()
error_t coapClientProcessNotification | ( | CoapClientRequest * | request, |
const CoapMessage * | response | ||
) |
Process notification response.
- Parameters
-
[in] request CoAP request handle [in] response Pointer to the response message
- Returns
- Error code
Definition at line 53 of file coap_client_observe.c.