UNIX Terminals. Terminology. Serial Ports. Serial connection. Terminal Types. Terminal Types
|
|
- Vanessa Cole
- 6 years ago
- Views:
Transcription
1 Terminology UNIX Terminals bps Bits per second, the rate at which data is transmitted baud The number of electrical state transitions that may be made in a period of time DTE Data Terminal Equipment your computer DCE Data communication Equipment modem RS-232 The common EIA standard for serial communication. There are also RS-423, RS-422, RS-485 Serial Ports Is an asynchronous port which transmit one bit of data at a time Are bi-directional Most of them obey some variant of the RS-232 standard Signal voltage is +/- 15V DC +/- 5V is the common value Serial ports relay on a special controller chip, the Universal Asynchronous Receiver Transmitter (UART) IT takes the parallel output of the computer and transform it into serial form of transmission. Speed usually is up to 115 Kbps Cable length is typically 50 feet maximum Serial connection Usually the serial connection are DB25 and DB9: Dumb Terminals Terminal Types Are specialized pieces of hardware that let you connect to computers over serial lines Called dumb because they have only enough computational power to display, send and receive text Digital Equipment Corporation s VT-100 (one of the most famous ones) Terminal Types Pcs acting as Terminals Any PC can act as a dumb terminal using a terminal emulation software. On FreeBSD tip(1) can be used On LINUX minicom(1) X11 Terminals Doesn t connect over serial line but use pseudo terminals Can display any X application 1
2 Terminal Modes - Cannonical Terminal input is processed as lines The terminal driver return one line per read request A line is delimited by a newline \n character end-of-file (EOF) character end-of-line (EOL) character Erase and kill processing occur when either of two special characters ERASE and KILL are received Terminal Mode - Noncanonical Input bytes are not assembled into lines Erase and kill processing does not occur The canonical mode is the default This can be seen when we use the read built in command of the shell Programs that manipulate the entire screen use non-canonical mode Input and Output queues There is an implied link between the input queue and the output queue when echo is enabled In most UNIX systems when the input queue is full the bell character is echoed Special Characters INTR Generate SIGINT signal which is sent to all processes in the foreground process group for which the terminal is the controlling terminal Quit Generate SIGQUIT ERASE In canonical mode erase the last character in the current line Special Characters (cont) KILL In canonical mode deletes the entire line EOF In canonical mode cause all the bytes waiting to be read to be passed immediately to the process without waiting to new line NL In canonical mode this is the line delimiter EOL An additional line delimiter Special Characters (cont) SUSP Generate SIGSTP signal to be sent to all the processes in the foreground STOP Special character on both input and output Can be used to temporary suspend output START The opposite of STOP CR \r from the C standard 2
3 Programming Interface All the terminal device characteristics that can be viewed/changed are in the termios structure (termios.h) struct termios { tcflag_t c_iflag; /* input flags */ tcflag_t c_oflag; /* output flags */ tcflag_t c_cflag; /* control flags */ tcflag_t c_lflag; /* local flags */ cc_t c_cc[nccs]; /* control chars */ speed_t c_ispeed; /* input speed */ speed_t c_ospeed; /* output speed */ ; Programming interface Input flags control the input of characters be the terminal device drive Output flags control the driver output (perform output processing, map new line to CR/LF..) Control flags effects the RS232 serial lines (ignore modem status line, one or two stop bits per character..) Local Flags effects the interface between the driver and the user (echo on or off, visually erase characters, enable terminal generated signals..) #define MAX_PASS_LEN 8 /* max #chars for user can enter */ Programming Interface tcgetattr fetch attributes (termios structure) tcsetattr set attributes (termios structure) cfgetispeed get input speed cfgetospeed get output speed cfsetispeed set input speed cfsetospeed set output speed tcdrain wait for all output to be transmitted tcflow suspend transmit or receive tcflush flush pending input and/or output tcsendbreak send BREAK character tcgetpgrp get foreground process group ID tcsetpgrp set foreground process group ID char *getpass(const char *prompt) { static char buf[max_pass_len + 1]; /* null byte at end */ char *ptr; sigset_t sig, sigsave; struct termios term, termsave; FILE *fp; int c; if ((fp = fopen(ctermid(null), "r+")) == NULL) return NULL; setbuf(fp, NULL); sigemptyset(&sig); sigaddset(&sig, SIGINT); sigaddset(&sig, SIGTSTP); sigprocmask(sig_block, &sig, &sigsave); tcgetattr(fileno(fp), &termsave); term = termsave; term.c_lflag &= ~(ECHO ECHOE ECHOK ECHONL); tcsetattr(fileno(fp), TCSAFLUSH, &term); fputs(prompt, fp); ptr = buf; while( (c = getc(fp))!= EOF && c!= '\n') { if(ptr < &buf[max_pass_len]) *ptr++ = c; *ptr = 0; putc('\n', fp); tcsetattr(fileno(fp), TCSAFLUSH, &termsave); sigprocmask(sig_setmask, &sigsave, NULL); fclose(fp); int main(int argc, char **argv) { char *pass_ptr; pass_ptr = getpass("enter Password:"); if(pass_ptr) printf("got password %s\n", pass_ptr); return 0; return (buf); Pseudo Terminals Pseudo Terminals A pseudo terminal is a pair of character devices master and slave The slave device provides to a process an interface identical to that of a terminal But this time there is no hardware device behind the device driver Instead another process is manipulating it through the master half of the pseudo terminal User Process Read/Write Functions Pseudo Terminal Master User Process Read/Write Functions Terminal Line Discipline Pseudo Terminal Slave 3
4 Pseudo Terminal script example Serial Console Many OS have the ability to boot the system with only a dumb terminal on a serial port as a console Useful for Installing machines which has not keyboards or screen attached Debugging kernels and device drivers Terminal servers can be used to manage/debug many pc s connected only to a serial line /etc/ttys Holds information that is used by various routines to initialize and control the use of terminal special files This information can be read using the getttyent(3) routine There is one line per special device file Field 1: Name of terminal special file Field 2: Command to execute for the line Field 3: Type of terminal connected, normally the name is found in /etc/termcap Field 4: Flags A flag value of on or off specify that init should (shouldn t) execute the command given in the second field A flag value of secure allows users with uid 0 to login on this line /etc/tty Example Root login on console at 1200 baud console "/usr/libexec/getty std.1200" vt100 on secure Virtual Terminal ttyv1 "/usr/libexec/getty Pc" cons25 on secure Serial Terminal ttyd0 "/usr/libexec/getty std.9600" dialup off secure Dialup at 1200 baud, no root logins ttyd0 "/usr/libexec/getty d1200" dialup on group=dialup # /etc/termcap Terminal capability data base The termcap file is a database file describing terminals Terminals are described by giving a set of capabilities that they have Describing how operations are performed Example: (the kermit terminal) kermit standard kermit:\ :bs:cd=\ej:ce=\ek:cl=\ee:cm=\ey%+ %+ :co#80:ho=\eh:li#24:nd=\ec:up=\ea:\ :ku=^k:kd=^j:kl=^h:kr=^l:kh=^^:ma=^hh\012j^kk^ll^^h:\ :is=k0 Standard Kermit \n: Termcap Example bs uses ^H to move left cd clear to end of screen ce clear to end of line cl clear screen and home cursure cm move to row #1 and culumns #2 co number of columns in a line ho home cursor li number of lines on screen or page nd move right one space 4
5 tty returns user terminal name On an xterm: ttyp9>>tty /dev/ttyp9 On a virtual terminal: ttyv1 On a serial line: ttyd0 stty set an option for a terminal stty set or reports on terminal characteristics for the device that is its standard input stty 9600 even tabs stty intr ^C kill ^U erase ^H -tabs When stdin is a file: ttyp9>>tty < typescript not a tty stty a ttypa>>stty -a speed 9600 baud; 24 rows; 80 columns; lflags: icanon isig iexten echo echoe -echok echoke -echonl echoctl -echoprt -altwerase -noflsh -tostop -flusho pendin -nokerninfo -extproc iflags: -istrip icrnl -inlcr -igncr ixon -ixoff ixany imaxbel -ignbrk brkint -inpck -ignpar -parmrk oflags: opost onlcr -ocrnl -oxtabs -onocr -onlret cflags: cread cs8 -parenb -parodd hupcl -clocal -cstopb -crtscts -dsrflow -dtrflow -mdmbuf cchars: discard = ^O; dsusp = ^Y; eof = ^D; eol = <undef>; eol2 = <undef>; erase = ^?; erase2 = ^H; intr = ^C; kill = ^U; lnext = ^V; min = 1; quit = ^\; reprint = ^R; start = ^Q; status = ^T; stop = ^S; susp = ^Z; time = 0; werase = ^W; tset, reset terminal initialization First tset determine the type of the terminal you are using When invoked as reset tset sets/unset the follwing: turn on coked and echo mode turn off cbreak and raw mode turn on newline translation mode set all special characters to their default values Options: -e ch -i ch -k ch -S set the erase character to ch set the interrupt character to ch set the kill character to ch print the terminal type and termcap entry to stdout tset -S ttyp9>>tset -S Erase is backspace. xterm xterm vs100:li#65:kh=\eoh:@7=\eof:kb=^h:kd=^?:k1=\eop:k2=\eoq:k3=\eor:k4= \EOS:km:is=\E>\E[?1;3;4;5l\E[?7;8h\E[1;65r\E[65;1H:rs=\E>\E[?1;3;4;5l\E[?7;8h:k I=\E[2~:kN=\E[6~:kP=\E[5~:k6=\E[17~:k7=\E[18~:k8=\E[19~:k9=\E[20~:k;=\E[21~:k5= \E[15~:ve=\E[?25h:vi=\E[?25l:k0@:im@:ei@:F1=\E[23~:F2=\E[24~:ic=\E[@:IC=\E[%d@: ec=\e[%dx:al=\e[l:dl=\e[m:mi:dc=\e[p:al=\e[%dl:dl=\e[%dm:dc=\e[%dp:do=\e[b:cl=\ E[H\E[J:sf=\ED:as=\E(0:ae=\E(B:cm=\E[%i%d;%dH:nd=\E[C:up=\E[A:nw=\EE:ce=\E[K:cd =\E[J:so=\E[7m:se=\E[m:us=\E[4m:ue=\E[m:md=\E[1m:mr=\E[7m:mb=\E[5m:me=\E[m:sr=\ EM:sc=\E7:rc=\E8:cs=\E[%i%d;%dr:UP=\E[%dA:DO=\E[%dB:RI=\E[%dC:LE=\E[%dD:ct=\E[3 g:st=\eh:co#80:le=^h:bs:am:if=/usr/share/tabset/vt100:ho=\e[h:ac=llmmkkjjuuttvv wwqqxxnnpprr\140\140aa:ks=\e[?1h\e=:ke=\e[?1l\e>:ku=\eoa:kd=\eob:kr=\eoc:kl=\eo D:@8=\EOM:K1=\EOq:K2=\EOr:K3=\EOs:K4=\EOp:K5=\EOn:pt:vt#3:xn:ta=^I:ms:bl=^G:cr= ^M:eo:it#8:ut:RA=\E[?7l:SA=\E[?7h:ttyp9>> 5
Computer Center, CS, NCTU. Serial devices. Terminal Modem Mice
Serial Devices Serial devices Terminal Modem Mice 2 Serial standard (1) RS-232 standard on DB25 connector Electrical characteristics Meaning of each signal wire Ping assignment DB25P (male) DB25S (female)
More informationTerminal Modem Mice. Computer Center, CS, NCTU
Serial Devices Serial devices Terminal Modem Mice Computer Center, CS, NCTU 2 Serial standard (1) RS-232 standard on DB25 connector Electrical characteristics Meaning of each signal wire Ping assignment
More informationSYNOPSIS #include <termios.h> #include <unistd.h>
NAME termios, tcgetattr, tcsetattr, tcsendbreak, tcdrain, tcflush, tcflow, cfmakeraw, cfgetospeed, cfgetispeed, cfsetispeed, cfsetospeed, cfsetspeed get and set terminal attributes, line control, get and
More informationMore on Unix Shell SEEM
More on Unix Shell SEEM 3460 1 Shell Operations When a shell is invoked automatically during a login (or manually from a keyboard or script), it follows a preset sequence: 1. It reads a special start-up
More informationChapter 2 Unix Utilities for non-programmers
Chapter 2 Unix Utilities for non-programmers 1 Y U A N L O N G C S C 3 3 2 0 S Y S T E M L E V E L P R O G R A M M I N G F A L L 2 0 1 6 Updated based on original notes from Raj Sunderraman and Michael
More informationAN809 INTEGRATING THE CP210X VIRTUAL COM PORT DRIVER INTO THE ANDROID PLATFORM. 1. Introduction. 2. Materials. 3. Overview
INTEGRATING THE CP210X VIRTUAL COM PORT DRIVER INTO THE ANDROID PLATFORM 1. Introduction This document describes how to build an Android kernel and the steps needed to integrate the CP210x virtual COM
More informationCOMP 2355 Introduction to Systems Programming
COMP 2355 Introduction to Systems Programming Christian Grothoff christian@grothoff.org http://grothoff.org/christian/ 1 Terminal Programming Job Control Today 2 Why bother with text mode? Often only practical
More informationPL-2303 specific usb-uart serial communications manager for QNX Neutrino
Driver - Description devu-prolific2303-speed PL-2303 specific usb-uart serial communications manager for QNX Neutrino You must be root to start this driver. Syntax: devu-prolific2303 [[options] [u devicenr
More informationXNET AN X-WINDOWS BASED AX.25 PACKET NETWORK ANALYZER
XNET AN X-WINDOWS BASED AX.25 PACKET NETWORK ANALYZER File Name : ps.main24hours Title : ps.main24hours Creator : XV Version 3.00 Rev: 3/30/93 - by Jo Pages : 1 OPERATING MANUAL RICHARD PARRY, W9IF APPENDIX
More informationCommunication. Serial port programming
Applied mechatronics Communication. Serial port programming Sven Gestegård Robertz sven.robertz@cs.lth.se Department of Computer Science, Lund University 2017 Outline 1 Introduction 2 Terminal I/O programming
More informationSerial Programming Guide for POSIX Operating Systems 5th Edition. Michael R. Sweet Copyright , All Rights Reserved.
5th Edition Michael R. Sweet Copyright 1994 1999, All Rights Reserved. Table of Contents Introduction...1 Chapter 1, Basics of Serial Communications...3 What Are Serial Communications?...3 What Is RS
More informationPAS: A Printer Accounting System for Linux. Murali Thiyagarajah. School of Computer Science, Carleton University. Ottawa, Ontario K1S 5B6, CANADA
PAS: A Printer Accounting System for Linux Murali Thiyagarajah School of Computer Science, Carleton University Ottawa, Ontario K1S 5B6, CANADA 22 June 1995 Abstract There are many hardware solutions for
More informationLinux. 2 Linux 2.1 Linux. . Windows. ipx/spx netbeui Tcp/ip. Tcp/ip. modem. Linux. 48 Journal of Zhangzhou Teachers College Nat. Sci. General No.
2005 2 No. 2. 2005 48 Journal of Zhangzhou Teachers College Nat. Sci. General No. 48 : 1008-7826 2005 02-0037-05 Linux 1, 2 1., 363000 2., 350300 : linux. : linux ; ; : TP393.09 : A 1. Windows linux unix
More informationinterface serially with the machine (through RS-232), 25-pin connectors
Terminals Terminal Hardware Terminals are of three types: interface serially with the machine (through RS-232), 25-pin connectors memory-mapped terminals network terminals Serial-Line Terminals UARTs (Universal
More informationSerial Programming Guide for POSIX Operating Systems
Serial Programming Guide for POSIX Operating Systems 5th Edition, 4th Revision Copyright 1994 2004 by Michael R. Sweet Permission is granted to copy, distribute and/or modify this document under the terms
More informationStudy Guide Linux Terminals
Study Guide Linux Terminals Q1 - Keyboard shortcuts Match the following actions or meanings to the corresponding keyboard shortcuts. # Actions # Shortcuts 1 Interrupt the currently executing program 1
More information: Nemeus MM0xx family. Reference : MM0xx AT. History : v0.4
V.5/17 Product : Nemeus MM0xx family Doc : SW interface - AT commands Reference : MM0xx-140624 -AT History : v0.4 1 Table of contents 2 Document history... 6 3 References... 6 3.1 Compatibility... 6 3.2
More information(1) (2) (3) Host Host Host
Release Note for AIC SAS 6G 4U60swap Expander Apr 16, 2015 Changelog 04/16/2015 (firmware 1.11.9.4 + mfg 1.9.0.2 + firmware 1.11.10.2 + mfg 1.10.0.4 + mfg 1.10.1.4) - Part Number (B98-004U60E0110904 +
More informationUC-8100 Series Linux Software User s Manual
User s Manual Edition 4.0, May 2016 www.moxa.com/product 2016 Moxa Inc. All rights reserved. User s Manual The software described in this manual is furnished under a license agreement and may be used only
More informationRealPort on DG/UX. Setup Guide A
RealPort on DG/UX Setup Guide 92000314A Digi International Inc. 2002. All Rights Reserved The Digi logo is a trademark of Digi International Inc. All other brand and product names are the trademarks of
More informationExperiment Number: 02. Title: PC-to-PC communication through RS-232 port
R (2) N (5) Oral (3) Total (10) Dated Sign Experiment Number: 02 Title: PC-to-PC communication through RS-232 port OBJECTIVES: 1. To learn to perform PC-to-PC communication using the RS-232 port 2. To
More informationUC-8410A Series Linux Software User s Manual
User s Manual Edition 1.1, August 2016 www.moxa.com/product 2016 Moxa Inc. All rights reserved. User s Manual The software described in this manual is furnished under a license agreement and may be used
More informationStreams and Pipes. Along the Stream by Sharon France
Streams and Pipes Along the Stream by Sharon France Streams As a leaf is carried by a stream, whether the stream ends in a lake or in the sea, so too is the output of your program carried by a stream not
More informationRMU2 Linux Logic Controller User Manual
Automation & Control Solutions RMU2 Linux Logic Controller User Manual MKS Instruments. Automation & Control Solutions 1321 Rutherford Lane, Suite 200 Austin, TX 78753 Main: 512.719.8000 Fax: 512.719.8095
More informationArm-Based Computer Linux User s Manual for Debian 9
Arm-Based Computer Linux User s Manual for Debian 9 Edition 2.0, August 2018 www.moxa.com/product 2018 Moxa Inc. All rights reserved. Arm-Based Computer Linux User s Manual for Debian 9 The software described
More information... AIC 12G Expander Controller
Release Note for AIC SAS 12G HotSwap Expander July 14, 215 Changelog 7/14/215 (FW 1.12.1.7 + MFG 1.1..7) - Part Number (B98-XUXXE1217 + B98-XUXXG1C7) Old Part Number B98-XUXXE1216 is replaced by B98-XUXXE1217.
More informationHE-GE Linux USB Driver - User Guide. 1vv r2 03/25/2013
Disclaimer SPECIFICATIONS SUBJECT TO CHANGE WITHOUT NOTICE Notice While reasonable efforts have been made to assure the accuracy of this document, Telit assumes no liability resulting from any inaccuracies
More informationHow to Implement a Web-based Terminal with Docker
How to Implement a Web-based Terminal with Docker 2015-03-14 Who am I 杜万 (Vangie Du) Full-Stack Web Developer Linux fans Working on Coding@Shanghai About Coding Project Management Source Code Management
More informationLesson Module Checklist Slides WB converted. Flash cards Page numbers 1 st minute quiz Web Calendar summary Web book pages Commands
Lesson Module Checklist Slides WB converted Flash cards Page numbers 1 st minute quiz Web Calendar summary Web book pages Commands Lab tested and uploaded Tech file email for Lab 9 ready Lock/unlock turnin
More informationAdvanced Unix Concepts. Satyajit Rai
Advanced Unix Concepts Advanced Unix Concepts Satyajit Rai March 17, 2003 March 22, 2003 KReSIT, IIT Bombay 1 Contents Contents Advanced Unix Concepts.......... 1 Contents.................. 2 Process Creation..............
More informationRich's lesson module checklist
Rich's lesson module checklist Slides and lab posted WB converted from PowerPoint Print out agenda slide and annotate page numbers Flash cards Page numbers 1 st minute quiz Web Calendar summary Web book
More informationRich's lesson module checklist Last updated 4/18/2018
Rich's lesson module checklist Last updated 4/18/2018 Zoom recording named and published for previous lesson Slides and lab posted Print out agenda slide and annotate page numbers Flash cards 1 st minute
More informationCS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2018 Lecture 20
CS24: INTRODUCTION TO COMPUTING SYSTEMS Spring 2018 Lecture 20 LAST TIME: UNIX PROCESS MODEL Began covering the UNIX process model and API Information associated with each process: A PID (process ID) to
More informationRaspberry Pi System Software Reference
TECHNOLOGY IN ACTION Raspberry Pi System Software Reference AN INDISPENSABLE GUIDE TO LINUX ON THE RPI, FROM MASTERING THE RASPBERRY PI Warren Gay For your convenience Apress has placed some of the front
More informationAdvanced Unix/Linux System Program. Instructor: William W.Y. Hsu
Advanced Unix/Linux System Program Instructor: William W.Y. Hsu CONTENTS Process Groups Sessions Signals 5/10/2018 INTRODUCTION TO COMPETITIVE PROGRAMMING 2 Login process 5/10/2018 ADVANCED UNIX/LINUX
More informationIntroduction to Unix
Introduction to Unix Frank G. Fiamingo Linda DeBula Linda Condron University Technology Services The Ohio State University August 14, 1996 1997 Frank Fiamingo, Linda DeBula and Linda Condron, University
More informationCS 33. Signals Part 2. CS33 Intro to Computer Systems XXIV 1 Copyright 2016 Thomas W. Doeppner. All rights reserved.
CS 33 Signals Part 2 CS33 Intro to Computer Systems XXIV 1 Copyright 2016 Thomas W. Doeppner. All rights reserved. Job Control $ who foreground job $ multiprocessprogram ^Z foreground job stopped $ bg
More information8086 Interrupts and Interrupt Responses:
UNIT-III PART -A INTERRUPTS AND PROGRAMMABLE INTERRUPT CONTROLLERS Contents at a glance: 8086 Interrupts and Interrupt Responses Introduction to DOS and BIOS interrupts 8259A Priority Interrupt Controller
More informationQNX Momentics DDK. Character DDK. For targets running QNX Neutrino 6.3 or later. 2005, QNX Software Systems Ltd.
QNX Momentics DDK Character DDK For targets running QNX Neutrino 6.3 or later 2005, QNX Software Systems Ltd. QNX Software Systems Ltd. 175 Terence Matthews Crescent Kanata, Ontario K2M 1W8 Canada Voice:
More informationQC Linux USB Driver - User Guide 1vv r7 04/11/2014
QC Linux USB Driver - User Guide Disclaimer SPECIFICATIONS SUBJECT TO CHANGE WITHOUT NOTICE Notice While reasonable efforts have been made to assure the accuracy of this document, Telit assumes no liability
More informationBasic POSIX signal concepts
Basic POSIX signal concepts Last modification date: 02.11.2015 Note: The material does not cover real-time signal generation/delivery and thread-specific signal handling 1 POSIX signal Signal - a mechanism
More informationCSCI 8530 Advanced Operating Systems. Part 9 Device Management
CSCI 8530 Advanced Operating Systems Part 9 Device Management Updated 10/11/2016 Location of Device Management in the Hierarchy Ancient History Each device had unique hardware interface Code to communicate
More informationINSTALLING INSTALLING INSTALLING
MVCS Serial Communications Kernel Level Driver Installation Guide January 2006 0890509-100 READ READ READ ME ME ME BEFORE BEFORE BEFORE INSTALLING INSTALLING INSTALLING THIS THIS THIS PRODUCT PRODUCT PRODUCT
More informationLecture 13: I/O I/O. Interrupts. How?
Lecture 13: I/O I/O Interrupts MS-DOS Function Calls Input,Output, File I/O Video Keyboard Getting data into your program: define it in the data area use immediate operands Very limiting Most programs
More informationSystem Programming. Introduction to Unix
Content : by Dr. B. Boufama School of Computer Science University of Windsor Instructor: Dr. A. Habed adlane@cs.uwindsor.ca http://cs.uwindsor.ca/ adlane/60-256 Content Content 1 Introduction 2 3 Introduction
More informationCS631 - Advanced Programming in the UNIX Environment. Process Groups, Sessions, Signals
CS631 - Advanced Programming in the UNIX Environment Slide 1 CS631 - Advanced Programming in the UNIX Environment Process Groups, Sessions, Signals Department of Computer Science Stevens Institute of Technology
More informationCSE506: Operating Systems CSE 506: Operating Systems
CSE 506: Operating Systems What Software Expects of the OS What Software Expects of the OS Shell Memory Address Space for Process System Calls System Services Launching Program Executables Shell Gives
More informationCSE506: Operating Systems CSE 506: Operating Systems
CSE 506: Operating Systems What Software Expects of the OS What Software Expects of the OS Memory System Calls System Services Launching Program Executables Shell Memory Abstraction CSE506: Operating Systems
More informationCS 3113 Introduction to Operating Systems Midterm October 11, 2018
General instructions: CS 3113 Introduction to Operating Systems Midterm October 11, 2018 Please wait to open this exam booklet until you are told to do so. This examination booklet has 10 pages. You also
More informationCS 3113 Introduction to Operating Systems Midterm October 11, 2018
General instructions: CS 3113 Introduction to Operating Systems Midterm October 11, 2018 Please wait to open this exam booklet until you are told to do so. This examination booklet has 10 pages. You also
More informationAssignment 1. Teaching Assistant: Michalis Pachilakis (
Assignment 1 Teaching Assistant: Michalis Pachilakis ( mipach@csd.uoc.gr) System Calls If a process is running a user program in user mode and needs a system service, such as reading data from a file,
More informationNAME telnet - user interface to the TELNET protocol. SYNOPSIS telnet [[options ] host [ port ]]
NAME telnet - user interface to the TELNET protocol SYNOPSIS telnet [[options ] host [ port ]] DESCRIPTION telnet is used to communicate with another host using the TELNET protocol. If telnet is invoked
More informationHW 1: Shell. Contents CS 162. Due: September 18, Getting started 2. 2 Add support for cd and pwd 2. 3 Program execution 2. 4 Path resolution 3
CS 162 Due: September 18, 2017 Contents 1 Getting started 2 2 Add support for cd and pwd 2 3 Program execution 2 4 Path resolution 3 5 Input/Output Redirection 3 6 Signal Handling and Terminal Control
More informationSender Receiver Sender
EEE 410 Microprocessors I Spring 04/05 Lecture Notes # 19 Outline of the Lecture Interfacing the Serial Port Basics of Serial Communication Asynchronous Data Communication and Data Framing RS232 and other
More informationMost of the work is done in the context of the process rather than handled separately by the kernel
Process Control Process Abstraction for a running program Manages program s use of memory, cpu time, and i/o resources Most of the work is done in the context of the process rather than handled separately
More informationbash, part 3 Chris GauthierDickey
bash, part 3 Chris GauthierDickey More redirection As you know, by default we have 3 standard streams: input, output, error How do we redirect more than one stream? This requires an introduction to file
More informationVirtual Terminal Apps telnet/rlogin
Virtual Terminal Apps telnet/rlogin TCP/IP class 1 outline intro telnet architecture nvt option negotiation rlogin what else? 2 intro - network terminals telnet - TCP/IP classic application, RFC 854, 1983
More informationEach terminal window has a process group associated with it this defines the current foreground process group. Keyboard-generated signals are sent to
Each terminal window has a process group associated with it this defines the current foreground process group. Keyboard-generated signals are sent to all processes in the current window s process group.
More informationFile Access. FILE * fopen(const char *name, const char * mode);
File Access, K&R 7.5 Dealing with named files is surprisingly similar to dealing with stdin and stdout. Start by declaring a "file pointer": FILE *fp; /* See Appendix B1.1, pg. 242 */ header
More informationCreating a Shell or Command Interperter Program CSCI411 Lab
Creating a Shell or Command Interperter Program CSCI411 Lab Adapted from Linux Kernel Projects by Gary Nutt and Operating Systems by Tannenbaum Exercise Goal: You will learn how to write a LINUX shell
More informationInternet of Things: Using MRAA to Abstract Platform I/O Capabilities
Internet of Things: Using MRAA to Abstract Platform I/O Capabilities Integrated Computer Solutions, Inc. Contents 1. Abstract... 3 2. MRAA Overview... 3 2.1. Obtaining MRAA APIs and API Documentation...
More informationEmbedded Systems and Software. Serial Communication
Embedded Systems and Software Serial Communication Slide 1 Using RESET Pin on AVRs Normally RESET, but can be configured via fuse setting to be general-purpose I/O Slide 2 Disabling RESET Pin on AVRs Normally
More informationPebbles Kernel Specification September 26, 2004
15-410, Operating System Design & Implementation Pebbles Kernel Specification September 26, 2004 Contents 1 Introduction 2 1.1 Overview...................................... 2 2 User Execution Environment
More informationLecture 7: Signals and Events. CSC 469H1F Fall 2006 Angela Demke Brown
Lecture 7: Signals and Events CSC 469H1F Fall 2006 Angela Demke Brown Signals Software equivalent of hardware interrupts Allows process to respond to asynchronous external events (or synchronous internal
More informationEmbedded Systems and Software
Embedded Systems and Software Serial Communication Serial Communication, Slide 1 Lab 5 Administrative Students should start working on this LCD issues Caution on using Reset Line on AVR Project Posted
More informationCS370 Operating Systems
CS370 Operating Systems Colorado State University Yashwant K Malaiya Fall 2016 Lecture 5 Slides based on Text by Silberschatz, Galvin, Gagne Various sources 1 1 User Operating System Interface - CLI CLI
More informationBeijer Electronics AB 2000, MA00453,
VT100 emulation This manual presents installation and handling of the driver VT100 to the terminals in the E-series. The functionality in the E-terminals and in MAC Programmer+ are described in the E-manual.
More informationDOS INT 21h - DOS Function Codes
Back To Home DOS INT 21h - DOS Function Codes The follow abridged list of DOS interrupts has been extracted from a large list compiled by Ralf Brown. These are available on any Simtel mirror (e.g. sunsite.anu.edu.au)
More information8051SERIAL PORT PROGRAMMING
8051SERIAL PORT PROGRAMMING Basics of Serial Communication Computers transfer data in two ways: Parallel Often 8 or more lines (wire conductors) are used to transfer data to a device that is only a few
More informationSoftware I: Utilities and Internals. What is UNIX?
Software I: Utilities and Internals Lecture 1 UNIX for Beginners What is UNIX? UNIX is a time-sharing operating system with userchosen shells (user interfaces) and one kernel (operating system core, which
More informationRIO for Linux v2.2.x
Release Note RIO for Linux v2.2.x Release v1.0 5600038-12 Specialix International Limited December 1999 1. Introduction This release note covers the installation and configuration of the RIO Driver for
More informationDNP/2110 Linux Starter Kit: First Steps
DNP/2110 Linux Starter Kit: First Steps The DIL/NetPC DNP/2110 starter kit contains everything you need to get started with your Intel PXA255 Xscale-based embedded networking application. The starter kit
More informationKilling Zombies, Working, Sleeping, and Spawning Children
Killing Zombies, Working, Sleeping, and Spawning Children CS 333 Prof. Karavanic (c) 2015 Karen L. Karavanic 1 The Process Model The OS loads program code and starts each job. Then it cleans up afterwards,
More informationUniversal Asynchronous Receiver Transmitter Communication
Universal Asynchronous Receiver Transmitter Communication 13 October 2011 Synchronous Serial Standard SPI I 2 C Asynchronous Serial Standard UART Asynchronous Resynchronization Asynchronous Data Transmission
More informationLesson Module Status Slides Whiteboard with 1st minute quiz
Lesson Module Status Slides Whiteboard with 1st minute quiz Flashcards Web Calendar summary Web book pages Commands Howtos Lab tested Lab template in depot Extra credit lab tested Lab template in depot
More informationCS24: INTRODUCTION TO COMPUTING SYSTEMS. Spring 2017 Lecture 19
CS24: INTRODUCTION TO COMPUTING SYSTEMS Spring 2017 Lecture 19 LAST TIME Introduced UNIX signals A kernel facility that provides user-mode exceptional control flow Allows many hardware-level exceptions
More informationCOMP 2718: The OS, Shell, Terminal, and Text
COMP 2718: The OS, Shell, Terminal, and Text By: Dr. Andrew Vardy Adapted from the notes of Dr. Rod Byrne Outline What is an Operating System? The Shell and Terminal How are Characters Encoded? Standard
More informationControlling RS-232 equipped devices using Raspberry Pi and C++
Joona Matikainen Controlling RS-232 equipped devices using Raspberry Pi and C++ Metropolia University of Applied Sciences Bachelor of Engineering Degree Programme in Information Technology Thesis 29 November
More informationCS246 Spring14 Programming Paradigm Files, Pipes and Redirection
1 Files 1.1 File functions Opening Files : The function fopen opens a file and returns a FILE pointer. FILE *fopen( const char * filename, const char * mode ); The allowed modes for fopen are as follows
More informationSection 4: Device Descriptions
Section 4: Device Descriptions This section of the manual describes the full set of Xinu device driver types available in Version 7.9 for an IBM PC fitted with a Serial Port and an ETHERNET Adapter. Each
More informationECE 598 Advanced Operating Systems Lecture 6
ECE 598 Advanced Operating Systems Lecture 6 Vince Weaver http://www.eece.maine.edu/~vweaver vincent.weaver@maine.edu 4 February 2016 Homework #2 was due Announcements Homework #3 will be released shortly
More informationBeagleBone Black USB Expansion RS232 Module Cape Coolgear, Inc. Version 1.1 September 2017 Model Number:
BeagleBone Black USB Expansion RS232 Module Cape Product Manual Coolgear, Inc. Version 1.1 September 2017 Model Number: USB-2COM-BB 2 USB-2COM-BB Product Manual Revision History Revision Date Author Comments
More informationPrograms. Program: Set of commands stored in a file Stored on disk Starting a program creates a process static Process: Program loaded in RAM dynamic
Programs Program: Set of commands stored in a file Stored on disk Starting a program creates a process static Process: Program loaded in RAM dynamic Types of Processes 1. User process: Process started
More informationCSCI0330 Intro Computer Systems Doeppner. Project Shell 2. Due: November 8, 2017 at 11:59pm. 1 Introduction 2
CSCI0330 Intro Computer Systems Doeppner Project Shell 2 Due: November 8, 2017 at 11:59pm 1 Introduction 2 2 Assignment 2 2.1 Stencil 2 2.2 Jobs vs. Processes 2 2.3 Foreground vs. Background 3 2.4 Specification
More informationMICROPROCESSOR TECHNOLOGY
MICROPROCESSOR TECHNOLOGY Assis. Prof. Hossam El-Din Moustafa Lecture 16 Ch.7 The 80386 and 80486 Microprocessors 21-Apr-15 1 System Descriptors The system descriptor defines information about the system
More informationGoals of this Lecture
I/O Management 1 Goals of this Lecture Help you to learn about: The Unix stream concept Standard C I/O functions Unix system-level functions for I/O How the standard C I/O functions use the Unix system-level
More information2009 S2 COMP File Operations
2009 S2 COMP1921 9. File Operations Oliver Diessel odiessel@cse.unsw.edu.au Last updated: 16:00 22 Sep 2009 9. File Operations Topics to be covered: Streams Text file operations Binary file operations
More informationMidterm Exam CPS 210: Operating Systems Spring 2013
Your name: Sign for your honor: Midterm Exam CPS 210: Operating Systems Spring 2013 The last page of this exam is a list of terms used in this class, and whose meanings you should know. You may detach
More informationSerial Communication Prof. James L. Frankel Harvard University. Version of 2:30 PM 6-Oct-2015 Copyright 2015 James L. Frankel. All rights reserved.
Serial Communication Prof. James L. Frankel Harvard University Version of 2:30 PM 6-Oct-2015 Copyright 2015 James L. Frankel. All rights reserved. Overview of the Serial Protocol Simple protocol for communicating
More informationI/O Management! Goals of this Lecture!
I/O Management! 1 Goals of this Lecture! Help you to learn about:" The Unix stream concept" Standard C I/O functions" Unix system-level functions for I/O" How the standard C I/O functions use the Unix
More informationI/O Management! Goals of this Lecture!
I/O Management! 1 Goals of this Lecture! Help you to learn about:" The Unix stream concept" Standard C I/O functions" Unix system-level functions for I/O" How the standard C I/O functions use the Unix
More informationProject #1 Exceptions and Simple System Calls
Project #1 Exceptions and Simple System Calls Introduction to Operating Systems Assigned: January 21, 2004 CSE421 Due: February 17, 2004 11:59:59 PM The first project is designed to further your understanding
More informationGetting Started. Running Utilities. Shells. Special Characters. Special Characters. Chapter 2 Unix Utilities for non-programmers
Chapter 2 Unix Utilities for non-programmers Graham Glass and King Ables, UNIX for Programmers and Users, Third Edition, Pearson Prentice Hall, 2003. Original Notes by Raj Sunderraman Converted to presentation
More informationContent. Input Output Devices File access Function of File I/O Redirection Command-line arguments
File I/O Content Input Output Devices File access Function of File I/O Redirection Command-line arguments UNIX and C language C is a general-purpose, high-level language that was originally developed by
More informationSUDO_PLUGIN(5) File Formats Manual SUDO_PLUGIN(5)
NAME sudo_plugin - Sudo Plugin API DESCRIPTION Starting with version 1.8, sudo supports a plugin API for policy and session logging. Plugins may be compiled as dynamic shared objects (the default on systems
More informationUSB-2COM-BB USER S MANUAL
USB-2COM-BB USER S MANUAL 2017 May Edition Titan Electronics Inc. Web: www.titan.tw The computer programs provided with the hardware are supplied under a license. The software provided should be used only
More informationProgramming in the MAXQ environment
AVAILABLE The in-circuit debugging and program-loading features of the MAXQ2000 microcontroller combine with IAR s Embedded Workbench development environment to provide C or assembly-level application
More informationAltering the Control Flow
Altering the Control Flow Up to Now: two mechanisms for changing control flow: Jumps and branches Call and return using the stack discipline. Both react to changes in program state. Insufficient for a
More informationOperating Systems. Project #2: System Calls
Operating Systems Project #2: System Calls Project #2: System Calls Objective Background Getting Started Using BIOS Routines Printing to the Screen via the BIOS (Interrupt 0x10) Reading from the Keyboard
More informationCOM(PCI/C-PCI)Linux/RT GPH Asynchronous Serial Comunications Driver Software for Linux/RTLinux. Help for Linux.
COM(PCI/C-PCI)Linux/RT GPH-4141 Asynchronous Serial Comunications Driver Software for Linux/RTLinux Help for Linux www.interface.co.jp -Contents- GPH-4141 Help for Linux Chapter 1 Introduction 4 1.1 Overview...4
More information