mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
tests/nanocoap_cli: define CoAP resources as XFA
This commit is contained in:
parent
44c267c84a
commit
e45508dab4
@ -14,6 +14,7 @@ USEMODULE += gnrc_ipv6_default
|
||||
# USEMODULE += gnrc_ipv6_nib_dns # include RDNSS option handling
|
||||
|
||||
USEMODULE += nanocoap_sock
|
||||
USEMODULE += nanocoap_resources
|
||||
|
||||
# boards where basic nanocoap functionality fits, but no VFS
|
||||
LOW_MEMORY_BOARDS := \
|
||||
|
@ -72,10 +72,6 @@ static ssize_t _value_handler(coap_pkt_t *pkt, uint8_t *buf, size_t len, coap_re
|
||||
COAP_FORMAT_TEXT, (uint8_t*)rsp, p);
|
||||
}
|
||||
|
||||
/* must be sorted by path (ASCII order) */
|
||||
const coap_resource_t coap_resources[] = {
|
||||
COAP_WELL_KNOWN_CORE_DEFAULT_HANDLER,
|
||||
{ "/value", COAP_GET | COAP_PUT | COAP_POST, _value_handler, NULL },
|
||||
NANOCOAP_RESOURCE(value) {
|
||||
.path = "/value", .methods = COAP_GET | COAP_PUT | COAP_POST, .handler = _value_handler,
|
||||
};
|
||||
|
||||
const unsigned coap_resources_numof = ARRAY_SIZE(coap_resources);
|
||||
|
Loading…
Reference in New Issue
Block a user