Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Thu 23 Oct 2014, 12:49
All times are UTC - 4
 Forum index » House Training » Beginners Help ( Start Here)
How to toggle between laptop / external monitor? (Solved)
Moderators: Flash, Ian, JohnMurga
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 2 [21 Posts]   Goto page: 1, 2 Next
Author Message
nooby

Joined: 29 Jun 2008
Posts: 10557
Location: SwedenEurope

PostPosted: 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 Smile

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
View user's profile Send private message 
nooby

Joined: 29 Jun 2008
Posts: 10557
Location: SwedenEurope

PostPosted: Wed 15 Feb 2012, 05:52    Post subject:  

May I kindly ask for help with this one?
_________________
I use Google Search on Puppy Forum
not an ideal solution though
Back to top
View user's profile Send private message 
L18L

Joined: 19 Jun 2010
Posts: 2525
Location: Moved from Hosla to www.eussenheim.de

PostPosted: 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 Question
And what is Fn+F6 Question

Crying or Very sad
Back to top
View user's profile Send private message 
mahaju


Joined: 11 Oct 2010
Posts: 493
Location: between the keyboard and the chair

PostPosted: Wed 15 Feb 2012, 09:38    Post subject:  

Fn key in laptop
Back to top
View user's profile Send private message 
nooby

Joined: 29 Jun 2008
Posts: 10557
Location: SwedenEurope

PostPosted: 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 Smile

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 use Google Search on Puppy Forum
not an ideal solution though
Back to top
View user's profile Send private message 
trapster


Joined: 28 Nov 2005
Posts: 2006
Location: Maine, USA

PostPosted: 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 Slacko AND lupu52 w/ fluxbox
Back to top
View user's profile Send private message Visit poster's website 
nooby

Joined: 29 Jun 2008
Posts: 10557
Location: SwedenEurope

PostPosted: 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 use Google Search on Puppy Forum
not an ideal solution though
Back to top
View user's profile Send private message 
Aitch


Joined: 04 Apr 2007
Posts: 6825
Location: Chatham, Kent, UK

PostPosted: 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

Code:
xrandr --auto


just a thought...?

Aitch Smile
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2260

PostPosted: 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
View user's profile Send private message 
nooby

Joined: 29 Jun 2008
Posts: 10557
Location: SwedenEurope

PostPosted: 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 use Google Search on Puppy Forum
not an ideal solution though
Back to top
View user's profile Send private message 
nooby

Joined: 29 Jun 2008
Posts: 10557
Location: SwedenEurope

PostPosted: 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 use Google Search on Puppy Forum
not an ideal solution though
Back to top
View user's profile Send private message 
postfs1


Joined: 27 Mar 2010
Posts: 831

PostPosted: 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
View user's profile Send private message 
Semme

Joined: 07 Aug 2011
Posts: 3968
Location: World_Hub

PostPosted: 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
View user's profile Send private message 
Aitch


Joined: 04 Apr 2007
Posts: 6825
Location: Chatham, Kent, UK

PostPosted: 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 Wink

http://www.phoronix.com/scan.php?page=article&item=927&num=1

Aitch Smile
Back to top
View user's profile Send private message 
nooby

Joined: 29 Jun 2008
Posts: 10557
Location: SwedenEurope

PostPosted: 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 use Google Search on Puppy Forum
not an ideal solution though
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 2 [21 Posts]   Goto page: 1, 2 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » House Training » Beginners Help ( Start Here)
Jump to:  

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
[ Time: 0.0854s ][ Queries: 11 (0.0059s) ][ GZIP on ]