Keywords

1 Introduction

The Internet of Things (IoT) is a transformative development [1,2,3]. From its starting, the Internet was a network of networks, associating different government and academic PCs together to share information. What has changed progressively in the course of recent decades is the capacity to interface remote and versatile “things” or “machines” or “resources” to the Internet or corporate Intranets using remote interchanges and low-cost sensors or computers or storage. The confluence of productive remote protocols, enhanced sensors, less costly processors, and varied new businesses and built-up organizations build up the very important administration and application programming has at long last created the concept of the IoT standard [4,5,6]. IoT is an open and intensive system of clever things that have the capability to auto-sort out, offer data, information, and assets responding and acting in face of circumstances and changes in the earth [7, 8].

We can allude IoT as developing the present Internet and giving association, communication, and between systems administration amongst gadgets and physical items, or Things [9]. The IoT worldview remains for all intents and purposes interconnected items that are identifiable and furnished with sensing, computing, and correspondence capacities. The IoT paradigm indicates the pervasive and omnipresent interconnection of billions of installed gadgets that can be interestingly recognized, confined, and conveyed [10]. The IoT is a recent correspondence worldview that imagines a not thus distant future, in every the ventures of normal life are going to be supplied with microcontrollers, handsets for computerized correspondence, and acceptable convention stack that may create them able to speak with one another and with the clients, turning into a basic part of the Web [11]. The new idea of the IoT brings an open door for the production of creative applications that coordinate the very well-known conventional computerized advances. IoT is about interfacing these self-governing gadgets to communicate without human mediation and produce incorporated information. The IoT is the thing that happens when regular normal items have interconnected microchips inside them. These microchips help monitor different items, as well as a hefty portion of these gadgets sense their encompassing and report it to different machines and in addition to the people [12].

The IoT is regards as a technology and economic wave of information industry after internet. The IoT is an astute system which interfaces all things to the Web with the end goal of trading data and conveying through the data-detecting gadgets in accordance with agreed protocols. It is associated with extension and enlargement of internet-based network, that expands the communication from human to human (H2H), human to machine (H2M) and machine to human (M2H) [13, 14]. The IoT is made up of hardware and software technologies. The equipment comprises of the associated gadgets which range from basic sensors to cell phones and wearable gadgets and the networks that connects them, for example, 4G Long-Term Evolution, WiFi, and Bluetooth. Software part incorporate information storage platforms and examination programs that present data to users [15,16,17,18].

2 Tools in IoT

IoT covers a colossal range of industries nowadays and use cases that scale from a solitary compelled gadget up to gigantic cross-stage deployments of inserted innovations and cloud frameworks interfacing continuously. IoT contains various protocols at various levels like infrastructure layer contains protocols like 6LowPAN (IPv6 over Low power Wireless Personal Area Networks), RPL (Routing Protocol for Low-Power and Lossy Networks), IPv6, identification layer contains EPC, uCODE, URIs, Transport layer contains Wifi, Bluetooth, LPWAN, Data Protocols contains MQTT, CoAP, AMQP, Node [2, 19, 20]. IoT contains various operating systems like Contiki OS, Tiny OS, Mantis OS, RIOT [21].

Contiki [22] is an open source, exceedingly compact, multi-entrusting working system for memory-productive networked implanted systems and remote sensor networks. Contiki has been utilized is an assortment of projects, for example, road tunnel fire monitoring, interruption discovery, wildlife monitoring, and in reconnaissance networks. Contiki is designed for microcontrollers with less amount of memory. A typical Contiki configuration is 2 kilobytes of RAM and 40 kilobytes of ROM. TinyOS (open source) is BSD-licensed working system intended for low-control remote gadgets those are utilized as a part of sensor systems, ubiquitious registering, individual zone systems, shrewd structures, and brilliant metres. Mantis OS kernel provides services like thread management, communication device management, and input–output device management. The I/O device management service provides a UNIX like uniform interface to the underlying hardware. RIOT is a well-disposed working system organized, memory-compelled systems with an attention on low-control remote Internet of Things. RIOT is a developer friendly. In RIOT OS, we can write programs in C or C++ as we are used to in other OS. It is planned especially to meet prerequisites of IoT which contains low memory impression, high-vitality productivity, ongoing abilities, a secluded and configurable correspondence stack, and backing for an extensive variety of low-power gadgets. RIOT provides a microkernel which comprises thread management, a priority-based scheduler, a powerful API for inter-process communication (IPC), a system timer, and mutexes. RIOT gives features like adaptable memory administration, high determination, IPv6, 6LoWPAN, UDP, RPL, CoAP, the local port permits to run RIOT as-is on Linux, BSD, and MacOS [19]. Various occurrences of RIOT running on a solitary machine can likewise be interconnected by means of a straightforward virtual Ethernet bridge.

3 Contiki OS

