Tag Archives: IoT

Movidius Deep Learning USB Stick by Intel

Last week, Intel launched the Movidius Neural Compute Stick, which is a deep learning processor on a USB stick.

This USB stick was not an Intel invention. In fact, Intel had acquired Movidius company that had produced last year the world’s first deep learning processor on a USB stick based around their Myriad 2 Vision Processor.

Neural Compute Stick is based around the Movidius MA2150, the entry level chip in the Movidius Myriad 2 family of vision processing units (VPUs). Using this stick will allow you to add some artificial visual intelligence to your applications like drones and security cameras. 

Movidius Neural Compute Stick form factor device enables you prototype and tune your deep neural network. Moreover, the USB form factor connects to existing hosts and other prototyping platforms. At the same time, the VPU provides machine learning on a low-power inference engine.

Actually, the stick role comes after training your algorithm where it is ready to try real data. All you have to do is to translate your trained neural network from the desktop using the Movidius toolkit into an embedded application inside the stick. Later on, the toolkit will optimize this input to run on the Myriad 2 VPU. Note that your trained network should be compatible with Caffe deep learning framework.

It is a simple process

  1. Enter a trained Caffe
  2. Feed-forward Convolutional Neural Network (CNN) into the toolkit
  3. Profile it
  4. Compile a tuned version ready for embedded deployment using the Neural Compute Platform API.

An outstanding feature is that the stick can work without any connection to cloud or network connection, allowing to add smart features to really small devices with lower consumption. This feature may be on of the revolutionary ideas to start combining IoT and machine learning devices.

Neural Compute Stick Features

  • Supports CNN profiling, prototyping, and tuning workflow
  • All data and power provided over a single USB Type A port
  • Real-time, on device inference – cloud connectivity not required
  • Run multiple devices on the same platform to scale performance
  • Quickly deploy existing CNN models or uniquely trained networks
  • Features the Movidius VPU with energy-efficient CNN processing

“The Myriad 2 VPU housed inside the Movidius Neural Compute Stick provides powerful, yet efficient performance — more than 100 gigaflops of performance within a 1W power envelope — to run real-time deep neural networks directly from the device. This enables a wide range of AI applications to be deployed offline.” — Remi El-Ouazzane, VP and General Manager of Movidius.

At the moment, the stick SDK in only availble for x86, and there are some hints to expand platforms support. Meanwhile, developers are hoping to have ARM processor support since many of IoT applications rely on ARM processor. However, this may be not possible since the stick is an Intel product.

This stick is available for sale now, and costs $79. More information about how to get started with the stick is available on the Movidius developer site. Also check this video by Movidius:

 

Visual Studio Code Extension for Arduino is now open sourced!

Visual Studio Code is the cross-platform, open sourced advanced code editor by Microsoft.

Recently, after being interested in IoT and hardware, Microsoft is now searching for tools to make building IoT devices easier. It added an Arduino extension to its Visual Studio Code to enable a better eco-system for IoT developers using Arduino. By making some research about some challenges usually developers face, Microsoft found out that giving more access to new features and capabilities will be a pain killer for IoT enthusiasts. Later on, Microsoft had opened the source of the Arduino extension and placed it on GitHub.

 

Our Arduino extension fully embraces the Arduino developer community and is almost fully compatible and consistent with the official Arduino IDE. On top of it, we added the most sought-after features, such as IntelliSense, Auto code completion, and on-device debugging for supported boards.

Core functionalities of Arduino extension

  • IntelliSense and syntax highlighting for Arduino sketches
  • Built-in board and library manager
  • Verify and upload your sketches in Visual Studio Code
  • Built-in example list
  • Snippets for sketches
  • Built-in serial monitor
  • Automatic Arduino project scaffolding
  • Command Palette (F1) integration of frequently used commands (e.g. Verify, Upload…)
  • Integrated Arduino Debugging (New)

Of course, you can download this extension from Visual Studio Code Marketplace at: https://aka.ms/arduino.

