Click here to Skip to main content
65,938 articles
CodeProject is changing. Read more.
Articles / IoT

IoT Path-To-Product: The Making of a Connected Transportation Solution

4.00/5 (2 votes)
19 Aug 2016CPOL11 min read 7K  
This solution monitors the temperature within a truck’s refrigerated cargo area, as well the open or closed status of the cargo doors. The gateway generates events based on changes to those statuses, to support end-user functionality on a tablet PC application.

This article is for our sponsors at CodeProject. These articles are intended to provide you with information on products and services that we consider useful and of value to developers

Get access to the new Intel® IoT Developer Kit, a complete hardware and software solution that allows developers to create exciting new solutions with the Intel® Galileo and Intel® Edison boards. Visit the Intel® Developer Zone for IoT.

To demonstrate a rapid path-to-product edge IoT solution for the transportation sector, a proof of concept was created using the Grove* IoT Commercial Developer Kit. That prototype was scaled to an industrial solution using an Intel® IoT Gateway, industrial sensors, and Intel® System Studio. This solution monitors the temperature within a truck’s refrigerated cargo area, as well the open or closed status of the cargo doors. The gateway generates events based on changes to those statuses, to support end-user functionality on a tablet PC application.

Image 1

Figure 1. The finished product demonstration with custom trailer housing.

The core opportunity associated with the Internet of Things (IoT) lies in adding intelligence and connectivity to everyday devices, harnessing information and putting it to use in ways that add value. Monitoring the status of a refrigerated semi-truck trailer hauling perishable goods is a simple example. Alerting the driver when the temperature passes outside a pre-set range or when cargo doors are opened unexpectedly can help avoid financial losses. An IoT solution to monitor and track these aspects of a semi-truck trailer could therefore be a viable commercial product.

Intel undertook a development project to investigate this and other opportunities associated with building a connected transportation solution. The project was presented as a demonstration at Intel® Developer Forum in 2015 and again in 2016. This document recounts the course of the project development effort, to help drive inquiry, invention, and innovation for the Internet of Things.

For a how to for this project, see IoT Path-to-Product: How to Build a Connected Transportation Solution.

Visit GitHub for this project's latest code samples and documentation.

Introduction

The goal of this project was to build a functional prototype and then to transition that proof of concept into an industrial-grade solution for scalable deployment as a commercial product. Rapid prototyping is facilitated by using the Grove* IoT Commercial Developer Kit, which consists of an Intel® NUC system, Intel® IoT Gateway Software Suite, and sensors and their components from the Grove* Starter Kit Plus (manufactured by Seeed). The project also uses the Arduino* 101 board. Hardware used in the prototype stage of this project is illustrated in Figure 1, and specifications are given in Table 1.

Note: Known in the United States as "Arduino* 101," this board is known elsewhere as "Genuino* 101." It is referred to throughout the rest of this document as the "Arduino* 101" board.

Table 1. Prototype hardware used in connected transportation project

 

Intel® NUC Kit
DE3815TYKHE

Arduino* 101
Board

Processor/
Microcontroller

Intel® Atom™ Processor E3815 (512K Cache, 1.46 GHz)

Intel® Curie™ Compute Module @ 32 MHz

Memory

8 GB DDR3L-1066 SODIMM (max)

  • 196 KB Flash Memory
  • 24 KB SRAM

Networking / IO

Integrated 10/100/1000 LAN

  • 14 Digital I/O Pins
  • 6 Analog IO Pins

Dimensions

190 mm x 116 mm x 40 mm

68.6 mm x 53.4 mm

Full Specs

specs

specs

Image 2

Image 3

Figure 2. Intel® NUC Kit DE3815TYKHE and Arduino* 101 board.

The course of this project demonstrates the value of the path-to-product approach: it allows a prototype to be built with a relatively small investment of time and effort, followed by an efficient transition to a commercially viable solution. Using a precompiled OS as well as RPMs helps to eliminate unnecessary downloads, having to customize the OS, and identifying libraries necessary to bring a project to life.

This project was devised to contribute to innovations around solutions for similar use cases being produced and marketed. While this project was designed to provide only basic functionality, its design is flexible and extensible enough that a variety of features could be added. In particular, the project could be expanded in the future to include web connectivity, cloud capabilities, remote monitoring, and other components.

