BookRags.com Literature Guides Literature
Guides
Criticism & Essays Criticism &
Essays
Questions & Answers Questions &
Answers
Lesson Plans Lesson
Plans
My Bibliography Periodic Table U.S. Presidents Shakespeare Sonnet Shake-Up
Research Anything:        
History | Encyclopedias | Films | News | Create a Bibliography | More... Login | Register | Help
Not What You Meant?  There are 17 definitions for Device.

Device file

Print-Friendly
About 1 pages (354 words)

Bookmark and Share Questions on this topic? Just ask!

A device file or special file is an interface for a device driver that appears in a file system as if it were an ordinary file. This allows software to interact with the device driver using standard input/output system calls, which simplifies many tasks. Device files often provide simple interfaces to peripheral devices, such as printers. But they can also be used to access specific resources on those devices, such as disk partitions. Finally, device files are useful for accessing system resources that have no connection with any actual device such as data sinks and random number generators.

Unix special files

Main article: Device node

There are two general kinds of device nodes in Unix-like operating systems, known as character special files and block special files. The difference between them lies in how data written to them and read from them is processed by the operating system and hardware. These together can be called device special files in contrast to named pipes, which are not connected to a device but are not ordinary files either.

MS-DOS device files

MS-DOS borrowed the concept of special files from Unix, but renamed them device files. Because early versions of MS-DOS did not support a directory hierarchy, device files were distinguished from regular files by making their names reserved words. This means that certain file names are reserved for device files, and cannot be used to name new files or directories. The reserved names themselves are chosen to be compatible with "special files" handling of PIP command in CP/M. Some device files are listed below:

File name Purpose
CON Console device
PRN Printer
AUX Auxiliary device
COM0 COM1 COM2 COM3 COM4 COM5 COM6 COM7 COM8 COM9 Serial ports
LPT1 LPT2 PRN Parallel ports
NUL Bit bucket

Reserved words cannot even be used with extensions, so that file names like "nul.doc" and "con.htm" are invalid. This has been known to confuse some users or to cause programmatic construction of file names to fail.

View More Summaries on Device file
 
Ask any question on Device file and get it answered FAST!
Answer questions in BookRags Q&A and earn points toward
discounted or even FREE Study Guides and other BookRags products!
Learn more about BookRags Q&A
Copyrights
Device file from Wíkipedia. ©2006 by Wíkipedia. Licensed under the GNU Free Documentation License. View a list of authors or edit this article.

Article Navigation
Join BookRagslearn moreJoin BookRags




About BookRags | Customer Service | Report an Error | Terms of Use | Privacy Policy