I've had a heck of a time figuring out how to get a program (feh, in this instance) to autostart after my Raspberry Pi auto launches into LXDE. I did finally get it working - my only excuse is I must be tired...
Not that it matters, I'm using the new raspbian distro (downloaded today, 07/19/2012), completely udpated/upgrade (sudo apt-get update
and sudo apt-get -y upgrade
)
I used the configuration utility to easily tell it to autostart into the window environment (sudo raspi-config
) then find the option for booting directly with startx & enabled it.
Then I wrote a script to launch feh (I'll do a more comprehensive post on this later, likely), left it in my home directory and named it start_feh.sh
(imaginative), with appropriate chmod +x
Next (and I assume you're doing this all from a terminal/ssh), change to your home folder's configuration folder (cd ~/.config
), and make an autostart directory (mkdir autostart
).
cd to that folder (cd autostart
), then make a *.desktop file for your script (vi feh.desktop
) with the following 3 lines:
[Desktop Entry]
Type=Application
Exec=/home/pi/start_feh.sh
That's it -- all it took. So... long story short: On your Raspberry Pi, to start a program after it launches into LXDE, make a *.desktop file in /home/[user profile]/.config/autostart
Stayman Winesap Apple Crumble (Jumbo) Muffins
9 months ago