Wednesday, November 11, 2009

Section 12.1. Introduction










12.1. Introduction


The embedded Linux examples demonstrate certain basic APIs for various operations. Additional APIs exist that offer other functionality. You should research the additional APIs on your own to determine whether there are other, better ways to perform the operations necessary for your particular embedded system.


One aspect of Linux you need to be familiar with is its thread model. The Linux API conforms to the key POSIX standard in the space, POSIX 1003.1c, commonly called the
pthreads
standard. POSIX leaves many of the implementation details up to the operating system implementer. A good source of information on pthreads is the book Pthreads Programming, by Bradford Nichols, Dick Buttlar, and Jacqueline Farrell (O'Reilly).


The version of embedded Linux used on the Arcom board is a standard kernel tree (version 2.6) with additional ARM and XScale support from the ARM Linux Project at http://www.arm.linux.org.uk.


A plethora of books about Linux and embedded Linux are available. Some good resources include Understanding the Linux Kernel, by Daniel P. Bovet and Marco Cesati (O'Reilly), Linux Device Drivers, by Alessandro Rubini and Jonathan Corbet (O'Reilly), and Building Embedded Linux Systems, by Karim Yaghmour (O'Reilly).


The instructions for configuring the embedded Linux build environment and building the example Linux applications are detailed in Appendix E. Additional information about using embedded Linux on the Arcom board can be found in the Arcom Embedded Linux Technical Manual and the VIPER-Lite Technical Manual.



In order to keep the examples in this chapter shorter and easier to read, we don't check the return values from function calls. In general, it is a good idea to validate all return codes. This provides feedback about potential problems and allows you, as the developer, to make decisions in the software based on failed calls. Basically, it makes your code more robust and, hopefully, less buggy.














No comments: