LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Embedded & Single-board computer (https://www.linuxquestions.org/questions/linux-embedded-and-single-board-computer-78/)
-   -   How to stop screen going blank in debian OS (https://www.linuxquestions.org/questions/linux-embedded-and-single-board-computer-78/how-to-stop-screen-going-blank-in-debian-os-813029/)

lalithasankh 06-08-2010 11:53 PM

How to stop screen going blank in debian OS
 
Dear All,

how to use setterm command in debian I mean in /etc/xx files

bathory 06-09-2010 03:56 AM

Hi,

You can create a script in /etc/init.d to run setterm, e.g.:
Code:

#!/bin/sh
/usr/bin/setterm -blank 0

make it executable and run
Code:

update-rc.d scriptname defaults
so it updates the necessary symlinks in the various runlevels

Regards

lalithasankh 06-09-2010 05:08 AM

does not work
 
Quote:

Originally Posted by bathory (Post 3997581)
Hi,

You can create a script in /etc/init.d to run setterm, e.g.:
Code:

#!/bin/sh
/usr/bin/setterm -blank 0

make it executable and run
Code:

update-rc.d scriptname defaults
so it updates the necessary symlinks in the various runlevels

Regards

thank you very much.


I have done as you mentioned

the step I followed is as follows

ot@ts7000:init.d# vi ww1
#!/bin/sh
/usr/bin/setterm -blank 0
root@ts7000:init.d# chmod 777 ww1
root@ts7000:init.d# ./ww1
oot@ts7000:init.d# update-rc.d ww1 defaults
Adding system startup for /etc/init.d/ww1 ...
/etc/rc0.d/K20ww1 -> ../init.d/ww1
/etc/rc1.d/K20ww1 -> ../init.d/ww1
/etc/rc6.d/K20ww1 -> ../init.d/ww1
/etc/rc2.d/S20ww1 -> ../init.d/ww1
/etc/rc3.d/S20ww1 -> ../init.d/ww1
/etc/rc4.d/S20ww1 -> ../init.d/ww1
/etc/rc5.d/S20ww1 -> ../init.d/ww1
root@ts7000:init.d# reboot




same after 10 minutes screen gone blank...
could you please suggest any wrong thing I did???


thanks once again for you kind reply

bathory 06-09-2010 05:43 AM

Hi,

It looks like you have to add some more setterm options
Code:

/usr/bin/setterm -blank 0 -powersave off -powerdown 0

lalithasankh 06-11-2010 01:36 AM

setterm -cursor off
 
Quote:

Originally Posted by bathory (Post 3997669)
Hi,

It looks like you have to add some more setterm options
Code:

/usr/bin/setterm -blank 0 -powersave off -powerdown 0

Thanks for your suggestion still the same problem
I have even added

seterm -cursor off also to make cursor blinking off but after doing this also cursor is blinking....

please suggest any other method...

lalithasankh 06-11-2010 02:00 AM

Quote:

Originally Posted by lalithasankh (Post 3999823)
Thanks for your suggestion still the same problem
I have even added

seterm -cursor off also to make cursor blinking off but after doing this also cursor is blinking....

please suggest any other method...

hey I always get following error

cannot (un)set powersave mode for
/usr/bin/setterm -blank 0 -powersave off -powerdown 0

please guide me how to resolve this issue

bathory 06-11-2010 02:29 AM

Are you running the command from an xterm? It is supposed to be run from CLI.
If you want to do the same for X you should use xset

lalithasankh 06-11-2010 03:52 AM

Quote:

Originally Posted by bathory (Post 3999853)
Are you running the command from an xterm? It is supposed to be run from CLI.
If you want to do the same for X you should use xset

I am using VI editor,I realyl don't know working with xterm

bathory 06-11-2010 04:04 AM

xterm is a X-windows terminal. What I mean is that if you're trying to run the setterm command from a terminal inside X, it's not going to work.
It is supposed to work when you boot into runlevel 3 and not runlevel 5 (that is X-windows)

lalithasankh 06-11-2010 04:35 AM

Quote:

Originally Posted by bathory (Post 3999935)
xterm is a X-windows terminal. What I mean is that if you're trying to run the setterm command from a terminal inside X, it's not going to work.
It is supposed to work when you boot into runlevel 3 and not runlevel 5 (that is X-windows)

see actually working on TS7260 ARM-linux board. Once power is switched on I get login prompt on Hyper terminal(in windows xp Machine) and another on VGA Screen

now what even I have done on windows Hyperterminal(which is ttyAM0 of
TS7260 arm9 board)....

now tell me what is wrong that I am doing?????????????

bathory 06-11-2010 05:37 AM

I don't think you're doing something wrong. I guess it's the customized debian you're running on this board.
You can leave the powersave option out the command and see if it works
Code:

/usr/bin/setterm -blank 0 -powerdown 0

lalithasankh 06-11-2010 06:21 AM

Quote:

Originally Posted by bathory (Post 4000051)
I don't think you're doing something wrong. I guess it's the customized debian you're running on this board.
You can leave the powersave option out the command and see if it works
Code:

/usr/bin/setterm -blank 0 -powerdown 0

thank you very much,

i went init 3 level
and executed the shell script and
updated rc.d as of ur 1st mail but for rebooting

I am saying to reboot and again getting same problem cursor in blink
and screen goes blank.

bathory 06-11-2010 07:12 AM

If you're using console-tools, it's maybe worth trying to edit /etc/console-tools/config and use:
Quote:

BLANK_TIME=0
POWERDOWN_TIME=0

lalithasankh 06-11-2010 07:54 AM

Quote:

Originally Posted by bathory (Post 4000127)
If you're using console-tools, it's maybe worth trying to edit /etc/console-tools/config and use:

sorry I am not able to find console-tools in /etc/ directory

bathory 06-11-2010 03:48 PM

Makes sense since you're using a customized debian.
The last thing I can think that it could work, is to use ansi escape codes to do the same as setterm:
Code:

echo -e '\033[9;0]\033[14;0]' > /dev/console


All times are GMT -5. The time now is 03:15 PM.