Wednesday, 19 October 2011

Terminals

5: Terminals

Reading from and Writing to the Terminal
Talking to the Terminal
The Terminal Driver and the General Terminal Interface 
  • Overview
  • Hardware Model
The termios Structure 
  • Input Modes 
  • Output Modes 
  • Control Modes 
  • Local Modes
Special Control Characters 
  • Terminal Speed 
  • Additional Functions 
Terminal Output 
  • Terminal Type 
  • Identify Your Terminal Type 
  • Using terminfo Capabilities 
Detecting Keystrokes 
  • Virtual Consoles 
  • Pseudo-Terminals

The Linux Environment

4: The Linux Environment 

Program Arguments 
  • getopt 
  • getopt_long 
Environment Variables 
  • Use of Environment Variables 
  • The environ Variable 
Time and Date 
Temporary Files 
User Information 
Host Information 
Logging 
Resources and Limits

Working with Files

3: Working with Files

Linux File Structure 
  • Directories
  • Files and Devices
System Calls and Device Drivers
Library Functions
Low-Level File Access

  • write
  • read
  • open
  • Initial Permissions
  • Other System Calls for Managing Files
  • The Standard I/O Library
  • fopen
  • fread
  • fwrite
  • fclose
  • fflush
  • fseek
  • fgetc, getc, and getchar
  • fputc, putc, and putchar
  • fgets and gets
Formatted Input and Output
  • printf, fprintf, and sprintf
  • scanf, fscanf, and sscanf
  • Other Stream Functions
  • Stream Errors
  • Streams and File Descriptors
File and Directory Maintenance
  • chmod
  • chown
  • unlink, link, and symlink
  • mkdir and rmdir
  • chdir and getcwd 
Scanning Directories
  • opendir
  • readdir
  • telldir
  • seekdir
  • closedir
Errors
  • strerror
  • perror
The /proc File System
Advanced Topics: fcntl and mmap
  • fcntl
  • mmap



Shell Programming

 2: Shell Programming

Why Program with a Shell?
A Bit of Philosophy
What Is a Shell?
Pipes and Redirection


  • Redirecting Output
  • Redirecting Input
  • Pipes
The Shell as a Programming Language
  • Interactive Programs
  • Creating a Script
  • Making a Script Executable
Shell Syntax
  • Variables
  • Conditions
  • Control Structures
  • Functions
  • Commands
  • Command Execution

Getting Started

 1: Getting Started

An Introduction to UNIX, Linux, and GNU
  • What Is UNIX?
  • What Is Linux?
  • The GNU Project and the Free Software Foundation
  • Linux Distributions
Programming Linux
  • Linux Programs
  • Text Editors
  • The C Compiler
  • Development System Roadmap

Introduction

Introduction

The Complete Beginning of Linux Programming Language Tutorial

Introduction 
 1: Getting Started                                                
 2: Shell Programming                                         
 3: Working with Files                                          
 4: The Linux Environment                                
 5: Terminals                                                    
 6: Managing Text-Based Screens with curses
 7: Data Management                                       
 8: MySQL                                                          
 9: Develop ment Tools                                    
10: Debugging                                                       
11: Processes and Signals
                                  
12: POSIX Threads
13: Inter-Process Communication: Pipes
14: Semaphores, Shared Memory, and Message Queues 
15: Sockets

16: Programming GNOME Using GTK+
17: Programming KDE Using Qt
18: Standards for Linux.