Download your favorite Linux distribution at LQ ISO.
Go Back > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Linux - Kernel This forum is for all discussion relating to the Linux kernel.


  Search this Thread
Old 01-12-2009, 11:45 PM   #1
Registered: Jan 2009
Location: Bangalore , India
Distribution: Fedora 12
Posts: 65

Rep: Reputation: 17
How to write a keyboard driver?

How to write a keyboard driver with interrupt driven? the platform is ARM and the interface is SRAMC with I/O mapped. What should my handler and read fucntions contains? and I want to know how to map the memory by using the ioremap() function? when exactly we have to use mmap()can you please help me out with some kinda psuedo code.
warm regards,
Ravi Kulkarni
Old 01-13-2009, 12:24 AM   #2
Senior Member
Registered: Jan 2005
Location: Nottingham, UK
Distribution: Mageia 5, Linux Lite
Posts: 4,312

Rep: Reputation: 209Reputation: 209Reputation: 209
Please don't double post!
Old 01-13-2009, 08:00 AM   #3
LQ Guru
Registered: Feb 2004
Location: SE Tennessee, USA
Distribution: Gentoo, LFS
Posts: 8,450
Blog Entries: 4

Rep: Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915Reputation: 2915
The best way to write any driver, after carefully checking to see that it has not already been done, is ... "use the source, Luke!" Find devices that are similar to the one you're considering, and study their working drivers. Remember that, most of the time, "writing new software" actually consists of adapting what is already out there.
Old 01-13-2009, 02:56 PM   #4
Registered: May 2007
Location: New Zealand
Distribution: Ubuntu
Posts: 88

Rep: Reputation: 16
Refer to the device driver writers bible - Linux Device Drivers published by O'Rielly. The second edition is available online here...
If you are using a 2.6 kernel you might want to track down the third edition which is slightly updated.
Old 01-15-2009, 12:40 AM   #5
Registered: Jan 2009
Location: Bangalore , India
Distribution: Fedora 12
Posts: 65

Original Poster
Rep: Reputation: 17
@above all

Yeah thanks . I av started to learn the LDD3 from Oreilly. I want some help on how to write a interrupt handler and a read fucntion interface is SRAMC memory in ARM processor with I/O mapped. Im starting to write a read fucntion for my driver but still have some glitches about what exactly it should do ! so lookin for some suggestions on it.
warm regards,
Ravi Kulkarni.


driver, keyboard

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to write vga card driver and lcd driver? bobby1112 Programming 2 09-29-2006 05:20 PM
How I can write winmodem driver? LinLove Linux - Hardware 1 05-31-2006 07:11 PM
how to write to keyboard buffer vineeth789 Programming 1 01-11-2006 03:30 PM
latin keyboard to write in japonese setlec_seta Linux - Software 0 01-22-2005 11:41 AM
How to write a Vietnamese keyboard program for Linux Namhh Linux - Software 2 10-15-2003 08:31 AM > Forums > Linux Forums > Linux - Software > Linux - Kernel

All times are GMT -5. The time now is 12:35 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration