0% found this document useful (0 votes)
380 views

IoT-Protocol CoAP

CoAP is a lightweight protocol designed for constrained devices and networks. It uses UDP as the underlying transport protocol and defines message formats and types for request-response interactions. CoAP supports reliable transmission of confirmable messages through retransmissions and timeouts. Service discovery in CoAP is done through multicast IP addresses for nodes to broadcast available services and discover other devices on the network.

Uploaded by

Cindy
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
380 views

IoT-Protocol CoAP

CoAP is a lightweight protocol designed for constrained devices and networks. It uses UDP as the underlying transport protocol and defines message formats and types for request-response interactions. CoAP supports reliable transmission of confirmable messages through retransmissions and timeouts. Service discovery in CoAP is done through multicast IP addresses for nodes to broadcast available services and discover other devices on the network.

Uploaded by

Cindy
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 12

Constrained Application Protocol

(CoAP)
MMS
Institut Teknologi Del
Overview
• What is CoAP
• CoAP Message Format
• CoAP Implementation
• Architecture
• URI
• Reliable CoAP Transmission
• Service Discovery
What is CoAP
• Developed by IETF Contrained RESTful
Environments (CoRE) working group
• Generic framework for resource-oriented
application (constrained node and network)
• CoAP framework defines simple and flexible ways
to manipulate sensors and actuators for data or
device management
• RFCs
• RFC 7252 CoAP Protocol
• RFC 6690, 7641, 7959, 8075
CoAP Message format
• CoAP messaging model is to facilitate message
exchange over UDP endpoints
• Use DTLS (Datagram Transport Layer Security) for
message security
2 2 4 8 16 (bits)
Message Types
• Describe the datagram’s message type for the
request and response
• Request
• 0 : Confirmable : This message expects a corresponding
Acknowledgement message.
• 1 : Non-confirmable : This message does not expect a
confirmation message.
• Response
• 2 : Acknowledgement : This message is a response that
acknowledge a confirmable message
• 3 : Reset : This message indicates that it had received a
message but could not process it.
Message Code
• Similar to HTTP code, indicated the request method
and the response status
• REQUEST RESPONSE
• 001 GET 201 Created
• 002 POST 202 Deleted
• 003 PUT 203 Valid
• 004 DELETE 205 Changed
205 Content

• RFC 7252 for complete list


Implementation (Architecture)
URI

coap://172.21.12.12:10000/.well-known/core
coap://californium.eclipse.org:5683/

coaps://localhost:2332/

5683 Default CoAP Port


Reliable CoAP Transmission
• The behavior of UDP protocol introduce risk on CoAP packet loss
• CoAP offer reliable transmission of messages when a CoAP header is marked as
“confirmable” (Types: CON), combined with timeout and retransmission
mechanism
CoAP Service discovery
• IP Multicast is used to broadcast messages to
multiple IoT devices
• Multicast IP 224.0.1.187 (IPv4) FF0X::FD (IPv6)
• Multicast addresses are joined by CoAP nodes offering
service to other endpoints while listening on default
CoAP Port.
• Endpoints can find available CoAP services through
multicast service discovery
• /.well-known/core as entry point relative
URI to list available service on a Node (client,
server)
Summary
• CoAP is a lightweight protocol (similar to HTTP)
designed for constrained devices
• CoAP use UDP as underlying transport protocol
• CoAP use multicast IP as service discovery
mechanism to support large number of nodes

You might also like