Page 1 of 1

Autostart file

Posted: Thu Jan 22, 2015 9:01 pm
by mancity
Hi guys,

I'm trying to setup synergy to start with Raspian, but im struggling to get the auto start file to become an executable.

Should the file icon change to look like something other than a notepad if done correctly?

I keep getting permission denied so tried logging in as sudo startx but it still won't work yet...

Re: Autostart file

Posted: Thu Jan 22, 2015 9:48 pm
by B.Goode
There is a tutorial here that might help.

https://learn.adafruit.com/synergy-on-r ... -autostart

In general, I think that initiating the GUI/windowing system as the root user is probably Not A Good Idea.

Re: Autostart file

Posted: Sat Jan 24, 2015 8:00 am
by mancity
Im following a guide already in a book (21 Brilliant Pi Projects) :roll: .

The only thing I cannot do is to get it to work from boot. I have followed a process to create a file named 'autostart' here -

/home/pi/.config/lxsession/LXDE/autostart

And the file contains this - synergyc -n RaspberryPi 192.168.1.79 - and it works if I type that directly into a terminal.

But I don't think the file is actually starting at startup. The guide said put this into a terminal to make is an executable and load at startup -

chmod +x /home/pi/.config/lxsession/LXDE/autostart

I have done this, and it doesn't say anything when you enter the command and the file still just looks like a leafpad file rather than some kind of executable, so I dont think its working?

Re: Autostart file

Posted: Sat Jan 24, 2015 8:08 am
by r3d4
mancity wrote: chmod +x /home/pi/.config/lxsession/LXDE/autostart

I have done this, and it doesn't say anything when you enter the command and the file still just looks like a leafpad file rather than some kind of executable, so I dont think its working?
To see if it worked ( normaly it will do )

try exec ing the file (just tipe in the path )
/home/pi/.config/lxsession/LXDE/autostart

or chk with LS ( some explanation of file permitions / ls output might be use full , search.. ;-)
ls -al /home/pi/.config/lxsession/LXDE/autostart

it might also be use full to include a hashbang for want ever language you write the script in.

Re: Autostart file

Posted: Sat Jan 24, 2015 8:18 am
by ktb
Might the problem be that the custom LXDE-pi lxsession config is what is being used instead of the LXDE lxsession config?

You could try modifying the suggested paths:

/home/pi/.config/lxsession/LXDE-pi/autostart

chmod +x /home/pi/.config/lxsession/LXDE-pi/autostart

Re: Autostart file

Posted: Sat Jan 24, 2015 8:54 am
by mancity
ktb wrote:Might the problem be that the custom LXDE-pi lxsession config is what is being used instead of the LXDE lxsession config?

You could try modifying the suggested paths:

/home/pi/.config/lxsession/LXDE-pi/autostart

chmod +x /home/pi/.config/lxsession/LXDE-pi/autostart
This worked! Mint

Thank you.

PS - This book is just plain wrong unless its out of date now because of the newer looking Raspian OS???

Re: Autostart file

Posted: Sat Jan 24, 2015 10:08 am
by B.Goode
The author of that book is a member of these forums.

Autostart help

Posted: Mon Apr 08, 2019 8:28 pm
by WilliamNPI
Pretty bad at coding but try to learn.

Want to make the system know when chrome has started and make a command line after chrome has started. Have managed to get chrome start in a computer bootup but can’t manage to do make it commands after its boot. How do I do that? Any genius coders out here? :)

Something like
Chrome started= wait 10 seconds then Tab, Tab then Type Username:William then Password: 12345