O'Reilly logo

Mastering Internet of Things by Peter Waher

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using UDP

CoAP optimizes this drastically, changing two things. First, it uses UDP instead of TCP. In UDP, IP packets, called datagrams, are not acknowledged or ordered as they are in TCP. This means that datagrams can get lost or be received in a different order compared to when they were sent. Such considerations must be handled by CoAP implementations. While CoAP manages acknowledgements also, it is optional. This means that the application has the option of using the unacknowledged service when sending data. This saves a lot of network traffic, especially in cases where loss of datagrams is acceptable.

This is typically the case, for instance, with sensors measuring analog ambient values that regularly report their status. If a value ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required