CONNECT WITH US

Implementing a web server on MCU hardware to address IoT data acquisition requirements

Contributed by Gordon Lunn 0

When you look at any electronic engineering magazine these days there is certainly never a shortage of articles to read that relate in some way or other to the Internet of Things (IoT). IoT-based systems will, as we all know, serve a broad spectrum of different purposes, but some things remain fundamental to them all. Whatever the context in which this technology is going to be used, it is certain that there will be a need for ongoing access to the large quantities of data that are being generated, so that subsequent analysis, manipulation and comparison can be undertaken. Much of this activity will be done once the data has been transported from where it was originally acquired back to the cloud.

In order to gain the required online connectivity for cloud-based operation it is necessary to specify a microcontroller unit (MCU) that encompasses the appropriate interface technologies - for wireline this could be through Ethernet, while for wireless this might be via use of Wi-Fi, ZigBee or Bluetooth protocols. As a greater variety of IoT applications emerge, each with their own very specific operational criteria, MCUs with much more expansive I/O capabilities will be called for.

pic

Figure 1. Industrial monitoring system with data being acquired from a sensor array

A simple scenario is detailed in Figure 1, where a web server is being used to compile data coming from an array of sensor devices. Here the open source lwIP (lightweight IP) platform furnishes the TCP/IP stack needed for Internet connectivity. The web server code running on the MCU provides a web page through which all the acquired data can be viewed and analysed by a suitably trained member of staff. Depending on the nature of the application, the data may need to be dealt with in real time (for example, in a factory production line inspection system, where if a problem is identified then action will be required immediately). In such use cases, system latency can present a major problem, not allowing enough time for an appropriate response to be made if a situation arises that could have serious consequences - such as expensive items of machinery being damaged or the workforce located in the vicinity being put in danger.

As already stated, currently the I/O resources of most MCUs are relatively limited and don't necessarily fully meet engineers' expectations. Devices are now being needed that offer a greater breadth of connectivity. At the same time they must be able to deliver elevated levels of operational performance too. Though a significant proportion of IoT applications will consist of large numbers of remotely-situated sensor nodes, with the focus being on maintaining low levels of power consumption and only supporting relatively limited data rates, there are plenty more scenarios besides these that will need the rapid transfer and processing of data. Key examples include home automation, industrial monitoring, utilities, etc.

In contrast to the vast majority of MCU solutions on the market, which are focused mainly on providing a feature set that is supported through software, the FT90X series MCUs from Bridgetek execute the most of their functionality via hardware. This allows performance-optimized operation that is not available using conventional generic MCU platforms to be benefited from and makes them an attractive option for data-intensive, low latency tasks like the one described above.

The advanced bridging technology built into these 32-bit RISC-based MCUs is pivotal to this. By making use of it, these devices can provide dedicated bridges between fast I/Os, allowing discrete elements of a design to gain access the most suitable hardware available. It means that interfacing of the different processing and I/O elements on the MCU can be done deterministic (without any latency problems arising). Using the company's proprietary FT32 core allows the ICs to deliver true zero wait state operation, reaching 310 DMIPS performance while running at a frequency of 100MHz. As well as accommodating both 10 Base-T (10Mbps) and 100 Base-TX (100Mbps) Ethernet connectivity, they also support CAN bus, I2C, USB and numerous other I/Os.

If we return to our earlier example, shown in Figure 1, an MM900EVxA board (which integrates an FT90X MCU) can be allocated the role of the web server needed to take care of all the data being generated by the array of sensors in real time. Universal plug-and-play (UPnP) is implemented onto this hardware, which allows for it to be listed under "Other Devices" within the "Network" section of Windows Explorer and similar Internet connectivity platforms. This makes installation quick and simple to accomplish. The relevant network settings can be stored on the non-volatile memory that has been incorporated into the MM900EVxA board. This information resides in the lwIP library. The HTTPD application reads static and server-side-include files from the virtual file system. Server-side-include files are processed in the HTTPD application and include data is added via an application call-back function.

(Editor's note: Gordon Lunn is technical marketing manager at Bridgetek.)

DIGITIMES' editorial team was not involved in the creation or production of this content. Companies looking to contribute commercial news or press releases are welcome to contact us.