Fortunately, Microsoft had open sourced this project on GitHub under MIT License. Thus, if you are developer, you are more than welcome to participate in developing this extension and here how you can help:

  • File a bug, submit a feature request, you can find the current bug/issue list and feature requests at GitHub’s issue tracker.
  • Join developers and users’ discussions at chat on gitter.
  • Fork the repository, fix bugs and send pull requests
  • Fork the repository, add your new cool features and send pull requests.

Finally, more detailed instructions are available at the Visual Studio Code Repo at GitHub.

Temperature Controlled Stair lights With Raspberry Pi

Ever wished to know the temperature on your way to breakfast after waking up in the morning? Now you can find it out in a fascinating way as Lorraine Underwood at The MagPi magazine designed a temperature controlled colorful stair lights system with raspberry pi. In this tutorial, we’re going to discuss that project.

Temperature Controlled Stair Lights
Temperature Controlled Stair Lights

Required Parts

  • Strip of 50 neopixels
  • A 5V power source for the lights
  • 2 x terminal blocks
  • 2 x male to female jumper cables
  • A raspberry pi zero with SD card with Raspian installed
  • Power supply for the Pi zero (temporary)

 

Make sure that the raspberry pi power supply gives exactly 5 volts and is capable of outputting 2.5A current.

Make The Circuit

At first, examine your LED strip and find out which pin is what. Connect two wires to GND, one wire to Din, and one wire to +5V pin. Now, connect the 5V pin to the “+” terminal of the female jack and GND pin to the “-” terminal. Tighten the screws of the terminal block to ensure that the wires are connected properly.

Connect the Din and GND pin of the LEDstrip to the GPIO 18 and GND of the Raspberry Pi respectively, using the male-to-female jumper wires. Please note that Broadcom numbering (BCM) is used in this tutorial, not the physical numbering. It will look like below after making the connections:

Connecting Wires To The LED Strip
Connecting Wires To The LED Strip

Set Up The Weather API

You need to set up a weather API in order to get the outside temperature in your area. In this tutorial, forecast.io is used as they allow you to make 1000 queries per day free of cost. Go to forecast.io and select Developer option. Then, click sign up to create a developer account and provide your email address. A secret key will be sent to that address. Store it securely as you’ll need in the next step.

Prepare The Raspberry Pi

At first, you need to install the Adafruit NeoPixel library rpi_ws281x. Go here and follow the instructions to install the required files on your raspberry pi. Once installed, navigate to the examples folder, run any script you wish, and check if the LED strip is functioning properly.

Now, save the below script as stair_lights.py in the Raspberry Pi:

#!/usr/bin/python3
from urllib.request import urlopen
import json
import time
from neopixel import *

apikey="get_your_own_key" # get a key from https://developer.forecast.io/register
# Latitude & longitude - current values are Lancaster University
lati="54.005546"
longi="-2.784876"

LED_COUNT = 50 # Number of LED pixels.
LED_PIN = 18 # GPIO pin connected to the pixels (must support PWM!).
LED_FREQ_HZ = 800000 # LED signal frequency in hertz (usually 800khz)
LED_DMA = 5 # DMA channel to use for generating signal (try 5)
LED_BRIGHTNESS = 8 # Set to 0 for darkest and 255 for brightest
LED_INVERT = False # True to invert the signal (when using NPN transistor level shift)

def color(strip, color, start, end): 
 for i in range(start, end+1):
 strip.setPixelColor(i, color)
 strip.show() 
 
strip = Adafruit_NeoPixel(LED_COUNT, LED_PIN, LED_FREQ_HZ, LED_DMA, LED_INVERT, LED_BRIGHTNESS)
strip.begin()

count = 0
try:
 while True: 
 #get the data from the api website
 url="https://api.forecast.io/forecast/"+apikey+"/"+lati+","+longi+"?units=si"
 meteo=urlopen(url).read()
 meteo = meteo.decode('utf-8')
 weather = json.loads(meteo)

currentTemp = weather['currently']['temperature']