Contiki [18] is an open source sensor node operating system having event driven kernel. It gives dynamic loading and emptying of projects and services. Contiki is an OS similar to Microsoft Windows and Linux, except for a awfully purpose and primarily centred on things within IoT. The goal of Contiki is to satisfy requirements of the smallest devices such as smart dust. Things ought to be ready to communicate a few bits of data to one another. Contiki is an open source programming venture with the vision to make a moderate and working OS for wide deployment. Contiki gives intense low-control Internet communication. Contiki underpins completely standard IPv6 and IPv4, alongside the late low-control remote norms: 6lowpan, RPL, CoAP. With Contiki’s ContikiMAC and sleepy routers, even wireless routers will be battery operated. Contiki applications are written in standard C, with the Cooja simulator. Contiki can be unreservedly utilized both as a part of business and non-business systems. Contiki is intended to keep running in little measures of memory. A regular system with full IPv6, organizing with sleepy routers and RPL routing needs under 10 kilobytes of RAM and 30 kilobytes of ROM. Contiki OS offers numerous features. It is intended for small systems, having just a couple of kilobytes of memory accessible. Contiki is along these lines exceedingly memory proficient and gives a set of mechanisms for memory distribution. It gives a full IP network stack, with standard IP protocols, for example, UDP, TCP, and HTTP, notwithstanding the extraordinary failure power benchmarks like 6lowpan, RPL, and CoAP. Contiki underpins dynamic loading and connecting of modules at run-time.

4 Border Router in Contiki OS

Here, we will see how Border router gets connected to the internet. The border router is used to interface IP network with an RPL 6LoWPAN network. Webservers tries the border router to connect to the Internet sky motes. Before that we will discuss about mote. The node of IOT where wireless transceivers are combined with sensors is known as mote. Every mote consists of an address in order to uniquely identify it and also to find it. System that manages the address ability of the motes is called Identity of Things.

Here, we will use InstantContiki 2.7 simulator.Footnote 1 First open cooja in InstantContiki simulator and create new simulation as shown in Fig. 1 and name it.

Fig. 1.
figure 1

Create new simulation interface

In second step, create a sky mote as shown in Fig. 2.

Fig. 2.
figure 2

Creation of sky mote

Fig. 3.
figure 3

Network window

In third step, browse and follow the path /home/user/contiki/examples /ipv6/rpl-border-router/border-router.c. Now compile it and after it gets compiled, click on create. It will contain only one border router, so create 1 mote (Figs. 3, 4, 5 and 6).

Green colour around the border mote indicates that all the motes within that region have good radio coverage and the motes within the grey colour indicate that motes do not have that good radio coverage and beyond grey colour region motes are not connected to each other. Create more sky motes but this time it will be motes which will have Websense that will connect border mote to the Internet. So to create more motes, create sky motes from motes option. Browse and follow the path /home/user/contiki/examples/ipv6/sky- websense/ sky-websense.sky. Compile and create it.

Now we will place 3 motes in green region and 2 motes in grey region. Select mote type from view option to differentiate the motes. Open radio messages from tools. It will show what happens to radio messages. Right click on border mote and select serial socket from mote tools for Sky 1. It will monitor serial socket for border router. Now in order to start the simulation follow the steps as mentioned further. Open new terminal and type the following commands.

  1. 1.

    cd

  2. 2.

    cd contiki-2.7/examples/ipv6/rpl-border-router

  3. 3.

    Make connect-router-cooja

  4. 4.

    Press enter and it will ask for password which is user itself

  5. 5.

    Now what you will see is tun slip. It is one type of protocol which is used to capture the routing packets and it will aslo show the ip address and all in detail in terminal. Now move to the created simulation and start the simulation from the simulation control window.

Fig. 4.
figure 4

Addition of sky mote

We will see the outputs in each window. Now again move to the terminal and we will see the server ipv6 address. Now to check whether the Web server is working or not, copy the first address which will be like aaaa::212:7401:1:101. Open browser and write http://[ aaaa::212:7401:1:101]. And we will get output as the ipv6 address of neighbour motes and routes of motes.

Fig. 5.
figure 5

Route status, as visible to the border router

Fig. 6.
figure 6

Mote readings

Now when we will write address of other motes, i.e. [aaaa::212:7402:2:202], we will get output as shown in figure. It shows light and temperature at that mote.

Similarly, we can check the light and temperature of every mote in internet. Thus in simple terms, we can call this example as gateway, i.e. gateway connected to the internet.

5 Conclusions

In this paper, we discussed about IOT and its impact in our life in brief, all the tools and OS that are available in IOT like Contiki OS, Tiny OS. IOT contains several technologies like communication technology and low-power electronics. The development in IoT brought many new challenges including unclear architecture, immature standards, and lack of fundamental theory. We saw about Contiki OS and how we can use cooja simulator. Contiki gives a full IP network stack, with standard IP protocols, for example, UDP, TCP, and HTTP. We saw example of border router which saws how we can connect all the border mote and other sky mote with each other through internet. An interesting future add-on to the simulator may be a additional advanced radio medium.