Sofia2 participates in the SESIAD Virtual Laboratory

labVirtual

 

The Virtual Laboratory of the Secretary of State for the Information Society and Digital Agenda (SESIAD) was born under the standard UNE 178104 “Integrated management systems of the smart city” with the aim of becoming a benchmark for national and international platforms, being a place of experimentation in which companies and developers can evaluate the compatibility of their products with different Smart Cities platforms.

 

labVirtual

 

Currently, platforms that participate in the Virtual Laboratory are Sofia2, from Minsait by Indra, SmartBrain from Cellnex and Thinking City from Telefónica. They collaborate with SESIAD contributing their expertise and participating in the improvement of interoperability between platforms.

 

plataformas

 

As we saw in IoT Data Models: Initiatives and Sofia2 Data Model, there are different Initiatives of standardization of a Data Model in IoT. A Data Model represents the structure of your data and relationships, and therefore, organizes the elements and standardizes how they relate to each other.

 

gsma1

 

GSMA and FIWARE Data Models are defined in JSON, so their representation as Sofia2’s Ontology is immediate. We saw how they are supported and how easy it is to work with these entities in Sofia2

 

To achieve better interoperability between platforms, NGSI 9/10 v2 was selected as a common protocol for the Interoperability Layer. We saw in this document how they are supported and how to consume APIS modeled according to the semantic FIWARE Data Model and published in Sofia2 following the NGSI 9/10 v2 protocol.

 

In our experience with the Virtual Laboratory, in addition to making recommendations for new attributes and modifications in the Data Model, we had the opportunity to perform a Proof of Concept (PoC) by creating a connection  and transformation flow of real data from Smart City A Coruña to GSMA/FIWARE Data Model on Sofia2’s Platform.

 

In this example, Smart Coruña parking data is collected and is ingested in an Ontology on the Sofia2’s platform. Each time an instance of this ontology is received, a Script is launched and transforms this data adapting them to the Data Model and, consulting them, we see how, effectively, the Data Models are fulfilled.

 

dataingestGSMA

 

Also in this Proof of Concept we could publish this data through the API MANAGER of Sofia2 to later see that anyone with the proper permits can access this data via API, Curl or through the Virtual Laboratory portal.

 

consumptionGSMA

 

 

All this process is explained in the post Acquisition, transformation and consumption of data with GSMA/FIWARE Data Model, and has been captured in the demonstrator, which, in addition to parking data, collects data from beaches and museums.

 

demostrador

 

You can find all the information related to the SESIAD Virtual Laboratory here, as well as all the necessary tools (Data Model, APIs, Security tokens, examples …) to develop on the platforms complying with this interoperability model here

 

 

 

 

Sofia2 participates in the SESIAD Virtual Laboratory

Beijing Institute of Technology (BIT) meets Sofia2

IMG_20180123_153430862

 

In the context of “Winter School”, the collaboration framework between Polytechnic University of Madrid (UPM) and Beijing Institute of Technology (BIT), students from BIT visited Indra’s facilities in Madrid. Different Indra’s technological solutions were presented, highlighting the IoT approach based on Minsait IoT Sofia2 platform.

 

IoTVision

 

Sebastián Gómez, Business Development manager and Ayla Ruiz, platform consultant, introduced Sofia2 to the students, explaining its origin, present and future, as well as its main characteristics and capabilities.

 

IMG_20180123_153430862

 

They also presented the different types of projects where Sofia2 can be applied. They got help from Mario Briceño and Lucía Fernandez, IoT engineers, to explain practical examples and some of the different solutions that use Sofia2 as a technological base.

 

IMG_20180123_160417

 

BIT students showed great interest in creating their own projects using  CloudLabthe Sofia2’s experimentation environment.

See you soon!!

Beijing Institute of Technology (BIT) meets Sofia2

Acquisition, transformation and consumption of data with GSMA/FIWARE Data Model

dataingestGSMA

 

In the post How to work with Data Model FIWARE/GSMA in Sofia2 we saw how the Sofia2 platform supports the GSMA and FIWARE Data Models. We learned how to create Ontologies according to these models and how to insert data and consult them using the tool available on the BDTR and BDH Console. We also saw how to publish this Ontology as a RESTFul API and how to consume the API.

 

