IBM
Contents Index Previous Next



Prerequisites to the Example


The Pager System

The SDL system that will be used for this tutorial is a pager system. A pager is a small hand-held device used for contacting people. It contains a radio receiver which is capable of receiving signals on a certain frequency consisting of short messages and telephone numbers.

The pager has also a sort of databank with a limited capacity for storing messages as well as a keypad and a display which serve as the interface to the user. The user has the option of scrolling through, reading and deleting the messages that are displayed on the small screen.

The keypad consists of three buttons; one for scrolling to the right, one for scrolling to the left and one for deleting. The pager emits a sound when a new message has arrived and also when the user makes an error or tries to do something which is not allowed. For example, trying to delete a message when the databank is empty or scrolling too far in a certain direction would be instances of illegal actions. Naturally, the pager can only hold a certain amount of messages and therefore at some point eventually fills up.

When the pager has reached its capacity a warning message is given for 2 seconds before the received message is displayed.

The SDL Overview shows the pager system divided into blocks and processes.

Figure 179 : An overview of the system Pager

Process Description
Database

The process Database manages the array of messages that makes up the pager's memory. It can store messages, retrieve them and delete them while maintaining order in the databank.

PagerCtrl

PagerCtrl basically handles all the input and output of the system. It receives input from the user via the keypad, messages from the radio receiver and information from the database regarding the status of saving and deleting.

Keypad

The process Keypad converts the input from the user into a signal and sends it to PagerCtrl.

Delivered Files

The files needed for this tutorial can be found in the directory:

<installation>/sdt/examples/cmicrotutorial/<platform>/p
ager

The project directory pager includes a sub directory called system. The directory system contains the SDL/GR files of the Pager system.

Furthermore, there is a directory prepared in parallel to the system directory. Here you can find an environment file env.c which can be used if you are not interested in programming the environment on your own.


http://www.ibm.com/rational
Contents Index Previous Next