In the project’s earliest stages, the team listed potential features for the prototype and the product. A sample of these included rear-door status (open or closed), temperature of the trailer, alarms based on the state of the door and temperature, an online application to view data, and in-cab monitoring of information. To demonstrate the viability of creating a robust solution while maintaining simplicity and low cost, the team elected to limit the bill of materials for the prototype phase to just the contents of the Grove IoT Commercial Developer Kit.

Creating the Prototype Proof of Concept

To allow for separation of duties and efficient progress, the team divided the solution into three primary areas of effort:

  • User interface (UI). Part of the team began working on the actual production UI layout and design, looking ahead to the production stages of the project.
  • Application business logic. Part of the team began working on the logic for the prototype application, while also recognizing that changes would be needed as the project progressed toward the commercial solution.
  • Prototype sensor solution. Part of the team began to create the configuration of sensors for the solution, utilizing the UPM/MRAA libraries for rapid development.

This approach of separating the project into discrete segments allowed the team to progress through the prototype phase more rapidly than otherwise, taking best advantages of skill sets available within the team. In particular, while the user interface was not strictly required in the early phases of the project, it was expected to require the most development time of the three areas listed above. Therefore, so beginning it as early as possible allowed for it to be well underway by the time it was needed later in the project.

In terms of the application logic, the team was able to look ahead to the expected final functional prototype and make decisions in the early prototype process looking to the future. Overall, the team expected the operation of the door sensor to be relatively simple, allowing greater attention to the proper utilization of a temperature sensor on a small and then commercial scale.

By utilizing the sensors in the Grove* Starter Kit Plus, we were able to rapidly create a prototype with a functional sensor environment that the UI team could work with. This approach enabled layout and design elements to come to life quickly and provided a future framework for the final functional use case. The prototype configuration, with the Intel® NUC, Arduino* 101 board, and sensors, is illustrated in Figure 3. The bill of materials is given in Table 2.

Image 4

Figure 3. Developer kit with selected sensors enabled.

Table 2. Connected transportation prototype components.

 

Component

Details

Base System

Intel® NUC Kit DE3815TYKHE

http://www.intel.com/content/www/us/en/support/boards-and-kits/intel-nuc-kits/intel-nuc-kit-de3815tykhe.html

Arduino* 101 Board

https://www.arduino.cc/en/Main/ArduinoBoard101

USB Type A to Type B Cable

For connecting Arduino* 101 board to NUC

Components from Grove* IoT Commercial Developer Kit

Base Shield V2

http://www.seeedstudio.com/depot/Base-Shield-V2-p-1378.html

Touch Sensor Module

http://www.seeedstudio.com/depot/Grove-Touch-Sensor-p-747.html

Button Module

http://www.seeedstudio.com/depot/Grove-Button-p-766.html

Temperature Sensor Module

http://www.seeedstudio.com/depot/Grove-Temperature-Sensor-p-774.html

Buzzer Module

http://www.seeedstudio.com/depot/Grove-Buzzer-p-768.html

Red LED

http://www.seeedstudio.com/depot/Grove-Red-LED-p-1142.html

LCD with RGB Backlight Module

http://www.seeedstudio.com/depot/Grove-LCD-RGB-Backlight-p-1643.html

Use Case

The use case was built and displayed through an administration application to support the following scenario:

  1. Press button to start the use case (simulating opening the door):
    1. Sets threshold ambient temperature +5 degrees.
    2. Solid red LED lights up in cab.
    3. LCD displays current temperature and door status (open), as shown in Figure 4.

      Image 5

      Figure 4. Showing door status.
  2. Touch temperature sensor to raise ambient room temperature by five degrees:
    1. Buzzer sounds.
    2. Red LED blinks continuously.
    3. LCD turns red and displays actual temperature and door status (open), as shown in Figure 5.

      Image 6

      Figure 5. Showing high temperature status.
  3. Touch sensor to acknowledge alert (buzzer turns off).
  4. Press button to close the door:
    1. Red LED continues to blink until temperature passes below threshold.
    2. LCD displays temperature and door status (closed).
    3. When temperature passes below threshold, blinking red LED turns off, solid green LED lights up, and LCD turns green.
    4. LCD displays temperature and door status (closed).