In addition, we have the document Use of FIWARE Data Model and API NGSI9 publication, where we explain how to consume APIS modeled conformant FIWARE Data Model semantics and published in the Platform following the NGSI-9 protocol.

 

For the example, we use the Ontologies:

  • GSMA_OffStreetParking_Destino
  • GSMA_PointOfInterest_Beach
  • GSMA_PointOfInterest_Museum

 

Step by step we explains how to subscribe to these Ontologies, how to consult your Data through the BDTR and BDH Console, how to subscribe to NGSI-9 APIs and consume them through the API Manager developer portal and how to access these APIs via Curl.

 

consumptionGSMA

 

With all this information, and knowing that Sofia2 allows you to create Rules Scripts (it is advisable to read the Scripting Engine Sofia2 User Guide) that will be executed before the arrival of instances of Ontologies or every so often, it is easy to understand how we can receive data with a determined structure and transform them to meet these Data Models.

 

We will check it through the following flow:

 

dataingestGSMA

 

In this example, Smart Coruña car park data is collected, an Ontology is ingested on the Sofia2 platform, each time an instance of this ontology is received, a Script is launched that transforms this data adapting it to the Data Model and consulting it, we see as indeed, it is fulfilled with the GSMA and FIWARE Data Models.

 

ejemploparking1

Acquisition, transformation and consumption of data with GSMA/FIWARE Data Model

Client Code Generation in Test&Doc APIs

54

This new utility consists of a client code editor for the APIs of the Ontologies in the most popular programming languages, in this way we will only have to copy the code that it generates and insert it in our applications.

For this we must access the API of the Ontology that we want to invoke. In this example, it will be “APARCAMIENTOSPUBLICOSMADRIDES “. So we will access the “API MANAGER” menu, and the “APIs” submenu:

Image 001

Once here, we go to “My Subscriptions” tab:Image 004

We choose the API that we want to test. And click on the “Test & Doc” button:Image 007

Here we have information about the API and the functions it exposes for its consumption. We are going to choose the “getAll” function:

Image 010

Next we are shown the information referring to that function, and on the right part a drop-down menu called “API Invocation” will appear, in which we will choose the language we want to use to invoke the function:

Image 013

And this will generate the piece of code needed to invoke the function. We will only have to complete this code using the logged user’s token in the “x-sofia2-apikey” part:

Image 016

I have created a sample page in HTML using JQuery, to insert the code that generates us for the API method, the HTML code used for the example would be:

<code>

<!DOCTYPE html>
<html>

<head>
<meta charset=”UTF-8″>
<title>Test API</title>
http://code.jquery.com/jquery-2.2.3.min.js

$(document).ready(function() {
$(“#myButton”).click(function() {

var settings = {
“async”: true,
“crossDomain”: true,
“url”: “https://sofia2.com/sib-api/api/v1/aparcamientospublicosmadrides/getAll&#8221;,
“method”: “GET”,
“headers”: {
“x-sofia2-apikey”: “********************”
}
}

$.ajax(settings).done(function (response) {
console.log(response);
var num = response.data.length;
$(“#helloWorldDiv”).html(“Request URL: https://sofia2.com/sib-api/api/v1/aparcamientospublicosmadrides/getAll
Num Result: ” + num);

});

});
});

</head>

<body>
<button id=”myButton”>Test API</button>
</br>
</br>

</body>

</html>

</code>

result could be something like this:

Image 028

Client Code Generation in Test&Doc APIs

Integration of Lora and Sofia2

The communication between Lora and Sofia2 is done through the Multitech kit, formed by a test node that simulates the transmissions between a Lora device and a Gateway. This Gateway is needed to communicate this type of devices within the network and to send the captured data.

Kit
Used Multiconnect Conduit Kit.

Before the integration in Sofia2, the configuration between the Gateway and the test node is needed. In this brief tutorial, the steps to develop both configurations are collected, as well as all the information needed in Sofia2 to receive and store the data sent by Lora.