#negative number will always be on 
 color(strip, Color(0, 0, 255), 0,7) # Blue
 
 #what's the temp?
 if currentTemp > 0:
 color(strip, Color(75, 75, 255), 8, 15) # light Blue
 if currentTemp > 5:
 color(strip, Color(0, 255, 0), 16, 23) # dark Green
 if currentTemp > 10:
 color(strip, Color(75, 255, 75), 24, 31) # light Green
 if currentTemp > 15:
 color(strip, Color(255, 100, 0), 32, 39) # yellow 
 elif currentTemp > 20:
 color(strip, Color(255, 50, 0), 40, 47) #orange 
 elif currentTemp > 25:
 color(strip, Color(255, 0, 0), 48, 50) # Red 
 #check every 5 minutes (change to crontab)
 time.sleep(300)
 
except KeyboardInterrupt:
 print("Exit")
 color(strip, Color(0,0,0), 0, 49)

Enter your own secret key in the apikey field on the 7th line. Also, replace the longitude and latitude values on line 9 and 10 with the coordinates of your area. Now save the file and you are almost done.

To start the script automatically after each reboot and check the outside temperature every five minutes, set up a cron task by entering the following command:

sudoE crontab -e

A file will be opened and add the following lines at the end of the file:

*/5 * * * * /usr/bin/python3 /home/pi/stair_lights.py
@reboot /usr/bin/python3 /home/pi/stair_lights.py

Save the file and exit.

The Color Scheme

The following table shows which color represents which temperature range. You can modify the script to change the current color scheme.

Temperature (°C) Lights (Nos) Color
 0 – 4  9 – 16 Light Blue
 5 – 9 17 – 24 Dark Green
 10 – 14 25 – 32 Light Green
 15 – 19 33 – 40 Yellow
 19 – 24  41 – 48 Orange
 25+  48 – 50 Red

 

Open IoT Certification Mark – A New Certification For IoT Products

So it’s the time to witness the birth of a new certification for IoT industry. As security and data privacy in IoT platforms and products are two of the main concerns for developers and end-users, the new certificate discuss these concerns and even more. IoT is yet to have such certificate, as best of my knowledge, to pave the road to standardize the rules of openness and privacy in IoT. Although the term of IoT certification is already there, and some companies can do security test for your IoT products and certificate it, but nothing seems to analogy to certificate like open source hardware certificate, where anyone meets the principals, can use the OSH mark on his product.

Image courtesy of IoT.do

The new certification IoTMark was the output of a meetup hosted on June 16th 2017 in UK. This meetup gathered over 60 participants from UK and Europe. Specifically, a 22-page-long document was the output from this meetup. This document contains the principles of the certificate:

  • Privacy
  • Interoperability
  • Ownership, Permissions, Entitlement
  • Cost/biz models/pricing transparency
  • Security
  • Lifecycle, provenance, sustainability & future-proofing

To mention a few of these principles:

Privacy


The supplier of this product or service MUST be General Data Protection Regulation (GDPR) compliant.

This product SHALL NOT disclose data to third parties without my knowledge.

I SHOULD get full access to all the data collected about me.

….

Interoperability

  1. Have an open platform API [MUST]
  2. Provide comprehensive platform API documentation [MUST]

The preparation for the certificate didn’t finish yet, where The folks behind this certification will finalize it and register the mark by December 2017.

Don’t forget to have a look at the full document here. Who knows; You could use it in your next product. It’s really worth to give it a bid!

Source: Adafruit Blog

LoRaCatKitty: Build IoT Applications with LoRa in 3 steps!

Based on the ESP8266 module, “Andres Sabas” unite the best of WiFi and LoRa, Facilitating the development of IoT solutions.

LoRaCatKitty is designed to simplify the development of Internet of Things (IoT) applications using the fabulous (but still underutilized) LoRa Technology. We have based our development on the ESP8266 WiFi module and the LoRa RN2903 or RN2483 microchip module, and we have designed it to allow you can create IoT applications without deep knowledge of technology.

Renesas Electronics Achieves Lowest Embedded SRAM Power of 13.7 nW/Mbit

Renesas Electronics Corporation announced the successful development of a new low-power SRAM circuit technology that achieves a record ultra-low power consumption of 13.7 nW/Mbit in standby mode. The prototype SRAM also achieves a high-speed readout time of 1.8 ns during active operation. Renesas Electronics applied its 65nm node silicon on thin buried oxide (SOTB) process to develop this record-creating SRAM prototype.

