here is what i have done, actually it works - i will watch it a few days.
switch to /bin/
cd /
cd bin
open nano and create a shell script
sudo nano monitor_on.sh
write the “On” Command in it and save with Ctrl+x
/opt/vc/bin/tvservice --preferred && sudo chvt 6 && sudo chat 7
open nano and create another shell script
sudo nano monitor_off.sh
write the “Off” Command in it and save with Ctrl+x
/opt/vc/bin/tvservice -o
make both shell scripts executable
sudo chmod +x monitor_off.sh
sudo chmod +x monitor_on.sh
open the crontab and add the following at the end
switches the monitor off and on every 15 minutes. this is for experimenting, i will look how it works and will set the
time up as.
15 * * * * sudo /bin/monitor_off.sh
15 * * * * sudo /bin/monitor_on.sh
@reboot sudo modprobe bcm2835-vl2