Configuration of Lora technology

  • Gateway configuration

    In order to use the gateway without any connection problem, an initial configuration is needed. First access to the Gateway must be done by means of serial communication, though Putty or another similar tool. Credentials needed to access by console are admin/admin. We can get its IP address with the command ifconfig. Once the IP address is known, we use the explorer to access to the Multitech webpage, where we introduce the same credentials again.

    Acceso web al gateway
    Access to the gateway webpage

    Once we start the session, and only by the first time that we do it, we will find an assistant that requires us to change the password, to select the timezone and to configure the IP address. When the last window appears, we must to configure the static IP, to select the corresponding Gateway, and to add the DNS servers.

    Once we finish the IP configuration, we will configurate Lora. To do that, we have to access to Setup -> Lora. Then, we will see a screen where we will see some configurable fields. Anyway, we only need to modify Name and Passphrases.

    Web
    Lora configuration
  • Node-Red configuration

    Once we activate the Node-Red application, we can access though the “App” menu of the webpage. By default, a program that receives Lora test data and shows them is designed, but we have to modify it in order to send the information to Sofia2. Image shows the final flow diagram, with the option “Sofia2 API WEB encoder” added. This option is uncharged of giving the desired format, adding a header to the send message and an output HTTP.

    Node-Red
    Node-Red diagram
  •  Configuration of test node

    To configurate the parameters of the test node is really simple. We only have to connect the mDot to the PC, by means of a USB, and to connect it to the test node with the kit programming cable. Then, we select the “Configuration” option in the mDot Box and we access to the device by using the Putty serial communication at 115200 baud.

    Tester
    Lora tester

    We only need to configure two parameters, using the following AT commands:

    AT+NI=1,<Name>

    AT+NK=1,<Passphrase>

    AT&W is used to save changes and  AT+Exit to exit the configuration mode.

    <Name> y <Passphrase> fields have to be the same values as used previously in the gateway.

    Configuración del tester
    Test node configuration

    In order to check if the configuration of both devices has been correct, we can do a test with the Node-Red.

Sofia2

Once that the devices have been configured, we have to develop the next steps in Sofia2. We need two new ontologies, an API rest and a rule script to deal with data. This section briefly explains with each of them.

  • Defining new ontologies

    First of all, we have to create an ontology that will receive the data sent by the test node. In this ontology we will insert raw data, without any previously filtering.

    ontologia
    Ontology example with raw data

    As we can see in the previous image, data usually have hexadecimal codifications, undesirable formats or information that needs to be treated before work with it. To do that, we have to create a rule script and a new ontology, where we will insert filtered data with the format required by the data base to correctly store it.

  • API REST

    Once the ontologies are defined, we will create an API REST of type POST, to insert data in the ontology of raw data. To do that, we have to go to the API MANAGER -> APIs, where we will find the option “New API”. There, we write the name of our API, and select the option “Publish Ontology as REST API” and the ontology desired. It is convenient to disable the maximum number of calls per minute, in order to assure that we do not lose information. At the end, we select the “POST” operation and create the API.

    API
    API

    The URL of the “Base Endpoint” field is the one that we have to insert in the Node-Red.

  • Rule script

    Once verified that the data sent directly from the device is correctly inserted in the desired ontology, we must create a script to filter them, extract all possible information and provide them with the corresponding format. To do this, we simply enter Rules-> Wizard New Rules and select the option “Generate rule using a template “. With this type of rules, each time the device sends new data to the ontology, the script will be executed and data will be processed and inserted into the final ontology.

  • Presentation on results

    We can use Sofia2’s visualization tools to show the data we’re storing quickly and easily. To do that, we have to go to the Visualization ->My Gadgets -> New Gadget, where we can select the optimal tool depending on our data. On the basic of measured data from Lora tester, the following representation could be interesting: to drawn the coordinates on a map or Signal to Noise Rate (SNR) along the time.

Mapa
Coordinates shows on a map
SNR
SNR representation.
Integration of Lora and Sofia2

5 IoT trends that will define 2018

(From NetworldWorld)

The Internet of Things (IoT) wasted no time spreading across the world and connecting millions of individuals. In just a few short years, billions of sensors redefined how businesses operated and how people interacted with one another, and that was only the start; one IHS forecast predicts the IoT will grow to reach a staggering 75 billion devices by 2025.