Simulation

This simulation demonstrates the reduced potential loss of temperature-sensitive cargo by monitoring temperature changes and alerting the driver if it becomes critical, as illustrated in Figures 6 and 7.

Image 7

Figure 6. Log file showing events.

Image 8

Figure 7. Base online view as envisioned.

Target Commercial Solution

With an operational prototype based on the Intel® IoT Developer Kit and Grove IoT Commercial Developer Kit, it was necessary to determine how to proceed to create a commercial solution. Table 3 outlines how the components used in the prototype phase could be transitioned to a production solution.

Table 3. Components in prototype versus production solution.

 

Prototype

Production Solution

Buzzer

Grove Kit Buzzer

Alarm on Phone (customer application)

LCD

Grove LCD panel

Screen on Phone (customer application)

LED (RED)

Grove Kit LED

Light on Phone (customer application)

Button

Grove Kit Button

Industrial magnetic sensor with paired magnet

Touch Sensor

Grove Kit Touch Sensor

Touch on Phone (customer application)

Temp Sensor

Grove Kit Temp Sensor

Commercial Temp Sensor

Heat Source

Person’s Finger

20-watt Halogen Puck Light

Gateway

Intel® NUC and Arduino 101 Board

Intel® IoT Gateway

In addition, there are many commercial gateways available, with design differences making them suited to various industries and use cases. A key consideration for this project was a broad range of I/O options, to support both current and future functionality, specifically for connecting sensors to provide a data feed.

An Intel® IoT Gateway was chosen as the gateway device for the product portion of this project, as shown in Figure 8. The processing power and I/O functions were deemed sufficient for the presented commercial usage.

A wired Modbus temperature sensor was chosen to provide a reliable connection to obtain temperature readings every several seconds. All communications on devices were performed via direct wiring or via Ethernet. Standard MRAA/UPM libraries were maintained throughout the process without any modifications.

The gateway acts as a web server, storing data as well as making calls to the temperature sensor to keep the data fresh. The Java UPM Library uses libmodbus to read and send periodic updates from the Comet* temperature sensor to the Tomcat* web server.

Image 9
Figure 8. Gateway installed as part of demo with temperature sensor.

Transferring Code to the Gateway

Typically, ramping up to a commercial gateway involves having to revamp code so that it is compatible with whichever services are available on the system. In this case, the coding on the prototype was all performed in Java*, HTML, and JavaScript*, making the transition to a commercial solution relatively simple. The code transition was simplified by the use of the same MRAA/UPM libraries in both phases of the project.

Mapping Grove Sensors to Industrial Sensors

Using MRAA and UPM libraries can help jumpstart a project. The following steps cover porting the app to the commercial product solution:

  1. Target desired industrial hardware:
    1. Determine whether the hardware requires additional libraries or application support.
    2. If needed, integrate libraries and software and create OS layers for software deployment.
  2. Once commercial product hardware is successfully integrated into the prototype solution, remove the code that is no longer needed:
    1. Utilize existing layers created during the prototype phase to install solution dependencies.
    2. Make changes as needed for new hardware.
  3. Take new and old layers and build into production runtime.
  4. Complete all installation and testing on production hardware.

Customer Application

The base customer application, shown in Figures 9 through 12, was created to replace the functionality of the Grove LCD, LED, buzzer, and touch sensor that the driver would interact with. In the production solution, the customer application would reside on the mobile device carried by the driver, allowing for easy notification and response to alerts. The customer application is quite simple in this example but could be easily expanded. It has two status indicators that refer to temperature and door status. An alert button becomes active and then gives an acknowledge button to clear the alert.

Image 10

Figure 9. Main status screen.

Image 11

Figure 10. Status showing an alert.

Image 12

Figure 11. Showing a full alert and acknowledge button active.

Image 13

Figure 12. Initial setup screen finding IP address of gateway.

Conclusion

This exercise demonstrates use of the Grove* IoT Commercial Developer Kit to rapidly develop a prototype. With wide-ranging libraries, the ease of use of the Developer Kit simplifies the development process while also providing high compatibility for commercialization of the product. Scaling up to a commercial gateway was quite easy, as the team was able to directly copy code and have it function immediately.

More Information

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)