Amazing technological breakthrough possible @S-Logix

Office Address

  • #5, First Floor, 4th Street Dr. Subbarayan Nagar Kodambakkam, Chennai-600 024 Landmark : Samiyar Madam
  • +91- 81240 01111

Social List

How to run DTLS for CoAP in Contiki Cooja simulator?

 Execute DTLS for CoAP in Contiki Cooja simulator

Executing the DTLS for CoAP in Contiki Cooja simulator


   Datagram Transport Layer Security (DTLS) is a transport layer protocol providing security to datagram-based applications of CoAP. DTLS is a protocol designed to to prevent eavesdropping, tampering, or message forgery during the communication.


  Open file menu on cooja and create new simulation with random seeding.

  it will auto-generate the seeds for every time reload the simulation.

  File -new simulation (or) (ctrl+ n).

  click -New random seed on reload option.

  click -Create .

  File -new simulation (or) (ctrl+ n)

  After click the create option number of tabs will appear in terminal it is basic necessary to simulate applications.

  Open motes menu >> add motes >> create new motes type >> sky

  Three files are necessary to run CoAP applications. In order to create the motes,

  i. border- router.

  ii. er-example-server.c

  iii. er-example-client.c

Run CoAP applications

  To create border router motes


  Choose the file in location >> compile >> create >> Add motes.

 create border router motes

  To create server motes.


  Choose a file location >> compile>> create >> choose sever

  count(optional)>> Add motes.


create server motes

  To create client motes .


  Choose a file in location >> compile >> create >> choose client

  count(optional) >> Add motes.

 create client motes .

Now connect the serial socket server in border router.

In cooja, network terminal .. View menu -choose the options you want,

For example: mote Type, mote ID’s, radio traffic, ...

Left click on border router motes >> choose: mote tools for sky1 >> serial socket(SERVER).

New tab will appear click : start -> now the default port will listen.

open one more command terminal and set directories to this location:

Cd contiki/ examples/ ipv6/ rpl-border-router/

Make connect-router-cooja the server will be connected to router.

Connect the serial socket server in border router