The Linux4.TV Set-Top Box Open Source Project
The lowest-level software is linked with the kernel as various device drivers and provides low-level chip support for the Geode SC1200 CPU, Sigma Designs MPEG-2 decoder and the Philips SAA7114 NTSC decoder. A number of other drivers are included for the MacPHYTER network interface and stereo audio I/O as well. The kernel is based on version 2.4.3 and uses utilities and the filesystem design from Red Hat 6.2. At boot time, the system performs a normal Linux boot, executes device-driver initialization code, initializes the framebuffer to an NTSC or PAL-compatible screen size and then executes the /etc/rc startup script. There are a number of device drivers that must be available to the Linux operating system in order to provide the level of hardware support needed for the National API. These drivers include audio, video, DVB, DVD, video capture and graphics. In addition, supplementary drivers are needed to provide full support for MPEG, DVD and DVB demultiplexers.
The mid-level layer executes in user mode and implements the device-independent Video Middleware API used to provide a standard interface to the hardware included in the set-top box. The API includes functionality for controlling analog and digital video, selecting the video input, tuner channel selection, DVD, satellite DVB demultiplexing, video blanking interrupt and overlay capabilities. National's Video Middleware uses the Linux Video 4 Linux Two API underneath for interfacing with the kernel drivers. This layer abstracts the operating system and underlying hardware from the application program. Thus, the application programmer need not know which IOCTL for the sound driver sets its frequency; instead, a function call similar to AUD_SetFrequency( ) is used, which in turn communicates with the audio driver. The details of the driver interface are abstracted from the programmer. Following are descriptions of some of the functional areas of the Video Middleware API.
The audio subsystem API uses an abstract device called an audio player to control the playback of multiple applications while masking the differences of underlying hardware implementations. With audio players, applications are assured of consistent audio playback, regardless of the features or limitations of the target audio device. Audio also includes CD-ROM audio support for playing tracks from an audio CD (a CD-ROM is considered an audio source when an audio CD is inserted).
The video capture API enables applications to capture single or multiple frames of live video in real time and save them to a pixel map in graphics memory. Applications can then manipulate the captured images using the functionality of the graphics subsystem or other image-processing facilities.
The overlay subsystem APIs used in concert with the graphical-windowing system provide arbitration across multiple applications and control which applications are visible. In addition, the overlay subsystem provides a mechanism to overlay graphical information from the graphics subsystem over video.
The MPEG transport APIs provide traffic management of MPEG transport streams for digital video. MPEG transport streams are multiprogram data streams of interleaved digital video, audio and data. This API receives MPEG transport streams containing encoded content from the network and extracts the desired program from them. It then separates the audio, video and data components and routes them to the audio decoder, video decoder and CPU RAM, respectively.
The TV subsystem API provides a consistent interface to analog and digital broadcast services, so applications developed for one service easily can be extended to work with other services. The TV API also provides functionality that lets end users control interactive TV sets in familiar ways, such as changing the channels and adjusting volume.
Microwindows is used as the graphical windowing system, which easily integrates with the NTSC or PAL-compatible framebuffer provided by the kernel. A nice feature of the set-top box design is that the windowing system is not tied heavily to the hardware video functions. The windowing system primarily supports WebMedia and the applications layers, which use color keying and Video Middleware API calls in order to interface with video functions. Color keying works by drawing a rectangle in a special color using a standard graphical API, with the Geode's video overlay processor combining the video stream into the framebuffer contents defined by the color-keyed area. Thus, positioning or resizing the video stream is straightforward. WebMedia's use of FLTK allows the X Window System to be used as the windowing system, if desired.
One Click, Universal Protection: Implementing Centralized Security Policies on Linux Systems
Join editor Bill Childers and Bit9's Paul Riegle on April 27 at 12pm Central to learn how to keep your Linux systems secure.
Free to Linux Journal readers.Register Now!
|diff -u: What's New in Kernel Development||Aug 20, 2014|
|Security Hardening with Ansible||Aug 18, 2014|
|Monitoring Android Traffic with Wireshark||Aug 14, 2014|
|IndieBox: for Gamers Who Miss Boxes!||Aug 13, 2014|
|Non-Linux FOSS: a Virtualized Cisco Infrastructure?||Aug 11, 2014|
|Linux Security Threats on the Rise||Aug 08, 2014|
- diff -u: What's New in Kernel Development
- Security Hardening with Ansible
- NSA: Linux Journal is an "extremist forum" and its readers get flagged for extra surveillance
- Monitoring Android Traffic with Wireshark
- Tech Tip: Really Simple HTTP Server with Python
- [<Megashare>] Watch Mrs Brown's Boys Movie Online Full Movie HD 2014
- Readers' Choice Awards 2013
- RSS Feeds
- Linux Security Threats on the Rise
- IndieBox: for Gamers Who Miss Boxes!