OVMS3-idf/components/coap/port/include/coap/coap.h
Jon Shallow bc9d1a65d7 Update component/coap to libcoap version release-4.2.0
This takes the code up to the latest released version of libcoap.

As there have been API changes, coap_client and coap_server in
examples/protocols have been updated to use the new APIs.

Further information on the new libcoap APIs can be found at
https://libcoap.net/doc/reference/4.2.0/

coap_client has been updated to handle BLOCK2 responses from
"coap://californium.eclipse.org"
coap_client has been modified to only send out one request (and wait for
the response)

coap_server has been updated to support Observe subscriptions, and well as
adding in PUT and DELETE handlers to work on the Espressif resource

coap_server and coap_client have had their stack sizes increased.

port/coap_io.c has been added, a copy of libcoap/src/coap_io.c with support
added for systems that do not have RFC 3542 section 20 support.

port/coap_io_socket.c has been removed as a lot of the code is now
replicated in different libcoap files.

Once this PR is place, then adding in DTLS will be a lot simpler (as a
separate PR)

Signed-off-by: Jitin George <jitin@espressif.com>

Merges https://github.com/espressif/esp-idf/pull/3148
2019-03-18 12:33:52 +00:00

50 lines
1 KiB
C

/* Modify head file implementation for ESP32 platform.
*
* Uses libcoap software implementation for failover when concurrent
* define operations are in use.
*
* coap.h -- main header file for CoAP stack of libcoap
*
* Copyright (C) 2010-2012,2015-2016 Olaf Bergmann <bergmann@tzi.org>
* 2015 Carsten Schoenert <c.schoenert@t-online.de>
*
* Copyright 2015-2016 Espressif Systems (Shanghai) PTE LTD
*
* This file is part of the CoAP library libcoap. Please see README for terms
* of use.
*/
#ifndef _COAP_H_
#define _COAP_H_
#ifdef __cplusplus
extern "C" {
#endif
#include "libcoap.h"
#include "address.h"
#include "async.h"
#include "bits.h"
#include "block.h"
#include "coap_dtls.h"
#include "coap_event.h"
#include "coap_io.h"
#include "coap_time.h"
#include "coap_debug.h"
#include "encode.h"
#include "mem.h"
#include "net.h"
#include "option.h"
#include "pdu.h"
#include "prng.h"
#include "resource.h"
#include "str.h"
#include "subscribe.h"
#include "uri.h"
#ifdef __cplusplus
}
#endif
#endif /* _COAP_H_ */