Super powerful apps: PWA + IoT (WoT)
This article describes two technologies that significantly boosted the power of the web in the last few years. Providing Progressive Web Apps for IoT (Internet of Things) devices could be a huge step forward for real-world applications. Nowadays, web applications are not the only apps running on a desktop by a web browser. Browser-based applications should work (and look good) across all modern browsers, independently of the device (e.g., mobile, tablet as well as TV and smartwatch).
Progressive Web Apps are the way to users’ hearts ❤
The idea of PWA is to enhance a web application progressively and give immers. Our app should be fast, user engaging and connection-independent (e.g., should works Offline). Progressive Web Apps provide a new approach for developers. The mobile-first strategy goes out of date. The progressive concept refers to taking advantages of capabilities that are available in the application environment.
-Web USB API (The WebUSB API allows Web applications to interact with the Universal Serial Bus-compatible devices available in the system),
-Web RTC API (Web Real-Time Communication is a technology which enables Web applications and sites to capture and optionally stream audio or video media, as well as to exchange arbitrary data between browsers without requiring an intermediary),
-WEB NFC API (Near Field Communication enables wireless communication between two devices at close proximity).
These examples are pretty crucial for the Internet of Things technology.
Let’s talk about the Internet of Things
In IEEE’s report on the Internet of Things issued in March 2014 (IEEE, “Internet of Things”, 2014), IEEE described the term “ Internet of Things” as :
A network of items- each embedded with sensors- which are connected to the Internet.
The architecture of IoT is three-tiered, with the following layers: applications, networking and data communication, sensing. My concept is to use Progressive Web Apps in the “Applications” layer. The ability for PWA to be run from a uniform resource locator (URL) makes it easy to use the application on any device with a modern browser.
IoT is an application domain that integrates different technological and social fields. The potential of IoT is enormous. IoT devices can be used in various markets, for instance: healthcare, energy, media. Because of that, there is also a need to control these devices remotely and develop apps to do this.
Let’s focus on the problems of IoT and try to find solutions with PWA. For me, essential issues are:
1) getting devices connected to the network,
2) different tools to create apps for various devices (needs the universal solution),
3) no unique and universal application protocol.
One of the fundamental features of Progressive Web App is connectivity-independence. Service worker is a kind of a web worker, that is registered with the first app running in the browser and works independently of the app. This PWA standard allows application work even in the Offline state. After successful Service Worker registration process, the app will work in the device’s web browser. Machines don’t require connectivity to the network. For example, we have an app to monitor the temperature in the home. This app should present our data even if we don’t have access to the Internet or we can’t connect to the device with the temperature sensor. PWAs allow cache and synchronize some data. If we are in the Offline state, an app will work and will return the latest cached data. That is the magic of PWA.
A primary need for IoT is to find a single universal application layer protocol for devices and applications to connect with each other. It doesn’t matter how they are connected. The limitation of the IoT becomes visible as soon as one wants to integrate devices from different manufacturers into a single system or application. Maybe we can use the Web itself? Let’s reuse something that is already used for building scalable and interactive applications. This is what the Web of Things is all about: reuse and leverage readily available and widely popular Web protocols, standards and blueprints to make data and services offered by objects more accessible to a larger pool of (Web) developers.
In the Web of Things, devices and their services are fully integrated in the Web because they use the same standards and techniques as traditional Web sites. This means that you can write applications that interact with embedded devices in exactly the same way as you would interact with any other Web service that uses Web APIs.
- Applying PWA to IoT devices is an immensely exciting topic. Combination of these technologies allows creating apps to connect and control various devices.
- The Web is powerful. This technology makes developers happy because of the possibility to easy creating different kinds of app.
- The Web of Things — a technology that needs some love and care. That could be a simple solution for lack of unique and universal application protocol in the IoT.
- Browsers compatibility and standardization are obstacles for web developers. PWA and IoT are relatively new technologies and need time to evolve.
★ http://pwa-detector.firebaseapp.com — My application to detect browser compatibility for Progressive Web App (PWA) and Internet of Things (IoT) features. Developed to test browser support on different devices and browsers.
✔Check it out!