What changes will the IoT bring even sooner, in 2018? Is the phenomenon of an interconnected world a mere fad, or will the trends of the IoT continue to define us for decades to come? These five trends highlight the stunning innovations that may lurk just around the corner, and could be a taste of the world yet to come.

More IoT devices than ever

While IHS and others are predicting massive upticks in the amount of digitally-connected devices over the next decade, it’s likely we won’t need to wait very long. BI Intelligence’s report on the IoT notes that nearly $6 trillion will be spent on IoT solutions in just the next five years, for instance, meaning the rapid proliferation of IoT gadgets has already begun.

As more consumers around the globe purchase smartphones, tablets, and other gadgets which hook them into the web, the expanse of the IoT will only grow ever-greater. Low-power, short-ranged networked devices will be increasingly pushed by companies hoping to cash in on the boom in tech, and millions of more sensors embedded in our world in just a year’s time.

The forthcoming retail shakeup

One of the largest impacts the IoT could have in 2018 is the waves of change it’s bringing to retail. Consumers and business-owners alike have profited greatly off of the increase in sensors and data driven by the IoT, as it allows businesses to better market their products to prospective customers.

Increasingly, tech-savvy companies eager to use new data are investing in sensors-based analytics, which allows them to, among other things, track which areas of their stores are the most trafficked by customers. CBInsight’s report on the IoT’s impact on retail outlines the innovative ways companies are using the IoT to better track their inventory, manage losses from theft, and reach out to customers in new and exciting ways.

Forget Amazon’s coming drone-delivery systems or increased amounts of online shoppers; the boom in embedded-sensor driven retail shopping will by itself single handedly change how customers find and buy their favorite products.

Reshaping healthcare

As more and more patients turn to big data driven healthcare solutions, the IoT also stands to reshape how people access and pay for their healthcare services. An ongoing boom in wearable tech has largely been fueled by its applications to people’s healthcare, such as wearable gadgets’ abilities to monitor your heartrate or stress levels.

As hospitals and clinics face larger amounts of patients who need care, they can turn to networked gadgets which can remind patients when to take their prescriptions, when to exercise, and alerts patients when their blood pressure levels are too high.

New network security challenges

Not all of the forthcoming trends in the IoT are positive; new network security challenges will push IT experts to their limits in 2018 as hackers and other malevolent actors seek to harness the IoT for their own nefarious purposes. One cyberattack in October of 2016 already crippled large swaths of the internet after hackers effectively exploited the IoT to power their attack.

As industrial IoT continues to grow at an explosive rate, vulnerabilities in global internet-infrastructure systems will only grow worse. As more devices become connected to one another, security experts and major businesses will need to move quickly to patch holes in their defenses as malware jumps from one networked device to another.

Greater access to capital

These staggering leaps forward in tech aren’t occurring in vacuum; investors are taking notice of the IoT more so now than ever before, and are ponying up the funds needed for the IoT’s expansion. In 2018, IoT-based ventures will have greater access to startup capital and be taken more seriously in the market.

About 19% of business respondents to one Forrester survey reported using the IoT already, but a staggering 28% also reported that they planned to adopt IoT usage in their business operations in the near future. The utilities, transportation, manufacturing and mining industries are all perched to invest and benefit heavily in the IoT in coming years.

It’s never easy to accurately predict the future, and the true capabilities of the Internet of Things may not yet be realized. As consumers and corporations alike embrace the IoT’s world-changing impact on global commerce and lifestyle, however, it’s hard to imagine the IoT doing anything but growing to new and greater heights in 2018.

5 IoT trends that will define 2018

The Top 8 IoT Trends For 2018

(From Forbes)

A recent study shows about 2/3 of companies are currently utilizing IoT

An IHS survey estimates that there are 20 billion connected devices globally as of this year. Will 2018 be “The Year of IoT”? Not exactly, but the future looks promising and 2018 will show a promising trajectory.

Despite the huge gains in connectivity, the truth is 2018 will be more of a steady (rather than explosive) growth period for the IoT, full of fits and spasms, and everything that goes along with them. It will see lots of investment—lots of growth—and widespread adoption in a few major industries. But it will also see some growing pains—“fragmentation frustration,” potential data breaches, and security issues galore.

Futurum Research

