gkaindl / ambi-tv

a flexible ambilight clone for embedded linux
296 stars 85 forks source link

auto ambi-tv start problem #56

Open vooklej opened 10 years ago

vooklej commented 10 years ago

Hi!

So, my whole setup is complete.Eeverything works great and i was able to solve all issues, thanks to you guys! But, there is still last think that's bothering me. I added whole ambi-tv way to /etc/rc.local "sudo ./home/pi/ambi-tv/bin/ambi-tv --button-gpio 3" but now, after restarting RPI, ambi-tv starts, RPI wont ask me for user and passwd and i'm not able to kill the program. Tried ctrl c, ctrl z, esc, nothing actually works.

Little bit depressing while i need to do some adjusting in ambi-tv.conf...

Could some of you guys help me? I'm new in this stuff...

Thank you!! Great project!!

vooklej commented 10 years ago

Related to this one, i just discovered, that if i reboot RPI with switch button connected on 3, RPI will boot in 640x480 and stops with loading usb grabber...

duenorh commented 10 years ago

This is what i have in my rc.local file /home/pi/ambi-tv-master/bin/ambi-tv --button-gpio 3

You don't need the sudo part becouse rc.local is run as root.

For the other problem. What kind of usb dongle do you have? Is it the stk1160 or fushicai? Do a lsusb and see.

vooklej commented 10 years ago

I've tried without sudo, but RPI asked for user and passwd, after login didnt run ambi-tv.. usb dongle is fushicai.

vooklej commented 10 years ago

is there any possible way of killing program so i can uncomment autostart in /etc/rc.local?

duenorh commented 10 years ago

to kill a process you have to get the id of it. run ps aux | grep ambi-tv and a list should appear like this root 2316 0.3 0.1 10464 772 ? S Jan17 11:04 /home/pi/ambi-tv-master/bin/ambi-tv --button-gpio 3 pi 3611 0.0 0.1 3540 808 pts/0 S+ 18:04 0:00 grep --color=auto ambi-tv to kill ambi-tv run "sudo kill idnumber" where idnumber is the id of your process. (2316 in this case)

Are you running the hdmi/av as ntsc?

vooklej commented 10 years ago

i've hdmi/av on PAL, problem is, that i can't type anything. Even when i press alt+f2, black screen appears and i can't type username and passwd. I made brand new copy of debian on SD card and started over. I'll try to programm autologin and i'll put whole path of ambi-tv in rc.local without sudo.

Still can't figure out why is RPI loading in 640x480 and stops while loading usb grabber. Doesn't freeze, just stops.

Thanks a lot!

vooklej commented 10 years ago

Nope, same problem.. i've redone everything, everything goes like a charm, video0 is in /dev, spidev0.0 also right after uncomenting line in blacklist, but once i'll put full path to ambi-tv in /etc/rc.local (/home/pi/ambi-tv/bin/ambi-tv), reboot, and can't close the program!!

rc.local script looks like

PrintIP

..... .... some code to this program ....

./home/pi/ambi-tv/bin/ambi-tv

exit 0

I've tried to put full path under "exit0" but without any effect.

Please help, i've redone SD card like 5 times already..

Thank you!

duenorh commented 10 years ago

Remove the dot infront of /home /home/pi/ambi-tv/bin/ambi-tv

Have you tried just running it from the terminal?

vooklej commented 10 years ago

Yep, program runs fine...i'll try it without the dot.

ghgoldberg commented 10 years ago

It would be super if ambi-tv had a function where pressing the q key would quit the program and take you to the command line. That way, you can auto-start the program, but grab back control if need be.

danrspencer commented 10 years ago

Seconded about the "q" key. Was a bit of a pain having to restart the Pi every time I wanted to test my tweaked RBG settings.

Might try and code it in myself at some point if and pull request it if I get chance ....