home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / unix / programm / 5302 < prev    next >
Encoding:
Internet Message Format  |  1992-11-16  |  1.5 KB

  1. Xref: sparky comp.unix.programmer:5302 comp.sys.sun.misc:5286
  2. Newsgroups: comp.unix.programmer,comp.sys.sun.misc
  3. Path: sparky!uunet!mcsun!sun4nl!fwi.uva.nl!gene.fwi.uva.nl!bosman
  4. From: bosman@fwi.uva.nl (Cor Bosman)
  5. Subject: Sun KeyBoard help wanted
  6. Message-ID: <1992Nov16.183544.24814@fwi.uva.nl>
  7. Sender: news@fwi.uva.nl
  8. Nntp-Posting-Host: gene.fwi.uva.nl
  9. Organization: FWI, University of Amsterdam
  10. Date: Mon, 16 Nov 1992 18:35:44 GMT
  11. Lines: 22
  12.  
  13. Im trying to code something, but im not very succesfull with it sofar.
  14. Here's my problem:
  15.  
  16.   I want to get keyboard events (mainly keypresses) from the keyboard
  17. without disturbing other processes. So, whatever process I run
  18. (this includes processes that want input, like 'vi') my program
  19. needs to get all keypresses and perform some action with it.
  20. This, while leaving other processes unharmed. So for example
  21. 'vi' doesnt even notice my other process is reading the characters
  22. too. Is this possible? 
  23. Sofar ive played a bit with opening /dev/kbd. Then read() from it.
  24. This doesnt work. Somehow it has to be possible to read chars
  25. without other processes being disturbed by it. 
  26. Id appreciate any help/info. Maybe someone knows some code that
  27. already does this (or partly). Or has some other general hints.
  28.  
  29. Cor Bosman
  30. -- 
  31. |bosman@fwi.uva.nl_   //     | Honest Officer , had I known my health      |
  32. |-----------------\\ //AMIGA | stood in jeopardy I would never had lit one.|
  33. |  PE no.1         \\/       |             -MAXIM (of the Hells Angels)-   |
  34. |__________ Quickly Scotty,beam me up.There is no ox..y..ge..._____________|
  35.