Skip to content

Linux driver which uses the keyboard leds in order to do two games. The purpose of this project was to know how the Linux kernel works

Notifications You must be signed in to change notification settings

arturobp3/Keyboard_Driver

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 

Repository files navigation

Keyboard Driver for Linux

How can I run this program?

Follow these steps to test the driver:

Compile "chardev_leds.c" file

You can use the makefile I provide you. In the directory where files are located, type:

make

Insert "chardev_leds.ko" in the Kernel

sudo insmod chardev_leds.ko

Create a new device file managed by the driver

sudo mknod -m 666 /dev/leds c 243 0

We can check if we did these steps well, typing:

cat /dev/leds

This command will print a message

Compile "leds_user.c" file

gcc -Wall -g leds_user.c -o leds_user

Run it

sudo ./leds_user

When you don't want to test this driver any more:

Remove "chardev_leds.ko" from the Kernel

sudo rmmod chardev_leds

Remove "/dev/leds"

sudo rm -r /dev/leds

About

Linux driver which uses the keyboard leds in order to do two games. The purpose of this project was to know how the Linux kernel works

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published