Friday, December 2, 2016

Using Contiki with linux CCS

Creating Contiki/CETIC based IPv6 border router solution (6LBR) with BeagleBone Black and using TI SensorTag2 with SLIP to connect 6LoWPAN mesh network is one thing. Debugging node from linux is another. Let's see how it works :)

Getting Contiki git repo and compiling web-demo for TI Sensortag in linux works quite well. Flashing it not so. Recommended way is to
transfer image to windows and flash from there, but it's possible to flash from linux commandline also. Using Code Composer Studio (CCS) makes job much easier, and you can also debug your code, at least in theory.

CCS can import project with makefile-style compiling (File -> Import -> C/C++ -> Existing Code as Makefile Project). Unfortunately it only can understand simple Makefile and Contiki uses include etc. Even when you can compile image, CCS will complain lot's of errors and warnings. It's quite bizarre situation. One way to 'fix' it, is defining things in makefiles to headers so CCS known what is actually defined when compiling. Like adding to project-conf.h:

/* for CCS as it can't detect this from Makefile.include */
/* CCS uses wrong button-sensor.h */

Also finding source files can be a bit tricky. Adding whole contiki would be simple way so solve this but CCS don't like adding parent of project. Way around is adding links (to project) to needed subdirectories:
project -> properties -> c/c++ general -> Paths.. -> Source Location -> Link Folder
apps, cpu/cc26xx-cc13xx, core, platform/stf06-cc26xx
Also in c/c++ build -> settings you can enable gnu-versions of parsers.

You can also add Makefile.include from top, but it only makes editing easier (project -> Add Files -> Link).

Also you need to get debug-symbols to elf, so add Makefile:

Nice. Now it doesn't complain and (most) code it shows is actually right one. To debug you need to create .ccxml target configuration file (project -> New).

Note that when you connected Debug DevPack to PC, it shouldn't have SensorTag2 connected to it. After board have booted (green led on) connect SensorTag2. Also when debugging first time, Debug DevPack firmware is updated to newest one.

Start debugger. Change Debug -> .ccxml -> Edit.. -> Program -> Cortex_M3_0 Project to project root and Program to .elf file. Check that run to symbol main is set. Next start of debug should then automagically load & run to main(). If it doesn't automatically load image to SensorTag2, you can choose Load & select elf.