So, will 2018 be an exciting year? Yes—ish. The truth is, we’re right smack in the midst of a revolution—no matter how imperfect it may initially seem. If that isn’t exciting, I don’t know what is. The following are the top eight trends we’ll see in the coming year:

1. The IoT Will Grow: In what might be the most obvious prediction of the decade, the IoT will continue to expand next year, with more and more devices coming online every single day. What isn’t so obvious about this prediction: where that growth will occur. The retail, healthcare, and industrial/supply chain industries will likely see the greatest growth. Forrester Research has predicted the IoT will become “the backbone” of customer value as it continues to grow. It is no surprise that retail is jumping aboard, hoping to harness the power of the IoT to connect with customers, grow their brands, and improve the customer journey in deeply personal ways. But industries like healthcare and supply are not far behind. They’re using the technology to connect with patients via wearable devices, and track products from factory to floor. In many ways, the full potential of the IoT is still being realized; we’ll likely see more of that in 2018.

2. It Will Also Become More Fragmented: Just as the IoT continues to grow, it will also become increasingly fragmented. As we’ve seen with the growth of as-a-Service (aaS) programs and cloud solutions, that fragmentation will create some hurdles for many companies, as they deal with compatibility issues throughout their industries. Though companies like Qualcomm are leading the push for IoT device standards and certifications, in many ways, the genie has already left the bottle. It’s now a matter of wrangling her back into place if we want to put those standards in place.

3. Which Leads to Greater Security Concerns: I’ve said it before, but fragmentation leads to system compromise. Almost every time. The more complex, the more network security challenges. Indeed, securing all these connected devices in an environment with minimal regulation will be difficult. Finding a solution to keep data safe will be a main goal in the coming year.

4. Mobile Platforms Will Make More Sense: The trend from mobile-first to mobile-only will likely continue to grow, as mobile platforms will become the de facto management system for IoT devices. Again, this isn’t shocking—but it isn’t finished yet, either. The development of the IoT is one that will happen over time as early adopters begin to refine, and late-comers jump into the mix. The coming year will continue to see many transition into mobile platform development.

5. And Marketing Efforts Will Continue: Again—perhaps a little obvious. But this coming year will be ripe with dings, bells, and whistles as customers are alerted to bargains, incentives, and other news regarding their homes and offices. An increasing number of companies will begin to use the IoT for these more personalized marketing efforts. They’ll also get closer to finding the “how much is too much” balance when it comes to marketing.

6. Companies Will be Pushed to the Edge with Data: Because of the huge influx of data being created through the IoT, it makes sense that companies will need to find a better, closer, cheaper way to process it. That’s why edge networking will be less of a trend and more of a necessity, as companies seek to cut costs and reduce network usage. Today we are seeing companies like Cisco, HPE and Dell leading the migration of compute infrastructure to the edge. Legacy industrial IoT firms like GE and ABB are also continuing to develop hardened infrastructure to handle challenging environments that are less ideal to hosting compute than traditional data centers.

7. And Need Advanced Analytics and Machines to Help Manage It: Just as the increase in data will push companies to “the edge,” it will also push them toward artificial intelligence (AI) and machine learning. Indeed, AI will also become a necessity, as the amount of data created by the IoT will simply be too large for humans to manage. These more advanced technologies will need to find their way to support the rapidly growing IoT space soon, however, in the meantime, we will see a strong growth in analytics software and tools to provide real-time data streaming for IoT devices. Analytics companies like Software Advice, SAS, SAP, and Teradata are a few of the players making noise in this arena. I also expect a series of new entrants in the IoT analytics, machine learning and AI space as this data deluge is going to require sophisticated tools to manage and extract the most valuable insights.

8. But There will be Lots of Money to be Had: Business Insider predicts business spending on IoT solutions will hit $6 trillion by 2021. It makes sense, then, that venture capitalists will continue to poor funds into the promise of IoT—underscoring its potential to improve customer experience in almost every industry.

Like I said—this won’t be a silver bullet year for the IoT. It rarely is for any new technology. But some major inroads will be created that should help build a larger and more solid foundation for the technology in the next five years. After that—it’s anyone’s guess; we may be talking about a whole new technology altogether.

The Top 8 IoT Trends For 2018