The time now is Thu 23 May 2013, 02:12
All times are UTC - 4 |
|
Page 1 of 2 [21 Posts] |
Goto page: 1, 2 Next |
| Author |
Message |
nooby
Joined: 29 Jun 2008 Posts: 9387 Location: SwedenEurope
|
Posted: Tue 14 Feb 2012, 07:07 Post subject:
How to toggle between laptop / external monitor? (Solved) Subject description: Using function keys in CLI |
|
Jemimah's pet for Wary and Racy worked well on Lupu528-004 too.
So thanks for making it and thanks for telling me and not giving up on me
old text
Sure I can do it manually on the Netbook's own keyboard
but to get rid of the noise from fan I have placed it on a shelf behind a screen
and I risk everything going down to the floor due to cramp space.
So to do the Fn+F6 on CLI, Terminal, Console, rxvt ? would be super!
I need to find out what number that key combination are or something?
How do I ask the terminal to tell and what command do I use to later
make use of that number it reveals? Would that be a unique number
for each computer or is it same all over the market?
Last edited by nooby on Fri 17 Feb 2012, 05:43; edited 2 times in total
|
|
Back to top
|
|
 |
nooby
Joined: 29 Jun 2008 Posts: 9387 Location: SwedenEurope
|
Posted: Wed 15 Feb 2012, 05:52 Post subject:
|
|
May I kindly ask for help with this one?
_________________
I'm a noob so I use Google Search of Puppy Forum
|
|
Back to top
|
|
 |
L18L
Joined: 19 Jun 2010 Posts: 1715 Location: Burghaslach, Germany
|
Posted: Wed 15 Feb 2012, 09:33 Post subject:
Re: How do I execute Fn+F6 on CLI, Terminal, Console, rxvt ? |
|
| nooby wrote: |
So to do the Fn+F6 on CLI, Terminal, Console, rxvt ?
|
F6 is a key on my keyboard.
But what is Fn
And what is Fn+F6
|
|
Back to top
|
|
 |
mahaju

Joined: 11 Oct 2010 Posts: 455 Location: between the keyboard and the chair
|
Posted: Wed 15 Feb 2012, 09:38 Post subject:
|
|
Fn key in laptop
|
|
Back to top
|
|
 |
nooby
Joined: 29 Jun 2008 Posts: 9387 Location: SwedenEurope
|
Posted: Wed 15 Feb 2012, 11:00 Post subject:
|
|
Yes the I should have explained that part. Sorry.
Full key keyboards have very many keys.
So when they have a very small one then
they let same key do many "Functions" so
you have a blue color or a green or something
that says Fn and then you hold that one down
and then press say F6 key in the most upper row.
That press makes the screen go black on my small Netbook.
Now I want to know what "number" is it I should use for
to send same signals through the CLI, Terminal, Console
or Urxvt whatever name it has to send same instruction
to shut down the screen on the Netbook but not on the external screen.
Sure I can stand up from the chair and lean over and reach hand inside
the shelf and try to see where these small keys are and use index finger
and thumb and wish me good luck by accident hit the right combination
But I risk that the external screen hit the floor when I try to get out of the
cramped place on the shelf. I live in a very small room so I had to
build the computer shack as a compact living mess
Three computers, three external screens and two DVD recorders and one
VHS and a Mixer board and three external keyboards and three mouses
and so on. Loudspearkers and so on. It is like finding a needle in a haystack to hit the right key combo.
_________________
I'm a noob so I use Google Search of Puppy Forum
|
|
Back to top
|
|
 |
trapster

Joined: 28 Nov 2005 Posts: 1966 Location: Maine, USA
|
Posted: Wed 15 Feb 2012, 18:35 Post subject:
|
|
In a console, try this:
| Code: | | xset dpms force off |
or
Try This
_________________ trapster
Maine, USA
Asus eeepc 1005HA PU1X-BK
Frugal install:Puppeee4.31 + 1.0, Puppy4.10 + Lupu52
Currently using Puppeee-1.0 AND lupu52 w/ fluxbox
|
|
Back to top
|
|
 |
nooby
Joined: 29 Jun 2008 Posts: 9387 Location: SwedenEurope
|
Posted: Thu 16 Feb 2012, 06:17 Post subject:
|
|
Haha that one was effective but sadly worked on both screens.
Sure it turned the internal screen off but also the external and
when I hit Esc to turn it on then it turned the internal one on too.
so one need to find the Fn +F6 number and only send that one.
Thanks for a good try though. Much appreciated.
_________________
I'm a noob so I use Google Search of Puppy Forum
|
|
Back to top
|
|
 |
Aitch

Joined: 04 Apr 2007 Posts: 6825 Location: Chatham, Kent, UK
|
Posted: Thu 16 Feb 2012, 07:17 Post subject:
|
|
nooby
maybe something like:
| Quote: | | xrandr --output VGA --mode 1024x768 |
or
| Code: | | xrandr | grep VGA | grep " connected " | egrep '16.0x|19.0x' |
to turn it off
just a thought...?
Aitch
|
|
Back to top
|
|
 |
amigo
Joined: 02 Apr 2007 Posts: 1759
|
Posted: Thu 16 Feb 2012, 07:26 Post subject:
|
|
Run 'xev', then press the desired key combination and xev will show you what code it is.
|
|
Back to top
|
|
 |
nooby
Joined: 29 Jun 2008 Posts: 9387 Location: SwedenEurope
|
Posted: Thu 16 Feb 2012, 09:30 Post subject:
|
|
Amigo,
I did not know how to apply that command.
Am I supposed to write xev and then do the Fn+F6 and then
hit enter or am I supposed to first do the xev and then hit enter
and then do Fn+F6?
I tested both. none of them gave an answer that I understand.
one of them gave this
KeymapNotify event, serial 28, synthetic NO, window 0x0,
keys: 40 0 0 0 16 0 0 0 0 0 0 0 0 0 0 0
0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0
KeyRelease event, serial 33, synthetic NO, window 0x2600001,
root 0x6d, subw 0x0, time 8813727, (584,282), root:(864,609),
state 0x0, keycode 36 (keysym 0xff0d, Return), same_screen YES,
" XLookupString gives 1 bytes: (0d) "
XFilterEvent returns: False
ClientMessage event, serial 39, synthetic YES, window 0x2600001,
message_type 0x10f (WM_PROTOCOLS), format 32, message 0x10d (WM_DELETE_WINDOW)
sh-4.1#
So maybe this is the answer?
keycode 36 (keysym 0xff0d, Return), So what am I suppose to do
to send that command using the terminal then?
Aitch you may be right but I understand too little to dare do such complicated things. What in that code only affect the internal screen
and not the external screen.
_________________
I'm a noob so I use Google Search of Puppy Forum
|
|
Back to top
|
|
 |
nooby
Joined: 29 Jun 2008 Posts: 9387 Location: SwedenEurope
|
Posted: Thu 16 Feb 2012, 09:42 Post subject:
|
|
Ubuntu has this text
| Quote: |
#
We are going to set up these keys. Open a terminal and type:
xev
#
Then press a multimedia key. If you are lucky it already has a keysym boundto it, so the output of xev for that key will be something like this:
KeyRelease event, serial 28, synthetic NO, window 0x3200001,
root 0xb7, subw 0x0, time 137010761, (693,138), root:(705,256),
state 0x10, keycode 136 (keysym 0x1008ff27, XF86Forward), same_screen YES,
XLookupString gives 0 bytes:
# The third row is the one of interest: it says that you have a keycode for that key (136) as well as keysym (XF86Forward). If you have a keysym then you can use that string to represent your key and use gnome keybindings or metacity keybindings to bind the relevant action to it. (See below).
#
But probably, you will find that the key does not have any keysym assigned to it, like this:
KeyRelease event, serial 28, synthetic NO, window 0x3200001,
root 0xb7, subw 0x0, time 137355697, (401,146), root:(413,264),
state 0x10, keycode 136 (keysym 0x0, NoSymbol), same_screen YES,
XLookupString gives 0 bytes:
# In this case you have to assign your keysym to the relevant keycode (136) (it does not match the kernel keycode for that keys, but it does not matter, it is by design). |
So that is in line with what amigo told me.
So what am I expected to do in the terminal to exec or what ever command to use to send that code to the linux OS?
from here
https://help.ubuntu.com/community/MultimediaKeys
_________________
I'm a noob so I use Google Search of Puppy Forum
|
|
Back to top
|
|
 |
postfs1

Joined: 27 Mar 2010 Posts: 831
|
Posted: Thu 16 Feb 2012, 15:50 Post subject:
Re: How do I execute Fn+F6 on CLI, Terminal, Console, rxvt ? |
|
| forum's user wrote: |
How do I execute Fn+F6 on CLI, Terminal, Console, rxvt ?
|
1)http://gunnarwrobel.de/wiki/Linux-and-the-keyboard.html
2)
http://stackoverflow.com/questions/3792487/sending-keyboard-input-to-a-program-from-command-line
http://stackoverflow.com/questions/954779/sending-keycode-to-xorg-wine-with-bash-script
_________________
- I don't know why laboratories are named a hospitals.
- The alive personage is like a tea bag with granules of unknown density inside, at that one the packet was made of organic material and was placed in the evaporated liquid or liquid.
|
|
Back to top
|
|
 |
Semme
Joined: 07 Aug 2011 Posts: 2049 Location: World_Hub
|
Posted: Thu 16 Feb 2012, 16:39 Post subject:
|
|
Nooby, try the grandr pkg- an xrandr gui. It may help simplify Aitchs`response..
Then again, maybe just dump: xrandr -q so we can see what's connected.
|
|
Back to top
|
|
 |
Aitch

Joined: 04 Apr 2007 Posts: 6825 Location: Chatham, Kent, UK
|
Posted: Thu 16 Feb 2012, 17:32 Post subject:
|
|
grandr gui for racy/wary, by jemimah
http://murga-linux.com/puppy/viewtopic.php?t=74692
manpages
http://www.manpagez.com/man/1/xrandr/
nooby guide [well almost nooby....newbie
http://www.phoronix.com/scan.php?page=article&item=927&num=1
Aitch
|
|
Back to top
|
|
 |
nooby
Joined: 29 Jun 2008 Posts: 9387 Location: SwedenEurope
|
Posted: Thu 16 Feb 2012, 18:38 Post subject:
|
|
Thanks seems way above my capacity to grasp.
Surprising this is so difficult? I give up on it.
_________________
I'm a noob so I use Google Search of Puppy Forum
|
|
Back to top
|
|
 |
|
|
Page 1 of 2 [21 Posts] |
Goto page: 1, 2 Next |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum You cannot attach files in this forum You can download files in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|