Results 1 to 4 of 4
can you tell me something about char devices in linux and how to write a program to access this devices in our program...
- 09-06-2011 #1Just Joined!
- Join Date
- Sep 2011
- Posts
- 4
can you tell me something about char devices in linux
can you tell me something about char devices in linux and how to write a program to access this devices in our program
- 09-07-2011 #2
character devices are simply devices that the kernel reads from or writes to one character at a time (as distinct from block devices like disks that are read from or written to in blocks). Char devices include consoles, sound devices, ports, etc. Each is characterised by a unique pair of numbers called the major and minor device nodes.
If you do a full listing (ls -l) of the dev directory, you will see that the first character of the listing for each device is 'c' for char or 'b' for block.
You may find a char subdirectory in /dev. This lists all your char devices by their device nodes with links to the actual names."I'm just a little old lady; don't try to dazzle me with jargon!"
- 09-08-2011 #3Just Joined!
- Join Date
- Sep 2011
- Posts
- 4
how to program this devices using c
i want to write device driver for that char device
do u have any idea about this.
e.g
I want to access usb file system in my c program using kernel module.
- 09-13-2011 #4Linux Guru
- Join Date
- May 2011
- Posts
- 1,845
That would be a block device (e.g. /dev/sdb1), not a char device.


Reply With Quote