Unfortunately good things stops there. For some reason JTAG connection to SensorTag2 seems to disconnect really often. Even dropping it's speed from 2.5MHz to 100kHz doesn't help :( This is probably due eclipse blocking and emulation package then misses something from JTAG/Debug DevPack. Hopefully future update fixes (some of) this.

Debugging active and ready to run
Jari Vanhala, Senior SW Designer, Ixonos

Friday, September 2, 2016

Quick Visual Dashboard

When developing IoT systems you’re often dealing with a huge amount of time series data. Basically key-value pairs bound to a timestamp. Or maybe you are debugging some sensor output or feedback controller only using text output on your terminal. Getting a sense of what kind of data your sensors are outputting is not easy when you’re dealing with tens, hundreds or even thousands of sensors and measurements.

Various tools already exist to visualize time series data. They are very good at visualizing large amounts of data in multiple different ways. But setting these tools up often takes time and the learning curve to effectively configure the visualizations to view your data is often an unwelcome bump in the road when all you care about is getting a sense of the data you’re dealing with without bothering with the details.

Real-time data visualized using simple graphs with minimum lag.

When developing, testing and prototyping, it is essential that you get good understanding, how your system performs in real-time and also within a longer time-frame. You don’t want to spend time configuring and setting up visualizations tools. This is why we put together Quick Visual Dashboard. A local or cloud deployed visualization tool where you can input data using standard TCP or MQTT protocols. With simple script templates done in Python, uploading data to the tool can be done in no time.

Built-in geospatial data support to see how and where your data is on the map in real-time.

The data is preprocessed and backed by InfluxDB. This means that after you’re done with your initial prototyping and you stop caring about real time data - you can go back and use industry proven tools like Grafana to further investigate all the details of your time series data at any point in time.

Using Grafana it is possible to dive deeper into historical time-series data.

Christian Talmo, Full-stack Developer, Ixonos
Stanislav Radomskiy, Senior SW Designer, Ixonos

Tuesday, April 21, 2015

NFC as an Enabler for Efficient Asset Management

When it comes to managing assets in industrial environments there are a few use cases that come up frequently. And naturally also a few problems relating to each. In this post an asset can be pretty much any device that monitors or controls an industrial manufacturing process. Of course assets also exist in environments with moving machines and logistics; like harbor areas.

 When a service person is visiting a site (either during installation, as a routine check-up, or responding to a service request) the first thing to overcome is usually identifying the asset he or she wants to operate. For example there can be various injection moulding machines operating in a factory floor. The machines may be from different suppliers, of different generation/version, running different software and/or configurations, and so on.

 After the asset has been identified, it usually needs to be accessed to retrieve logs, adjust parameters and so on. For this purpose there are various local control panels. These often don’t have the most modern and easy-to-operate user interfaces. Also the panels may be physically located in a hard-to-reach place (e.g. behind a corner, between a machine and a wall, etc.).

 In some cases you can or even have to connect an external control device (like a laptop) to the asset to control, reconfigure or even reprogram it. This is traditionally done with a laptop and some kind of serial cable. In more modern solutions (like Ixonos Internet Suite) it may also be possible to do the connecting and configuration wirelessly e.g. with a tablet or other mobile device.

 To solve the issues above and make the service person’s work as efficient and ergonomic as possible, there are several ways where modern wireless technology can help. You could use RFID tags or barcodes to identify the assets and setting up the connectivity.

 We decided to take a closer look at NFC. By using simple, inexpensive passive NFC tags we were able to significantly speed up identifying, accessing and connecting to assets in the field.

 Check the video below for details and examples:

All-in-all NFC is a modern and reliable technology for improving the efficiency of service personnels work in the field. Of course this is only a small part of a comprehensive solution which requires lot of intelligent software solutions both on site and in the cloud. Check our previous blog posts and stay tuned for more relating to those.

Manish Kumar, Senior SW Engineer, Ixonos
Mikko Mäkinen, SW Engineer, Ixonos

Friday, March 13, 2015

Mesh networks for industrial internet

Industrial internet is mostly about collecting, analyzing and visualizing data to enable new use cases or to enhance operations. One of the challenges in getting industrial internet systems up and running is how to efficiently set up and manage networks consisting of dozens or even hundreds of sensors. Wirepas have developed an interesting wireless mesh network solution they call Pino™ to solve this issue.

To test the usability of the Wirepas mesh with our existing data collector, Sensor Hub, we added a Wirepas plugin to the Hub, and designed a set of simple sensor boards that measure temperature, absolute air pressure and battery voltage. The readings were then transferred via UART to a reference HW board developed by Nordic Semiconductor running Wirepas Pino™ stack. These boards automatically organized themselves to a mesh and relayed the data to a gateway, a simple USB dongle with a virtual serial port. Users were able to view data collected from the sensors locally, and the Hub also pushed the data to the cloud using either ethernet, WiFi or cellular network.

See video of the solution in use:

Wirepas Pino™ mesh is not aimed at low latency real-time data, but rather at giving possibility to easy deployment of very low power battery operated mesh network with zero configuration and minimal installation.

Just drop the wireless sensor nodes where needed and the mesh automatically configures itself. If the signal range has to be extended, simply drop another node on the way and it starts relaying the data.

Most of the time there are multiple routes through the mesh for relaying data. The sender can set preference for either low latency or energy. The mesh automatically optimizes routing based on the energy reserves available in the nodes, or by fastest route. If a node is low on battery, the mesh automatically starts avoiding that node to further save its battery.

In case of deploying large amount of nodes, it is possible to add more gateway nodes to distribute the traffic load and also to avoid single point of failure.

Based on our experience the Wirepas Pino™ does it's job in providing a wireless sensor network that is easy to set up and administer. This quite nicely complements Ixonos' solutions that focus on data collection, cloud storage, and visualization of data quite nicely.  We look forward to creating solutions for our Industrial customers using Wirepas technologies.

Teemu Rasi, Embedded Engineer, Ixonos Plc

Friday, January 16, 2015

Linux Flashing for Freescale i.MX6

We often have customer and R&D projects where we build embedded SW solutions on the Freescale i.MX6 platform. As our OS of choice usually is Linux, developing those solutions has been a bit problematic since Freescale's own tool for flashing (MFGTool) is only available for Windows. Our developers finally got bored of having a separate Windows -workstation for flashing the stuff they had developed on Linux. Therefore they decided to create a Linux tool for flashing to speed up the
development process.

The result of this work was a tool called utp_com which can be used with imx_usb to flash i.MX6 based hardware from Linux environment. As we are talking about Linux we also decided to make the tool publicly available.

Development started from point where we were able to flash "flashing OS" into the device with imx_usb tool. After this a SD card device (/dev/sd* ) is available from the target device to the host machine via an USB connection. The SD card device is not a conventional one, but communication is done with the SCSI commands. On top of them Freescale has defined an Update Transport Protocol ( UTP ) which is used for communication. UTP message data is sent in the vendor specific CDB field of the SCSI message. Return values come as part of the SCSI sense data.

Example commands how a file is copied to the target device and then written to a flash device below:

utp_com -d /dev/sdb -c "send" -f u-boot.bin
utp_com -d /dev/sdb -c "$ dd if=\$FILE of=/dev/mtd0 bs=512"

Code is under GNU GPL v2.0 license, and can be found from:

We hope you find it as useful as we do!

Teemu Piiroinen, SW Specialist, Ixonos Plc

Tuesday, November 18, 2014

Fast Piloting of Industrial Internet

The buzz and fuzz around Industrial Internet seems to accelerate almost daily. While it is clear that the possibilities and potential benefits are endless, it is quite difficult to decide how to reach those in practice. We wanted to create a solution that makes it easy to setup the “basic infrastructure” to enable piloting different applications of Industrial Internet in practice.

We have seen that often a lot of data is collected from Industrial automation systems through different sensoring and other solutions. If that data could be easily moved to cloud, analysed and presented to users in smart ways, it would be easier to experiment with ways to utilise that data to improve efficiency of operations or even as an enabler for new digital services.

With this in mind we took our Industrial Internet Suite -software solution and installed it on Industrial grade reference HW with 3G connectivity. Our sensact -communication framework combined with Ixonos Cloud and Remote Dashboard make it easy to “plug in” your existing automation environment and start visualising your data. The HW/SW combination supports connections through common field-buses (like Modbus). Check out the more detailed architecture from a previous post.

After having the solution in place, we put it in a nice package. See the video below about what it looks like in practice.

We now have a set of these packages that we are offering to our customers for pilot use. This way it is very easy and risk-free to try out what you can get out of already existing data and automation by adding modern “Industrial Internet” -technologies.

Contact us for more info or a trial. There's also a white paper available concerning the topic on a bit wider scope.

Jukka Hornborg, Head of Offering Management, Ixonos Plc

Tuesday, October 7, 2014

Renew web & mobile automated testing with a new Page Model -based tool

Today more and more services are becoming web based. This means that modern user interfaces are built using HTML5 and other web technologies, even in embedded environments. At the same time applications and services are becoming more complex which means that testing is more crucial than ever in bringing high quality software to markets on time.

There are several existing tools to automate UI testing mostly based on different recording and playback methods. While it is easy to develop such tools, using them and especially maintaining test assets created with them is not very easy. Also it may be hard to match reported errors to actual web page elements (e.g. “element_id_zyz_2” is missing).

We decided to try a more innovative approach. We wanted to create a tool that is easy to use, while powerful enough for automating the testing of even the most complex and dynamic user interfaces. Also the solution should have long lasting support and have a wide cross-browser support across different desktop and mobile devices.

To meet the usability criteria we developed the Page Model approach. Here’s what it means in practice:
  • Page Model is similar to the Page Object, which represents the screens of your web app as a series of objects.
  • The difference is that the Page Model has more elements:
    • Information of web app screen and model type (full screen, selected area of screen)
    • Information of Page Objects (web elements and dynamic objects)
    • Screenshot of full screen or selected area of your screen
    • Methods containing the functionality of the web page (e.g. login method)
  • Page Model transforms the information of a web page's elements automatically to textual format that can be used instantly in creating test scripts.
  • Page Model screenshot visualises the web page and it is used for selecting objects in test creation.
  • Page Model file also contains methods that can be used to execute actions present on the web page. It can be understood as a Page Model specific “function library”.
  • After creating models, test scripts and methods can be easily constructed utilizing our graphical user interface

As a technology base we chose Selenium Webdriver, which has support of the largest browser vendors and is a widely used and well maintained Open Source tool. This is completed by the also Open Source Appium -framework to enable Selenium -based testing on mobile devices.

We combined these algorithms and technologies to Ixonos Visual Test(TM), which is a powerful set of tools for making testing easier both for test engineers and developers. With our tool you can plan, create, plan and maintain test scripts and test assets more visually. You can produce easily maintainable Page Models simply by browsing your web or mobile application. We have support for dynamic locators, javascript, AJAX and other special elements already implemented. We even have a solution for accessing HTML5 canvas elements from the test scripts; something at least we have not seen before. Everything is done with a modern powerfuI UI and the generated scripts are standard Selenium Webdriver format.

The best part is that the our tools also makes it possible to automatically detect changes to web pages. Detected changes (new and missing elements, broken methods) are visualized on top of the web page (see picture) and the tool even proposes fixes for those.

One of cool things is that you can generate tests graphically using a model graph UI that defines page model transitions and methods which are used there. The tool will go through the model graph and make test cases based on it.

To see introduction video, watch this:

And to witness the same approach applied to Android devices watch this:

Got interested? Visit our product pages for more information and a free trial Windows/Linux version.

And stay tuned for next innovations!

Anssi Pekkarinen, Solution Architect/Lead Test Automation Consultant - Ixonos Plc