Renesas Embedded SRAM prototype with SOTB Structure
Renesas Embedded SRAM prototype with SOTB Structure

This new low-power SRAM circuit technology can be embedded in application specific standard products (ASSPs) for Internet of Things (IoT), home electronics, and healthcare applications. The fast growth of IoT is requiring all the devices be connected to a wireless network all the time. Hence, products must consume less power to prolong battery life. With this new technology applied, much longer battery life can be achieved enabling maintenance-free applications.

One essential part of the development of IoT applications is the miniaturization of end products. This can be achieved by lowering battery capacity requirement of ASSPs. As an effort to reduce the power consumption in ASSPs for the IoT, there is a technique in which the application is operated in the standby mode and only goes to the active mode when data processing is required.

Now, the conventional way of saving power is to store all important data to an internal/external non-volatile memory and cut off the power supply to the circuit. If the wait time is long enough, this method is effective. But in most of the cases, the device has to switch between standby mode and active mode very quickly causing data-saving and restarting process extremely inefficient. There are even cases where, inversely, this increases power consumption.

In contrary to above, the new technology by Renesas Electronics uses a method where power consumption in standby mode is reduced a lot enabling switching operation to be performed frequently without leading to increased power consumption. Hence, it’s no more required to save data to non-volatile memory. This improves the efficiency further.

The low-power embedded SRAM which is fabricated using the 65 nm SOTB process, achieves both the low standby mode power consumption and increased operating speed.  Such features were difficult to achieve with the continuing progress of the semiconductor process miniaturization.  Renesas plans to support both energy harvesting operation and development of maintenance free IoT applications that do not require battery replacement by enabling ASSPs that adopt the embedded SRAM with SOTB structure.

To learn about all the complex technical information which is not covered in the scope of this article, visit the press release page of Renesas Electronics.

Bluey, BLE Development Board Supports NFC

Development boards are assistant tools that help engineers and enthusiasts to become familiarized with hardware development. They simplify the process of controlling and programming hardware, such as microcontrollers and microprocessors.

Electronut Labs, an embedded systems consulting company, had produced its new BLE development board “Bluey” with a set of useful sensors and NFC support.

Bluey is an open source board that features the Nordic nRF52832 SoC which supports BLE and other proprietary wireless protocols. Bluey has built-in sensors that include temperature, humidity, ambient light and accelerometer sensors. Also, it supports NFC and comes with a built-in NFC PCB antenna.

The nRF52832 SoC is a powerful, ultra-low power multiprotocol SoC suited for Bluetooth Low Energy, ANT and 2.4GHz ultra low-power wireless applications. It is built around a 32-bit ARM Cortex™-M4F CPU with 512kB + 64kB RAM.

Bluey Specifications:

  • Nordic nRF52832 QFAA BLE SoC (512k Flash / 64k RAM)
  • TI HDC1010 Temperature/Humidity sensor
  • APDS-9300-020 ambient light sensor
  • ST Micro LSM6DS3 accelerometer
  • CREE RGB LED
  • CP2104 USB interface
  • 2 push buttons
  • Coin cell holder
  • Micro SD slot
  • 2.4 GHz PCB antenna
  • NFC PCB antenna

Bluey can be programmed using the Nordic nRF5 SDK. You can upload the code with an external programmer such as the Nordic nRF52-DK, or the Black Magic Probe firmware on STM32F103 breakout. But, within the built-in OTA (over the air) bootloader, you can upload the code directly using a PC or a phone.

The sensors on the board require a minimum of 2.7 volts to function properly, and the maximum power is 6 volts. Bluey’s design offers three different ways to power it, all of them have a polarity protection:

  1. Using the 5V micro USB connector (which also gives you the option to print debug messages via UART).
  2. The + / – power supply pins which can take regular 2.54 mm header pins, a JST connector for a 3.7 V LiPo battery, or a 3.5 mm terminal block.
  3. A CR2032 coin cell for low power applications.

