From: Hugo V. <hvw...@ya...> - 2005-09-09 17:16:26
|
--- Aivils Stoss <ai...@un...> wrote: > On Piektdiena, 9. Septembris 2005 13:23, you wrote: > > Hi, > > > > I have an app that writes procfs status to > keyboard > > leds. Like: > > > > ... > > ioctl ( ttys[i].fd, KDSETLED, savedleds|led ); > > ... > > > > WITH hijacled it does not work. > > > > WITHOUT hijacled it does work. And capslock > numlock > > and scrolllock still work on both keyboards. > > But hijacled was intentionally created for that. > hijacled isolate keyboards LED's from old /dev/ttyXX > ioctl's. If Your 1st X/console don't use faketty, > then code above works fine. > > Normal kernel: You plug in 12 keyboards and press > CapsLock on 1st - remaider 11 keyboards switch LED's > as 1st one. You press key on twelfth and it goes to > console. > > hijacled: You plug in 12 keyboards and start single > X > on /dev/fttyXX as secondary head. Now You press > CapsLock on 1st - remaider 10 keyboards switch LED's > as 1st one, but twelfth was opened by X via faketty > does not respond to 1st keyboard keypress. That > twelfth > is grabed by faketty. You press key on twelfth and > it > goes to X instead console. While /dev/fttyXX is not > opened every keyboard is ordinary. Just close all > /dev/fttyXX and check out Your code. Good explanation. In any case: with faketty like this: lrwxrwxrwx 1 root root 10 2005-09-09 01:51 /dev/tty50 -> /dev/ftty1 lrwxrwxrwx 1 root root 10 2005-09-09 01:51 /dev/tty51 -> /dev/ftty0 and gdm running X1 to vt51 and X0 to vt7 (AGP TNT2 + MX-440 PCI) and hijacled NOT running, I can write to LEDs of tty1-7 and they function. I can hit caps lock on both kbds and get the LED on. But I cannot write to tty51 (cannot open...) nor to tty50 (vc's don't switch). With Ruby I could write to tty17 that X1 was running. Hugo __________________________________________________ Do You Yahoo!? Tired of spam? Yahoo! Mail has the best spam protection around http://mail.yahoo.com |