Monthly E-letter

Latest edition | Subscribe

More content, guided by database

A flexible hybrid database at work in the reference design of an electronic programming guide provides a cost-effective way to find and retrieve content from a multimedia device.

Cinema fans who get their flicks via mailed DVDs and bits streamed over the Internet might want to consider another option: Why not download your top movie picks onto Secure Digital (SD) cards at retail stores? MOD Systems, a tech firm backed by electronics giants Toshiba and NCR, has created a media-on-demand distribution system to make that happen.

MOD Systems, which has inked digital distribution deals with major studios, offers a software platform and interactive touch-screen kiosks that make it a breeze to browse, purchase, and download digital content. Forthcoming high-capacity SDXC cards will let users walk away from these kiosks with up to 2 terabytes of content – or hundreds of hours of programming – in their pockets.

This new technology poses a challenge: With so much content on a card, how can users navigate to find their desired movie, TV show, or music Video? Convenience, after all, is critical to success for consumer electronics.

To meet this need, MOD Systems turned to the Electronic Programming Guide (EPG), a type of embedded software application that enables users to zero in on relevant programming using metadata such as title, actor, genre, episode, director, TV season, theme, and keyword. MOD Systems designed EPG functions into its home media server firmware reference platform, a design that manufacturers are encouraged to adopt so that their set-top boxes, digital TVs, and other devices can play the SD cards. The EPG had to be highly memory- and CPU-efficient to reduce manufacturing costs. Processing latency could not exceed the unnoticeable level expected in consumer electronics.

To handle EPG metadata, MOD Systems incorporated an off-the-shelf Database Management System (DBMS) into its technology design. This decision underscored a growing trend of requiring DBMS for EPGs of any complexity. The database system is typically incorporated as a layer within the stack of set-top box embedded software to facilitate optimal data designs, support transactions and data integrity, accelerate performance, and minimize the impact of data management on RAM and CPU usage.

But “database system” is a broad product category. Most DBMSs – even many that are (somewhat confusingly) termed “embedded databases” – are designed for business software. Relatively few are suitable in resource-constrained EPGs, much less designed for this purpose. The following discussion highlights several key criteria that set-top box software developers have found useful when choosing a DBMS for programming guides to boost performance while minimizing development time and manufacturing costs.

Data type support

The database should offer broad data type support. For example, it should permit storage of variable length strings, a type that allows physical storage space to expand or contract, depending on the size of the stored item. Within an EPG, a show description can be nonexistent for the nightly news or lengthy for the synopsis of the Friday night movie.

Many DBMSs lack support for variable length strings. As a result, EPG designs must allocate resources based on the worst-case or maximum possible program description length, boosting memory and storage requirements.

Another critical data type is the object identifier, which is used to quickly match objects when a programming guide based on the popular carousel Model is updated. Yet another is the variable-length array, which provides flexibility in defining relationships between entities such as schedule and programs. The latter helps conserve space (memory and storage), while the former helps make updates fast and invisible to the end user.

Navigational API

Typically, the best API is navigational, meaning that interface functions embedded in the code work on the database one record at a time through looping, with application logic determining whether the current row is a member of the set of interest.

In contrast, the SQL database interface used widely in business applications offers a higher level of abstraction, but comes at the cost of processing overhead plus reliance on an optimizer that may introduce unpredictability in response times. Set-top box software developers, typically well-versed in third-generation languages such as C/C++, are usually happy to gain the efficiency and control that a navigational API provides.

Or consider a DBMS that provides both navigational and SQL APIs. While not ideal for real-time EPG processing, SQL can be fast and useful to generate ad hoc database queries and reports. And some SQL interfaces also map to the ODBC standard for interoperability, permitting data sharing between the EPG and a range of external systems.

In-memory and/or hybrid data storage

In-Memory Database Systems (IMDSs) store data in main memory, eliminating the I/O, caching, and data transfers that burden traditional DBMS performance. This makes IMDSs faster, and the streamlined design reduces CPU demands, both of which are big pluses for set-top boxes. For many EPGs, lack of persistent storage is a non-issue; if memory content is lost, the guide is easily downloaded from the cable head end or satellite transponder.

A few DBMSs such as McObject’s eXtremeDB Fusion offer a hybrid approach permitting both in-memory and persistent (disk and flash memory-based) storage, including, if desired, both types of storage in the same database instance. By enabling both kinds of storage, eXtremeDB Fusion (shown in Figure 1) spares developers the expense, learning curve, and support costs of incorporating multiple embedded database products across a product line. DIRECTV, for example, integrates eXtremeDB Fusion in both its disk-based and diskless set-top boxes, enabling it to deploy a unified software platform across these devices.

Figure1
Figure 1: McObject’s eXtremeDB Fusion combines on-disk and in-memory data storage in a single system, allowing developers to inexpensively integrate multiple database products across a product line.

Portability and reduced risk

A final DBMS attribute that benefits programming guides is portability. With embedded software’s lifespan often exceeding that of hardware, an EPG and its database component should be able to move seamlessly between operating environments. Available database source code is especially useful in accommodating new platforms.

Using a commercial off-the-shelf DBMS in MOD Systems’ reference design “removed risks and unknowns inherent in custom-written code, shortening development time and proving the cost-effectiveness of this COTS solution,” remarked Todd Duffin, the company’s technical program manager. The approach is also expected to provide consumers with faster access to programming information when they bring home movies and lower manufacturers’ costs in producing devices that will play the content. These advantages all bode well for the success of MOD Systems’ retail distribution system.

Ted Kenney, director of marketing for McObject (Issaquah, Washington), has a solid technical background with more than 12 years in the embedded systems, database, and enterprise software market segments. He has launched numerous products in the United States and international markets, and is a veteran of software, media, and restaurant industry start-ups. Ted holds a BA from Columbia University and an MBA from the University of California at Berkeley.

McObject
425-888-8505
www.mcobject.com

Silicon, software, and strategies for embedded devices
©MMX Embedded Computing Design.
An OpenSystems Media publication.