You can use Bluey for a wide range of projects. The BLE part is ideal for IoT projects, or if you want to control something with your phone. The nRF52832 SoC has a powerful ARM Cortex-M4F CPU, so you can use this board for general purpose microcontroller projects as well.

Bluey is available for $29 for international customers from Tindie store. Indian customers can purchase it from Instamojo store. There are also discounts for bulk purchases. For more information about the board visit its github repository, where you will find a full guide to start and a bunch of demo projects.

YouTube channel IoT view counter

Kenneth Finnegan built this YouTube channel IoT view counter. He writes:

I’ve wanted an Internet connected read-out for some time now, inspired by the awesome shadow box IoT projects Becky Stern has been doing (weather, YouTube subscribers). I’m certainly not to the same level of packaging as her yet, but I’ve got a functional display working with a Hazzah and an eBay seven segment display module.

YouTube channel IoT view counter – [Link]

Mongoose OS Operating System for Connected Devices

Another OS for IoT applications called Mongoose OS. Like the other OS’s for IoT, Mongoose OS has some security features like:

  • Microchip ECC508A crypto chip support.
  • Supporting mbedTLS library from ARM.
  • Implementation of file system encryption and full SPI-flash encryption on ESP32.

Mongoose implements the API for: HTTP, WebSocket, MQTT and CoAP; for both client and server and with a rich API and a tiny footprint. Moreover, it integrates with Amazon AWS IoT service, Google IoT Core and Adafruit IO online service.

Talking about the SDK; Mongoose prefers to use native SDKs instead of building them from scratch by extending the original ones. The current supported microcontrollers are ESP32, ESP8266, STM32, TI CC3200. You can develop your code in C or JavaScript using mJS engine (part of Mongoose OS).

For device management and firmware building Mongoose uses a tool called mos. This tool works in Windows and Linux as a command line interface or a web UI.

In the video below there is an example of running a built-in web server using ESP WiFi module.

 

Last but not least, Mongoose supports the following hardware interfaces: Bitbang, GPIO, I2C, NeoPixel, SPI and UART. It can also performs remote management for the device such as: file system (list, get, put and remove), configuration, I2C, GPIO and OTA

An example of upgrading the firmware over the air (OTA) is explained in the video below :

 

SYNTHETIC SENSORS, All-In-One Smart Home Sensor

In the era of Internet of Things, we wanted most of our home appliances to become smart. But currently, smart devices may cost much more than their offline counterparts and they often do not communicate with each other. Trying to overcome these limitations, A Ph.D student invented a way to turn entire rooms into smart with a single low-cost device called “Synthetic Sensors“.

Gierad Laput, is a Ph.D. student of computer-human interaction at Carnegie Mellon University. His research program explores novel sensing technologies for mobile and wearable computing, smart environments, and the Internet of Things.

Synthetic Sensor is a general purpose sensor that is powered directly from a wall socket and tracks ambient environmental data to monitor an entire room. It removes the need to attach additional hardware to each of home appliances.

We explore the notion of general-purpose sensing, wherein a single, highly capable sensor can indirectly monitor a large context, without direct instrumentation of objects. Further, through what we call Synthetic Sensors, we can virtualize raw sensor data into actionable feeds, whilst simultaneously mitigating immediate privacy issues. We use a series of structured, formative studies to inform the development of new sensor hardware and accompanying information architecture. We deployed our system across many months and environments, the results of which show the versatility, accuracy and potential of this approach.

The device uses machine learning to recognize the events that happen in the room, like recognizing a particular sound pattern as taking a paper towel, but it cannot monitor when the roll may need to be changed. However, by using a “second order” sensors, the devices can capture counts and send notifications of the need to replenish. This capability can be scaled to an unlimited degree giving consumers highly specific and applicable feedback.

Developers can use the recognized events as triggers for other IoT applications. For example, one could use “left faucet on” to activate a room’s left paper towel dispenser and automatically schedule a restock when its supply runs low.

The Synthetic Sensor is still in prototyping phase, you can learn more about it by visiting its website and read the research paper. Watch this video to see Synthetic Sensors in action: