Categories
Technology

LPWAN, LoRaWAN, NB-IoT: An introduction. Plain and simple


“I see people”

Once upon a time there was the simple Internet and it was designed for people to exchange content with each other. Since it was implied that this Internet of People (IoP) was for obviously for people, it was simply known as the Internet.

“People; meet Things”

Then came the Things. Smart devices, sensors and what not! Apparently, some smart people deemed that the Things should start communicating on their own too. This led to the birth of the Internet of Things (IoT).Programmable Things. An introduction. Plain and simple

“People-talk vs Things-speak”

Now the way people communicate is way different from the way things do. We, the people, for instance, love to do video chats, post our selfies, watch hours of cat memes and endless streams of text messages interspersed with smileys and weird acronyms. It would be surprising to know how much of this stuff moves around in a single internet minute! (Well, mostly not so useful stuff). This is akin to time itself being compressed and decompressed at a colossal scale.

What Happens in an Internet Minute in 2019?Did you know that a majority of the global population doesn’t have access to quality financial assets? In advanced…www.visualcapitalist.com

But Things communicate pretty crisply and in a business-like fashion. A smart thermometer may simply wake up and say “33°C” and go to sleep! They (usually) have no business chatting about the cute cat next door and so they simply don’t. A smart bulb may only need to hear “1” and it would turn itself on or vice-versa. The attempt here was not to outline exactly what language they communicated in or its semantics or its layers, but to generally give you an idea that their messages are usually infrequent, crisp and involve no crap.

There are of course exceptions. A smart video camera may need to transmit a live video feed, which is neither infrequent nor crisp; but most other sensors and actuators may very well tolerate low bandwidth and latency.

If you had read the first link in this article, you would realize that in many applications, it is necessary to have battery powered devices that last for a very long time (many years!). Also, in many applications, it is desirable to have battery powered devices that transmit/ receive wirelessly across long distances (many miles!).

“Enter: LP-WAN”

Therefore, LP-WAN; which simply stands for Low Power, Wide Area Network. This does exactly what it says. It is a generic term used to define technology blocks that allow low powered end-nodes/ devices to communicate with each other or to a set of central servers, over a large geographic area (aka Wide Area Network or WAN)

LP-WAN stacks are usually narrow band, support low bit-rates and may restrict throughput.

We will now take a few small detours to understand a few concepts better. You could skip them if you so wish.

a. What is narrow-band?

How does bandwidth figure into all this? Lets explore this aspect a bit. Any electromagnetic signal could essentially be approximated to be/ mathematically represented as an infinite set of sine waves. These waves will have different frequencies (f1, f2, f3… fn) and different amplitudes. There would be a few dominant waves (say fd1, fd2, fd3… fdn) and a few non-dominant ones (say fnd1, fnd2, fnd3…fndn). If that signal is being transmitted from one end of a medium, for it to be reproduced with reasonable fidelity at the other end, we would need most of the dominant and as many of the non-dominant frequency waves to reach the other end. The bandwidth available for the medium is the difference between the minimum frequency and the maximum frequency signals (fmax-fmin) that could be propagated through it without being significantly attenuated (dying out). The bandwidth is also dependent on the frequency band because different media have different conduction properties for different frequency ranges.

simplistic representation of a narrow-band medium

A narrow band therefore implies a medium (or an artificial constraint placed on the medium) where the difference between the highest and lowest frequency of signals that could be propagated through it is very small, say a few 100 kilohertz.

b. What is modulation?

In simple terms, it is the method of wrapping one signal up within a different signal envelop in such a way that it could fulfill a signal condition that is more suitable for the medium being used and also such that it would be possible to deconstruct this at the receiving and and retrieve the original signal (demodulation).

One such modulation technique is amplitude modulation where a lower frequency signal is essentially used as a cookie cutter on a higher frequency (carrier) wave.
amplitude(signalOut) = fn(amplitude(signalIn))
frequency(signalOut) = Kf. Where Kf >>f(signalIn)

Another modulation technique is frequency modulation where the amplitude of the lower frequency signal is converted into a corresponding signal frequency in a higher frequency range.
frequency(signalOut) = fn(amplitude(signalIn))
amplitude(signalOut) = Ka

Amplitude and Frequency Modulation. Source: Wikipedia

Modulation therefore helps one ensure that the signals generated by our sensors could be packed into the band and bandwidth constraints imposed by the air interface regulations.

c. Who owns the air interface?

The electromagnetic spectrum (or rather the radio and microwave part of it) is considered a sovereign subject. That is, something owned/ regulated very strictly by the state. This is because the available bandwidth is limited and there are multiple applications available and entities vying for a favorable band.

Radio spectrum. Source: Wikipedia

Simply put, two signals within the same bandwidth will have elements (constituent signal waves at particular frequencies) that will interfere (add up or cancel) with each other. Such an interference will result in a significant attenuation or amplification of constituent signals resulting in corruption of the overall signal being transmitted. Our governments therefore decided that it is better for them to own the bandwidth and only selectively permit chunks of it for different uses and different users. A good portion of the spectrum is reserved for the defense forces. Some for television signals. Some for mobile telephony and so on.

