Solved

How do I write Embedded Linux Driver for nXn matrix keyboard & LCD?

Posted on 2010-08-23
6
882 Views
Last Modified: 2012-05-10
Hi,
I am attempting to write a 8 x 8 matrix keyboard driver for a open embedded linux platform, need help learning writing basic device drivers in linux and interfacing a 16 x 2 alphanumeric LCD based on the HD 44780 display controller.
I would like if someone would point me to links where i can understand Linux device driver development such as GPIO port usage etc.  This is for a embedded development platform.
Thanks
0
Comment
Question by:vinit_0932
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
6 Comments
 
LVL 5

Accepted Solution

by:
Kendor earned 250 total points
ID: 33498697
when I visited the courses rtos and embedded linux we had a pretty cool script done by our prof. unfortunately i don't have it as pdf. but there's good books out there (and i know that you know how to get them as pdfs once you know the title)
get this one:
http://www.amazon.de/s?ie=UTF8&keywords=9780132396554&index=blended
and this:
http://www.amazon.com/Embedded-Linux-Hardware-Software-Interfacing/dp/0672322269

furthermore the internet brings:
- http://free-electrons.com/doc/embedded_linux_kernel_and_drivers.pdf
- http://www.linuxjournal.com/article/7355


if you know german you'll love this:
https://ezs.kr.hsnr.de//TreiberBuch/html//
(it is the university level course in linux driver development)

i try to find some more stuff for you...

0
 

Author Comment

by:vinit_0932
ID: 33499274
Thanks Kendor for your links.
0
 
LVL 5

Expert Comment

by:Kendor
ID: 33499725
by the way - for the hd44780 there are drivers for sure...
check : http://lcdproc.org/
and: http://www.home.unix-ag.org/nils/lcd.html
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:vinit_0932
ID: 33500062
Hi Kendor,
I have had a look at the links for drivers you suggested but they all use either a serial or parallel port. The serial port essentially needs additional hardware but the parallel port driver in the second link may be useful...
Thanks again.
0
 
LVL 12

Assisted Solution

by:HappyCactus
HappyCactus earned 250 total points
ID: 33511456
If your driver is for your own use, you only need a way to send data and commands to the lcd controller. It depends on the processor you have and how the lcd controller is interfaced with the cpu (by using a local bus driven by gpio, or via a memory mapped bus line...)
Also, you need to decide how to control the lcd with software, using ioctl, write or both.
Take a basic linux device driver tutorial, and start with a very basic one. If you do not need to follow a standard interface, you are free to make decisions. Since it's an alpha numeric device, I think you do not need any standard interface (like a frame buffer interface) so the driver is potentially very simple.
Take a look to rubini's book "Writing linux device driver, 2nd edition", freely available on internet. You need to read the chapters about device drivers basics and character devices (you do not need interrupts or dma, I think).
Start modifying a working, and very basilar, driver. It's not too difficult.
0
 

Author Comment

by:vinit_0932
ID: 33517783
Thanks HappyCactus for your pointers on Linux Device Driver development.
Appreciate your inputs.
0

Featured Post

Free Tool: Path Explorer

An intuitive utility to help find the CSS path to UI elements on a webpage. These paths are used frequently in a variety of front-end development and QA automation tasks.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
USB Error 20 195
C++ :Change value from  DisableCMD registry 4 71
Test the speeds on my PC Drives 12 71
keep track of class structure 1 22
An Outlet in Cocoa is a persistent reference to a GUI control; it connects a property (a variable) to a control.  For example, it is common to create an Outlet for the text field GUI control and change the text that appears in this field via that Ou…
Summary: This tutorial covers some basics of pointer, pointer arithmetic and function pointer. What is a pointer: A pointer is a variable which holds an address. This address might be address of another variable/address of devices/address of fu…
The goal of this video is to provide viewers with basic examples to understand recursion in the C programming language.
The goal of this video is to provide viewers with basic examples to understand how to create, access, and change arrays in the C programming language.

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question