Todays progress

So far so Good 😊, we have done some modifications to our solution and have now established a more attractive business value and some better user interfaces and data integrations.

First of all the new idea is to reduce the monitoring space and range, so we came up with changing the scope and customer type to: ZOOs. Our new brand is: SmartZoo.

In each ZOO we can find different species of animals living together in controlled habitats, they have very different needs and behaviors, that is why we needed an adaptable system that could receive information from different IoT devices measuring different types of data.

Our platform is “device ready”, it means that we can include new devices in an easy way by using the concept of “device groups” which allows us to differentiate animals by grouping IoT devices based on species.

Our final goal is to implement Smart ZOO in multiple locations around the world in different ZOOs and get Insights from all of them so we can identify anomalies, improve facilities and procedures and last but not least increase sustainability by optimizing the use of resources like electricity, food and water.

We created a web page to be presented to possible customers, it is responding very well to different screens and devices and it is a good entry point to get in touch with us. The URL is: https://smartzoo.webflow.io/

We have created a dashboard, in IoT Central, with data from the IoT devices (smarthphones + IoT DevKit). IoT DevKit provides data of temperature, pressure and humidity.

We are tracking the turtles locations in and showing it in a map. We want to use this information to send alerts if turtles escape their cage. We also want to generally gather information about their movement, which can be used to tell if a turtle is sick or hurt.

Smartphone (turtle) devices provides gyroscope (x,y,z) which tell how the rotation is for the smartphone (turtle). We are using this to provide information if the turtle is turned upside down (the worst thing that can happen to a turtle…). If the turtle (smarphone in our case) is upside down a rule is trigged and an email is sent to the zoo keeper and the light on the smarphone is turned on.

Logic app:

Email:

Light turned on the smartphone:

Machine Learning

We are currently working on implementing machine learning such as anomaly detection. If there is any spikes or dibs in the temperature value want to store this information in CosmosDB and send an alert message. This can detect any abnormal behavior in any of data we are collecting, and automate the job of alerting relevant people of what is happening.

We are gathering temperature information from the Event hub, sending it to Stream Analytics Jobs to detect anomaly and sending output result to Cosmos DB:

CosmosDB:

WebApplication

We have implemented Geolocation with SignalR so the markers are shown in the map in real time. When the devices are in motion the markers will move at the same time.

The front end calls the Hub so it does not need to call the controllers each time with a common Http call.

Excellent user experience

Here we can include all changes to our branding and webpage. IoT central got also a new brand and it is much easier to identify the different habitats per species in the dashboards.

We have also improved the responsiveness of some of the visuals in the IoT central by implementing signalr and React.

Most extreme business Value

We tried to explain it in the overview of this POST, but as we mentioned before, the real business values comes when getting data from different Zoos and produce Insights and make decisions based on it.

Rock Solid Geekness

Here is an overview of technology used:

Killer App We find it difficult to explain how it is a killer app, but we hope it is enough with all the previous text 😊

Hipsters dreamworld

We are making some improvements in the solution with the help of 2 technologies that we think might be considered for he Hipsters badge. They are:

  1. Azure IoT central V3 (Preview) connector: This allows us to send commands back to the devices from IoT central. Perfect for the business flow.
  1. Metamask plugin for login: We are working in a solution for end users where they can log in to a page and see real time data flowing into graphs and maps. One of the possible ways to login is by using Metamask as a Web 3 platform to login to an hypothetical blockchain that could work as decentralized data repository for members of ZOOs. (read more here: https://docs.metamask.io/guide/). This feature is in an experimental phase, but the POC is working good.

Happy coding!

Tips from an ACDC veteran!

Hello everyone! It has been a very interesting event this year, we got a new room, new participants and a lot of new challenges and ideas.

We were impressed with the sustainability challenge that we got yesterday and wanted to contribute a little bit with some ideas around it.

Some of us have been in this event many times and learned some tips that might suit everyone and in addition contribute a little bit with some of the the Principles of Sustainable Software Engineering.

Try not to go to bed so late, it’s not good for your mind and body to work under stress, you are less productive and creative. Try instead waking up early after a good sleep and you will think clearly and ideas will just start flowing.

Remember of course to shutdown your Azure services during the night and start them again during the day (Take a look at https://aka.ms/learn-green) to learn more about what we mean.

Happy coding!

Setting up the projects backbone

Azure Cosmos DB

The solution is using CosmosDB to store Users and Telemetry coming from the different devices/assets

CosmosDB is fast and easy to maintain for noncomplex solutions. The main use here is for very simple data structure and for mass data allocation. Since we are getting data from this DB in real time, so we need to send a lot of requests in very short time ranges. Since CosmodDB is DocumentDB based so it handles these kinds of situations smoothly.

Azure WebApplication

We have created a web application as the user interface to keep track on the assets. The web applications is based on .Net Core 6 with React/TypeScript. We have implemented some of the main .net core features as:

– Entity Framework: To connect in a simple way to CosmosDB

– Controllers: As API endpoints

– Azure KeyVault Provider: As a provider, the same as an appsettings file. This protects all of the secret variables like codes, keys, connection strings and so on.

– Session: To create an encrypted cookie (Https, SameSite) to keep the session alive

– Cors: to prevent other origins to send requests to the BackEnd

– Dependency Injection: To inject all different services to the solution, including custom services and custom repositories.

– Hub: To connect to the SignarlR applcation

Azure Maps

Azure maps is used to track the geo location for all different assets. It will show the position of all assets in real time with the help of Signal R.

We have given a little bit of extra styling to the pointers and added some of the out of the box controls.

Azure Signal R

We have implemented Signal R to open a websocket for real time communication. The main idea was to avoid so many common http requests to the backend which is not so good when it comes to performance and security.

The front end sends requests to the Hub and it immediately gets a response so the data is always fresh and new. This is the way we keep track on the assets by getting all the telemetry/data needed from the Cosmos DB.

GOOD MOOOOOOOOOORNING TURTLEEEES

We have found ourselves some coffee and we are now ready to start the day. At 07:15 the whole team was in place.

We took sometime last night to go through this challenge and learned very interesting concepts that we don’t usually think about in our day to day work. Thanks to the ACDC judges for this info, good to have it in our heads while designing solutions.

Rules

For å ha bedre kontroll på system, uten å måtte manuelt overvåke hele døgnet, har vi implementert “Rules” i IoT Central.

Hvis temperature går under 18 grader blir en alerm aktivert, hvor det sendes ut mail relevante personer med informasjon om hva som har skjedd.

Hvis Rotation/Y overstiger 0.1 betyr det at telefon (eller skildpadden i tenkt tilfelle) er snudd opp ned. Da sendes det ut en alarm beskjed om at gitt telefon er snudd på hode.

Bildet under viser hvordan en mail ser ut når en skildpadde er snudd på opp ned.

Claimed Badge:

IoT Central

Med hjelp av IoT Central kan vi vise frem leselig data. Microsoft har en “IoT Plug and Play” app som kan sende data hentet fra smart telefonen. Bilde nedenfor er et skjermbilde av appen på telefon.

IoT Plug and Play – App

Denne dataen har vi klart å sende til IoT Central. Bilde under viser data som blir sendt fra smarttelefonen.


IoT central:

Smarttelefonen kan vi bruke som som å simulere hvordan skildpadder eller fisker beveger seg i området. Med denne løsningen kan vi koble flere smarttelefoner til IoT Central, slik at det blir mer realistisk.

IoT DevKit

Vi har også koblet opp en MXCHIP (IoT DevKit) til Iot Central til vise frem temperatur, humidity osv… som er viktige data for å skape et godt og behagelig miljø til dyrene:

IoT Central/IoT Plug and Play er nytt og hipt så vi claimer Hipster badge. Dasboardet godt leselige grafer, så vi prøver oss på Dash It Out Badge. Vi claimer også Embedding numbuts grunnet IoT-løsningen.

Github repository & Azure Devops

For å få en god start på prosjektet setter vi i Bouvet Shredders opp en Github repository og Azure Devops. Med Azure Devops kan vi jobbe på tvers av teamet på best mulig måte.

Alle som ønsker å følge med på vår progresjon er hjertelig velkommen til å ta en titt på vår Github Repository:

  • https://github.com/bricenocar/acdc-2022

Vi tar i mot inspill med åpne armer, så ikke vær redd for å si ifra hvis du ser noe som kan gjøres bedre måte!