
|
The QNX 4 Real-time
Operating System
von Frank Kolnick
Basis Computer Systems Inc.
960 Seiten, 14 Kapitel plus Schlagwortverzeichnis
erschienen September 1998
ISBN 0-921960-01-8
|
Mit der POSIX-Version werden QNX' einzigartige Eigenschaften für
großen Personenkreis attraktiv. Aber QNX ist viel mehr als eines der vielen
UNIX-Produkte mit möchte-gern Ambitionen. Es ist eine umfangreiche
Entwicklungsumgebung mit der Entwickler feinabgestimmte Lösungen für komplexe
Probleme lösen können. QNX macht dies durch eine einmalige Mischung aus
fStandardwerkzeugen und sorgfältig ausgewählten Erweiterung möglich.
Insbesondere baut QNX auf den Austausch von diskreten Informationspaketen
-- Messages -- auf, um so gut wie alle Arten von zwischenprozeßlicher
Kommunikation zu realisieren. Dieses Paradigma findet auf allen Ebenen der
Programmierung Anwendung: von Gerätetreibern über das File System bis zum LAN.
Diese Mächtigkeit geht mit einer erhöhten Komplexität und einer steileren
Lernkurve einher. Es ist von entscheidender Bedeutung, die fundamentalen
Konzepte zu verstehen, um QNX effektiv einsetzen zu können. Dieses Buch führt
Sie langsam von den Grundlagen zu den komplexeren Themen der Programmentwicklung und des Entwurf in einer verteilten, message-basierten Umgebung. Es geht über reine Programmierung hinaus und erläutert die Verwendung der zahlreichen QNX-Kommandos inklusive der Systemverwaltung und Plattenwiederherstellungsmaßnahmen. Das Buch ist eine Fundgrube sowohl für neue QNX-Programmierer als auch für erfahrene Entwickler.
Das Buch behandelt:
- Betriebssystemkonzepte: Prozesse, Messages, Timer, Shared Memor, etc.
- Programmentwicklung: Editieren, Übersetzen,
Debuggen, Backups
- Softwarearchitektur: Entwurf verteilter kooperativer Prozesse
- Echtzeit-Besonderheiten wie Prioritäten, Scheduling und Gerätetreiber
- Benutzung und Programmierung der Shell
- grundlegende und fortgeschrittene Kommandos (sowohl für allgemeines POSIX als auch speziell für QNX)
- Benutzung und Programmierung der drei Benutzeroberflächen von QNX
Der Text wird illustriert durch hunderte von Diagrammen und getesteten Quellcodebeispielen.
Frank Kolnick ist der Geschäftsführer von Basis Computer Systems, Inc., einer Beratungsfirma mit jahrzehntelanger Erfahrung im Bereich Betriebssyteme und Echtzeitanwendungen (ganz zu schweigen von technischer Dokumentation). Von ihm stammt das erste und meistverkaufte Buch über QNX2. Basis entwirft und implementiert außerdem Serversoftware für QNX Windows.
Vollständige Inhaltsangabe
1 Introduction
About QNX
First steps
About POSIX and standards
QNX, Unix, DOS and Windows
About this book
What to do next . . .
Typeface conventions
A reading list
2 Overview of QNX
The programming model
Main
features
Users
Processes
Relationships
States
Scheduling
Threads
Files, etc.
File
names
Access
rights
Types
of files
Operations
on files
DOS
files
Devices
The network
Virtual
machine
Physical/logical
numbering
Transparency
and coupling
LAN
media
Design
factors
Virtual
circuits
Inter-process communication
(IPC)
Shared
memory
Shared
files
Record-locking
Inter-process
messages
Proxies
Signals
Semaphores
Which
to use?
Names
Scope
To summarize . . .
3 Writing Programs
Getting around
Getting startedÑ-hello.c
Editing text
Buffers,
windows and registers
Help
Interaction
Navigating/scrolling
Copying
and pasting
Searching
Customizing
the editor
Summary
Etc.
Preamble: header files
and usage messages
use
message
Compiling
The
cc command
Command-line arguments
Environment variables
Programming
The
user environment
Testing and debugging
Tools
4 Managing Programs
Object libraries
The
librarian (wlib)
Shared
libraries
make
Dependency
lines
Macros
Default
rules
Command-line
Parallel
makes
Etc.
Archives and back-ups
Other
removable media
Simple
copying
Compressing
files
Archives
Back-up
procedures
Version control
Basic
operations
Information
The
finer points
Identifying
revisions
Releases
Branches
Etc.
5 Basic System Calls
Programming environment
Common
variables
Common
headers
System
limits
Environment
variables
Basic
program structure
Process creation and management
spawn
exec
fork
Environment
Status
and synchronization
Detecting
process death
Remote
processes
Process
environment
Time
Time
of day
Intervals
Pausing
Using
timers
Time-outs
Out-of-sequence
program flow
The
system clock
Very
short intervals
The Year 2000
The system
function
User password processing
Error codes
6 IPC System Calls
Global names
Registering
a name
Messages
Operations
on messages
Restricted
receives
Conditional
receives
Sending
by name
Messages
across the LAN
Proxies
Canned
messages
Non-blocking
sends
Remote
proxies
Device
managers
Shared memory
Contiguous
(DMA) memory
Semaphores
Lock
files
Signals
Side-effects
Blocking
a signal
Signal-handling
Sending
signals
Waiting
for signals
Internal
conditions
Time-outs
Busy loops
7 File I/O Calls
File creation and I/O
Opening
a file
Deleting
a file
Renaming
a file
Reading
and writing
Buffering
Directories
Random (direct) file access
Records
and structures
Unbuffered I/O
Which
to use?
Access
permissions
Mixed-style
I/O
Locking a file
Summary
Terminal Device I/O
POSIX
I/O
Low-level
control: ioctl ( )
Pseudo-terminals
Pipes and FIFOs
Pipes
FIFOs
Temporary files
A files properties
and status
Getting
file information
File
accessibility
Changing
file information
fcntl
( )
Duplicating
descriptors
Changing
the mode
Changing
ownership
Non-blocking I/O
The
select function
Misc.
File-system
functions
Files
and children
In a
network . . .
8 Designing Programs and Systems
Relationships: good, bad
and ugly
Resources and states:
system building blocks
Resources
States
Levels of software
Subsystems
Clusters
Clients
and servers
Global
names
Libraries
Configuration
Design notation
Stepping
back
Moving
data
Changes
in state
Summary
Concurrent resources
Pros
and cons
Design
Distributed
processing
Global
Time
Load-balancing
Whose
resource?
Synchronization
Sharing
resources
Semaphores
and critical regions
Summary
An example
Specification
Resources
Operations
Messages
A quick
review
More
to worry about . . .
Reality checks
Factors
to consider
Optimization
Real-time Programming
Time
Design
principles
Guidelines
Formal
methodologies
Events
Timing
Memory
Synchronization
Scheduling
Performance
Reliability and fault-tolerance
Redundancy
Watch-dogs
and time-outs
Deadlock
Summary
Device and resource interfaces
I/O
(Resource) managers
Summary
9 Testing & Debugging
The general idea
Divide
and conquer . . .
Source-code debuggingÑwd
Starting
up
User
Interaction
Command
line
Executing
the program
Looking
at data
Where
am I?
Keyboard
shortcuts
Post-mortem
debugging
Summary
Looking at files
hd
spatch
Comparing
files
Strings
Looking at other nodes
(ditto)
Customized debugging code
Leaving
clues
QNX
event tracing
Checking
integrity
So,
then what?
Sample
code
Optimizing: the final
step
Profiling
Diagnosing system problems
10 A QNX Survival Guide: The Basics
Commands
Command
format
Command
paths
Confirmation
prompts
User Interaction
Consoles
GUIs
Shells
Special
characters
Patterns
Redirecting
input & output
Pipes
Shell
scripts
Final
touches
Environment variables
11 A QNX Survival Guide: Common Commands
Text-handling commands
Text
editors
Looking
at text
Rearranging
text
Searching
for text
Putting
things in order
Comparing
files
Counting
words and lines
Text
files from DOS, etc.
Automated
editing (sed and awk)
File and directory commands
Changing
directories
A list
of files
Copying
files
Moving
and renaming files
Deleting
files
Searching
for files
File
times
Path
prefixes
Permissions
and ownership
Managing
directories
DOS
filesystems
QNX
2 filesystems
Processes and the state
of the system
System
information
Terminating
a process
Managing
processes
Printing
Connecting
a printer
Printing
directly to a printer
Formatting
the output
Spooling
Graphics
12 System Administration
Basic system administration
User
accounts
Setting
the time
Shutting
down
System
logging
Back-ups
Disk
errors
Communicating with users
write
(to one user)
wall
(write to all users)
mail
Running programs on schedule
Scheduling
jobs
Access
control
Multiple
crons
Checking the network
Shell programming
Built-in
commands
Configuration
User
profiles
The
/etc directory
Managing your disks
Disk
information
Diagnostics
Disk/file
errors
Recovering
files
Cant
boot?
Back-ups
13 More About Messages
Messages as data structures
Variable-length messages
Queuing messages
Message
agents
QNX
(POSIX) queues
Built-in
queuing
Summary
Large multi-part messages
Buffering
a message
Scattered
messages
Summary
QNX system messages
Process
death
14 Graphical User Interfaces
Overview
Windowing
systems
QNX
Windows
X Windows
Photon
Features
General guidelines
The
manual
The
prototype
The
contingency
Program
structure
Common GUI widgets
Operations
Window
Layout
Pointers
& carets
clicks
& drags
Individual
descriptions
QNX Windows
Architecture
Basic
Interaction
Customization
Tools
& Toys
Programming
The X Window System
Architecture
Basic
Interaction
Customization
Tools
& Toys
Programming
Photon
Architecture
Basic
Interaction
Customization
Tools
& Toys
Programming
Katalogeintrag
|