Also, the atmospheric and geographic constitution of the wave-path favor certain frequency ranges over others for the distances involved. Chunks of spectrum, being a scarce resource, are usually auctioned out to the highest bidder. Especially for mobile telephony (remember the 2G spectrum case?)

d. ISM band?

There have been numerous applications of wireless/ radio technology in transmission of sensor signals, especially over short distances. Thankfully, certain frequency bands have been kept out of strict government licensing norms as long as they follow certain protocols. These are called the Industrial and Scientific Measurement, ISM bands. There are some LPWAN technologies that work in the ISM band and there are some which work in the commercial licensed bands.

While the ISM band is pretty restrictive, the fact that it is unlicensed means that one could easily use it based on readily available tools and platforms and that generally, it would cost less to send a packet over an ISM band than its counterpart (because there, every packet essentially bears some tiny fraction of the licensing cost). On the flip side the licensed bands are usually better placed for more bandwidth or throughput intensive applications.

e. WAN?

WAN is the good ‘ol Wide Area Network. So this is a term used to represent a network that is bigger than a typical LAN (Local Area Network) as found in a typical office space, spanning multiple square kilometers in geographic area and usually plumbed through a set of gateways (that convert a packet received over the incoming protocols like LP-WAN into standard internet packets).

“Introducing: LoRaWAN”

LoRaWAN simply stands for Long Range Wide Area Network. It is an LP-WAN technology that was developed on top of an innovative physical layer radio solution by a company named Semtech Corporation. It is actually a protocol/ a network stack that operates on top of LoRa as a (physical layer) modulation protocol. (So, yes LoRa modulation could also be used independently for long range point to point communication without a WAN protocol on top of it).

LoRaWAN functions within the ISM bands and therefore the operating band varies depending on the geographic region the solution is intended to operate in. Check them out here. What LoRa provides is really great range for tiny battery powered nodes. We are talking here about 10 Km line of sight range from something similar to a pair of AA cells that will last across their nominal shelf life (a couple of years at max). This is because of the way the LoRa chip pretty much ‘sleeps’ all the time at low power (think micro ampere) and wakes up only to transmit and then execute a synchronized receive at a few milli amperes of current for a few milli seconds.

Its resiliency is also because of its unique modulation technique that enables it to work even at signal to noise ratio levels of the order of -130dbm! Its modulation technique is called Chirp Modulation. Here’s how chirp modulation works. For a digital signal, we are essentially sending a pattern of binary signals (0 or 1). Imagine for a 1, we send a radio signal that increases from f0 to f1 and for a 0 we send a wireless signal that decreases from f3 to f2.

Play around with these online audio chirp generators and then imagine the same for radio 🙂 Then imagine that happening real fast and in a sequence (upward chirp or a downward chirp) according to the sequence of bits being transmitted.

Custom Chirp and Sweep Tones | Audio Test File GeneratorOur waveform generators deliver accurately calibrated sound files, with adjustable frequency and amplitude.

www.audiocheck.net

Now a chirp modulation is a fundamentally more robust because it is an application of what is called spread spectrum modulation. By spreading a single state (0 or 1) across a linear range of frequencies, we have made the signal a lot more resilient to noise because at the receiving end, it is easier to detect a general sweep occurring compared to detecting just the occurrence of an absolute frequency.

Now, wider the chirp spread (f1-f0), the wider is the bandwidth it needs (while still being narrow-band) and better is its ability to be detected in noisy environments or larger distances. This is where LoRaWAN has another neat trick up its sleeve, which is that it can smartly adapt the chirp spread depending on what it deems to be appropriate based on its previous signal communication history with a particular node.

In addition, depending on the bandwidth available in each region, the protocol employs multiple channels (each channel corresponding to chirp frequency band) with channel hopping as well to support multiple devices communicating at the same time.

However, it must be said that LoRaWAN is generally a non-ack based protocol. That is, unless explicitly designed to do otherwise, its nodes just transmit a packet (uplink) and hope that it reaches atleast one gateway in its vicinity. There is usually a packet counter implemented on both the node and the gateway and/ or the application that could be used to figure out if any packets were dropped.

And more interestingly, the packets are encrypted using multiple keys and AES. This enables secure communications. So even a gateway in its path cannot see the packet data being transmitted as long as it does not have the network key and the application key.

All in all, LoRaWAN is able to achieve really impressive feats like this one:
Ground breaking world record! LoRaWAN packet received at 702 km (436 miles) distanceWith the rise of novel wireless technologies, we surprise ourselves over and over again of what these technologies are…www.thethingsnetwork.org

Or this one for space communication! :
At 71,572 KM, You Won’t Beat This LoRa RecordA distance record for LoRa transmission has been set that you probably won’t be able to beat. Pack up your gear and go…hackaday.com

Here is the more interesting part, since it uses the ISM band, you could go ahead a create your own networks, gateways and nodes if you wish! The best place on the web to get started on this is to sign up on The Things Network (below).
The Things NetworkThe Things Network landing pagewww.thethingsnetwork.org

You could use the coverage map there to first check if there is already any community powered gateway in your city/ vicinity. If not, you could buy a reasonably cheap gateway, configure it and add it to the open network (highly recommended!). Once you have a gateway, you could simply add your own nodes. Here again, you could either design your own nodes (based on Semtech chips/ SoCs) or use readily available nodes which you just have to add your sensors, your code and credentials to configure and get started.

In India, there are a few private players as well who are providing a LoRaWAN network (Tata Communications and SenRa). At Tinkerbee Innovations we have tested these integrations and have our custom designed tiny LoRaWAN boards that can be configured for a variety of end-use applications.

One of our tiny mighty LoRaWAN end-nodes

“Ok, but whats NB-IoT?”

If you recall, we mentioned that some part of the radio spectrum was licensed by telecom operators? Mostly for voice, SMS and internet and mostly for people communications? True, there also existed a category of applications called M2M, or machine to machine for certain machines to send data over GSM/ GPRS networks through a SIM embedded on the end-node. Well, for one, this network was not kinda optimized for the small packet sensor data or for power efficiency. Most of the sensor nodes therefore in the earlier gen required constant power supply or frequent charging (every few hours/ days), but thankfully, due to the relatively wide coverage of the telecom networks, it gave the sensors more ubiquity.

Sensing an opportunity in the IoT aka Things communication space, the 3G telecom providers (3GPP) embarked on a brand new architecture that rode over existing LTE infra, but was designed to use a narrower bandwidth and optimized for extremely low power usage by end nodes. This was christened as NB-IoT or Narrow band IoT. with NB-IoT, the end-nodes could match LoRaWAN in terms of battery life but still would not match the LoRa performance or range (which is kinda offset by the already ubiquitous presence of cellular towers) or its price point. The per node one-time cost and the recurring subscription costs are now on the higher side. However, being backed up by relatively strong and established telecom operators, it may be a matter of time and scale when it could very well be a match. That said, NB-IoT would inherently also be able to support higher bandwidth sensors like camera and OTA (Over The Air) updates pretty much out of the box.

In India Airtel and Reliance have embarked on ambitious NB-IoT programs, but they are yet to have a widely available or open platform for third-party developers to test and play around with.

One of the most anticipated chip/ SoC releases for NB-IoT this year was Nordic Semiconductor’s 91 series, esp. nrf9160 SIP.Low power cellular IoT – Nordic SemiconductorNordic offers an unparalleled choice for LPWAN IoT connectivity over 4G cellular networks with their compact…www.nordicsemi.com

We also have the Quectel BC95 as a nice contender.Quectel LTE BC95 NB-IoT ModuleBC95 is a high-performance NB-IoT module with extremely low power consumption. The ultra-compact 23.6mm × 19.9mm ×…www.quectel.com

Also available are the SIMMCOM’s SIM 7000 and 7600 series. And many more.

“OK. Who wins?”

Honestly, it is too early to tell. As I see it, there is perhaps room for multiple LP-WAN protocols to co-exist and find their niches in various applications. True, they would compete on many fronts, but each has some clear pros and cons, at least as of now. Of course, technology evolves at such a fast pace that pretty soon we’d be talking about these technologies in past tense 🙂

But until then, it is clear that NB-IoT is poised to change the way Things communicate and this will add value to the way we humans interact with the world around us.

At Tinkerbee Innovations, our endeavor is to use sensors, IoT, LP-WAN, ML and Analytics to build solutions that #maximizeYourLife and we have only just begun! In case you are interested to explore this new world with us, do write in to info@tinkerbee.in

We welcome your views and suggestions and hope that this post was an informative starter: A plain and simple introduction to LP-WAN, LoRaWAN and NB-IoT.

PS: If you are a maker and would like to work with us, do check out our AngelList page

Categories
Technology

Bluetooth Low Energy devices

TinkerBee has developed capabilities around Nordic Semiconductor‘s BLE enabled SoCs in nRF51 series.

We’ve played around with the powerful nRF51822 module and used the ARM mbed platform to develop one of our earliest (and may we say- revolutionary) products called EyeBee. Well, more on that soon.

It is an awesome board designed by us, powered by a CR2030 button cell and sized slightly larger than a one rupee coin. It also comes with an Android app that auto-syncs with the device.

PS: If you are a maker and would like to work with us, do check out our AngelList page

Categories
Technology

WiFi devices

Over the years WiFi has become so prevalent that a hotspot or an access point is the first thing we look for when we reach a location!

Ever since Expressif launched an extremely versatile and low-cost chip that combined a microcontroller and a WiFi module into a single unit called the ESP-8266, there has been an explosion of services using/ built upon the WiFi protocol.

Some of the earliest prototypes of our StockBees were built using ESP-12F modules (that use the ESP-8266).

We love these cute little boards designed by us, that expose an SPI/ I2C bus connector, an 18650 LiPo cell charger, a buzzer for audio feedback and a few switches thrown in. A guitar pick next to it for size comparison.

PS: If you are a maker and would like to work with us, do check out our AngelList page