LinHES Forums
http://forum.linhes.org/

Autoload nvtv ?
http://forum.linhes.org/viewtopic.php?f=11&t=11659
Page 1 of 1

Author:  zitroneneis [ Sat Sep 16, 2006 9:40 am ]
Post subject:  Autoload nvtv ?

Hi
I've recently set up a mythtv box and it works great.
Just one problem is left.
I use nvtv to get rid of the black boarders.
But I haven't found a way to automate this small command

I've tried to add a line to "/home/mythtv/.fluxbox/apps"

its
[startup] {nvtv -r 800,600 -s HUGE -S PAL -t}

but this doesn't help.

So I tried it like I found it in an script which works for so else.
I created a file /home/mythtv/do_nvtv.sh
It contains a single line "nvtv -r 800,600 -s HUGE -S PAL -t"
then I did chmod 777 and chown mythtv:mythtv for this file and
added another line to .fluxbx/apps
[startup] {~mythtv/do_nvtv.sh}

and added /usr/local/bin/nvtvd to /etc/init.d/bootmisc.sh

("This daemon must be running if a non-root user needs to execute an nvtv command")

but: nothing happend

I still have to ssh in my box and do it by hand.

Could anybody please tell me the secret how to automate it

Thanks a lot

Author:  tjc [ Sat Sep 16, 2006 10:17 am ]
Post subject:  Re: Autoload nvtv ?

Kudos on doing your research and finding a fix, but I'm afraid you either found some bad advice or garbled it a bit.
zitroneneis wrote:
I created a file /home/mythtv/do_nvtv.sh
It contains a single line "nvtv -r 800,600 -s HUGE -S PAL -t"
then I did chmod 777 and chown mythtv:mythtv for this file and

OK, first of all NEVER do this with chmod, as a matter of fact tell me who taught you to do this so I can hunt them down. This is "cleaning" the windows of your car by smashing them out with a sledgehammer, and it drives me nuts to see this evil meme propogating.

Step 1, create a script called /home/mythtv/do_nvtv.sh to run the command, make it look like this:
Code:
#!/bin/bash

nvtv -r 800,600 -s HUGE -S PAL -t

The "pound bang magic" tells the system what type of script this is. Then give it the proper permissions, and if you created it as root, the proper ownership:
Code:
chmod u=rwx,go=rx do_nvtv.sh
chown mythtv:mythtv do_nvtv.sh

zitroneneis wrote:
added another line to .fluxbx/apps
[startup] {~mythtv/do_nvtv.sh}

Step 2, remove any nonworking versions of this from /home/mythtv/.fluxbox/apps and add it back with the full path
Code:
[startup] {/home/mythtv/do_nvtv.sh}

zitroneneis wrote:
and added /usr/local/bin/nvtvd to /etc/init.d/bootmisc.sh

("This daemon must be running if a non-root user needs to execute an nvtv command")

Step 3, make sure that /usr/local/bin/nvtvd exists and that it's actually running.
Code:
ls -l /usr/local/bin/nvtvd
pgrep -fl nvtvd

Author:  mamo74 [ Thu Sep 28, 2006 1:45 am ]
Post subject: 

Perfect for me, thank you...i've insert in do_nvtv the line for the problem with blue line with xvattr.

One little problem: when i play with tux race and i come back to mythtv i lose the setting.

sorry for my bad english
:oops:

Author:  mac [ Thu Sep 28, 2006 1:58 am ]
Post subject: 

I would rename the tux race binary with a name ending in .real or something
then create a script that calls the real binary on the first line and second line
it calls the script /home/mythtv/do_nvtv.sh

you might want to keep track of all little fixes so that they can added again after an
upgrade or reinstall.. remembering all of the small changes I made to my box is always
a bit of headache..

Author:  mamo74 [ Mon Dec 15, 2008 3:12 am ]
Post subject: 

mamo74 wrote:
Perfect for me, thank you...i've insert in do_nvtv the line for the problem with blue line with xvattr.

One little problem: when i play with tux race and i come back to mythtv i lose the setting.

sorry for my bad english
:oops:


quoting my old post beacouse i've change my hardware and re-install KnoppMyth 5.5, i'm able to use the old script (do_nvtv.sh) but i can't have correct video when i exit from xmame game...

when i exit from the game i've the "black border" so i run do_nvtv.sh and everythink is right. (using mythtv users) so nvtvd is running

i've try "update-rc do_nvtv.sh defaults", reboot and try but nothing exiting game black border

what i forget?
THX

Author:  jmckeown2 [ Tue Dec 16, 2008 6:09 pm ]
Post subject:  Re: Autoload nvtv ?

tjc wrote:
OK, first of all NEVER do this with chmod, as a matter of fact tell me who taught you to do this so I can hunt them down. This is "cleaning" the windows of your car by smashing them out with a sledgehammer, and it drives me nuts to see this evil meme propogating.

I'm not sure I'm sensing the evil here. Is it the octal mode chmod arg? I "grew up" in *Nix so I'd personally rather see 'chmod 755' versus 'chmod u=rwx,go=rx' but I see that one as preference rather than light side versus dark side. Is it opening write access to the world? (I agree that's evil.) Or is it thinking execute permission is sufficient and you don't need the shebang in the script? again not evil; a bad instruction, but not evil. That's more like cleaning your windows by spraying them with windex, but then not wiping. you think you're doing good, but actually making it no better at all.

Author:  tjc [ Tue Dec 16, 2008 10:55 pm ]
Post subject: 

The blind use of 777 is the evil that I was referring to. Using octal mode strings seems to encourage it since the average yahoo can't be bothered to learn or figure out the bit encodings to get it right and thus falls back on 777.

Author:  mamo74 [ Wed Dec 17, 2008 10:24 am ]
Post subject: 

ok thank you :shock: but anything for me? :roll:

Page 1 of 1 All times are UTC - 6 hours
Powered by phpBB® Forum Software © phpBB Group
http://www.phpbb.com/