I am new to Raspberry and Linux so please don't mind silly questions or if this is not the right place to post. I have a Raspberry Pi B+ running Rasbian.
I am trying to create a project whereby when I switch on the Raspberry an .odp presentation starts in presentation mode running in loops (i.e. when it reaches the last slide it starts over). So far so good.
The problem is that I want it to stop after 8 hours....that is, terminate libreoffice using wmctrl -c and then halting the system sudo shutdown -h now.
So I first created a crontab job (i.e. crontab -e) and I added the line:
Code: Select all
*/2 * * * * wmctrl -c libreofficeI then created a a script which contained the following lines
Code: Select all
#! bin/bash
wmctrl -c libreofficeCode: Select all
*/2 * * * * home/pi/killgracefully.shI tried other solutions as found at http://stackoverflow.com/questions/1616 ... ind-wmctrl, http://stackoverflow.com/questions/2229 ... b-will-use and http://askubuntu.com/questions/29239/wh ... sh-profile.
Nothing seems to work. Any ideas/suggestions will be very much appreciated.
Extra info: the Pi will not be connected to the network and therefore I will never have correct time hence the every 8 hours cronjob.
Thanks
I also