LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 04-16-2006, 05:53 AM   #1
nawin_g
LQ Newbie
 
Registered: Nov 2005
Posts: 19

Rep: Reputation: 0
Keyboard Programming


hi,

i want to write a program that will make it look like i have pressed a key on the keyboard eventhough i havent physically pressed the key on the keyboard.

like the 'on screen keyboards' where when i press a button using mouse, for the system it looks like it has come from the keyboard.

can anyone please help me in this.. like the articles on net that would help in keyboard programming or the C library and functions and data structures that would help me in solving the above problem.

thanking in advance


PS: i want to write the program using C in LINUX

Last edited by nawin_g; 04-16-2006 at 05:55 AM.
 
Old 04-16-2006, 02:43 PM   #2
exvor
Senior Member
 
Registered: Jul 2004
Location: Phoenix, Arizona
Distribution: Gentoo, LFS, Debian,Ubuntu
Posts: 1,537

Rep: Reputation: 87
Your question is intresting. I wonder if you could just write the output of the program directly to the stdin stream but im not sure if other programs would get it or how long it would stay in the buffer.

Its possible that its not possible with C but would have to use assembly. In C the stdin stream is kinda just the black box of sorts for the keayboard and other input methods.

Last edited by exvor; 04-16-2006 at 02:45 PM.
 
Old 04-16-2006, 03:47 PM   #3
exvor
Senior Member
 
Registered: Jul 2004
Location: Phoenix, Arizona
Distribution: Gentoo, LFS, Debian,Ubuntu
Posts: 1,537

Rep: Reputation: 87
I found a program written in C for X11 that acomplishes this. Mabye you can study the source and figure out how its done.


here is the link
http://tubular42.org/PicoPeta/tapatap.html
 
Old 04-17-2006, 08:43 AM   #4
nawin_g
LQ Newbie
 
Registered: Nov 2005
Posts: 19

Original Poster
Rep: Reputation: 0
thanks a lot

thank u a lot. i have been googling for such a link. i am downloadin the code and hope will make sense out of the code.

thanks a lot again.
 
  


Reply



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
Difference between Userland programming and Kernel Programming.. meetsagittarian Programming 1 02-20-2006 12:26 AM
Difference between Top Down programming & Bottom up programming minil Programming 1 06-17-2005 02:42 AM
Programming Keyboard? gsibble General 2 02-03-2005 05:11 PM
programming the keyboard nerak Programming 3 04-19-2002 01:59 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 07:56 AM.

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