@jfarro said in My mini magic mirror (pyramid style) build video:
vanity
Excellent work and nice idea!
@jfarro said in My mini magic mirror (pyramid style) build video:
vanity
Excellent work and nice idea!
I use via crontab the CEC-function of the Monitor:
0 8 * * 1-5 echo “on 0” | cec-client -s -d 1 >/dev/null 2>&1
30 9 * * 0,6 echo “on 0” | cec-client -s -d 1 >/dev/null 2>&1
30 20 * * * echo ‘standby 0’ | cec-client -s -d 1 >/dev/null 2>&1
this works like a charme since over one year
regards Mike
@CyruS1337 said in Cronjob:
Thanks for the link, but it still does not work
# Edit this file to introduce tasks to be run by cron. # # Each task to run has to be defined through a single line # indicating with different fields when the task will be run # and what command to run for the task # # To define the time you can provide concrete values for # minute (m), hour (h), day of month (dom), month (mon), # and day of week (dow) or use '*' in these fields (for 'any').# # Notice that tasks will be started based on the cron's system # daemon's notion of time and timezones. # # Output of the crontab jobs (including errors) is sent through # email to the user the crontab file belongs to (unless redirected). # # For example, you can run a backup of all your user accounts # at 5 a.m every week with: # 0 5 * * 1 tar -zcf /var/backups/home.tgz /home/ # # For more information see the manual pages of crontab(5) and cron(8) # # m h dom mon dow command # #MONTAG BIS SONNTAG UM 19:55 MAGICMIRROR RESTART 55 19 * * * pm2 restart mm.sh >/dev/null 2>&1 # #SAMSTAG REBOOT UM 12:00 MAGICMIRROR REBOOT 24 17 * * * sudo reboot #
Sounds strange. Maybe you first have to stop the pm2 process before restart, with pm2 stop mm.sh. Don’t forget to complete the line für den reboot am Samstag - sudo reboot >/dev/null 2>&1
regards Michael
@CyruS1337 said in Cronjob:
Good evening
I’d like to see my MagicMirror restart at a certain time each day. What should I enter in the crontrab? I have already tried x variants, but unfortunately it never worked.
27 17 * * * Command pm2 restart mm
The sudo reboot command works fine.
27 17 * * 5 sudo poweroff
Did you forget to write the full command? Try pm2 restart mm.sh
By the way: I prefere the online crontab generator (https://crontab-generator.org/). It’s very easy.
Regards Mike
@lovesicker OK. Did you try to start the module twice? Maybe this is the possibility to activate both gateways at the same time as you need it.
Regards Mike
@lovesicker Hi,
why do you use two gateways? It’s not necessary. I use one gateway for my complete house. I use 10 temperature and humity sensors. Have a closer look to my config.
Regards Mike.
@lovesicker Hi,
I think you are on the wrong way: You use gatewayIP and gatewayToken twice. Thats not necessary.
Look to my configuration - this works fine:
{
module: ‘MMM-xiaomi’,
position: ‘bottom_left’,
colored: true,
header: ‘Temperatur / Luftfeuchtigkeit’, // This is optional
config: {
gatewayIP: ‘192.168.160.xx’,
outsideSensorId: ‘15xxx0201dxxx’,
gatewayToken: ‘cd857eee1fc760d029767709cd50xxxx’,
showWindow: true,
showVentilation: true,
showLights: false,
showTend: false,
showNotifications: false,
audioNotifications: false,
rooms: [
{
name: 'Büro',
minTemperature : 15,
maxTemperature : 35,
sortOrder: 1,
devices : ['158d0001c2cxxx']
},
{
name: 'Aussentemperatur ',
sortOrder: 20,
devices : ['15xxx00201d4xxx']
},
{
name: 'Wohnzimmer ',
minTemperature : 15,
maxTemperature : 35,
sortOrder: 2,
devices : ['158d0001c2cxxx']
},
{
name: 'Schlafzimmer ',
sortOrder: 3,
minTemperature : 15,
maxTemperature : 30,
devices : ['1xxx000201dxxx', '15xxx001f49xxx']
},
{
name: 'Philipp',
minTemperature : 15,
maxTemperature : 35,
sortOrder: 4,
devices : ['1xxd0001c14xxx']
},
{
name: 'Marco',
minTemperature : 15,
maxTemperature : 35,
sortOrder: 5,
devices : ['15xxx01f54xxx']
},
{
name: 'HW-Raum',
minTemperature : 10,
maxTemperature : 35,
sortOrder: 7,
devices : ['15xxx002029xxx']
},
{
name: 'Garage',
minTemperature : 15,
maxTemperature : 35,
sortOrder: 10,
devices : ['15xxx001c1xxx']
},
{
name: 'Keller',
minTemperature : 15,
maxTemperature : 35,
sortOrder: 9,
devices : ['15xxx001c2axxx']
},
{
name: 'WC',
minTemperature : 15,
maxTemperature : 35,
sortOrder: 8,
devices : ['15xxx001c1axxx']
},
{
name: 'Bad',
minTemperature : 18,
maxTemperature : 35,
sortOrder: 6,
devices : ['15xxx001c2cxxx']
},
]
@stuartiannaylor said in YAPi0 Installer Stretch Lite:
pm2 save
Great job! I ve got it to work - it runs fine on my Pi0!
Thank you for your great efforts.
Michael
I still have problems. Afer several installations, I always get after start a white screen:
“This side can’t be readed - localhost refused to connect
checking the proxy and the firewall”
Also, this error message appears after new installation:
"Extracting node-v10.15.1-linux-armv6l.tar.gz
Extracting node-v10.15.1-linux-armv6l
unlink: cannot unlink ‘/usr/bin/pm2’: No such file or directory
unlink: cannot unlink ‘/usr/sbin/pm2’: No such file or directory
unlink: cannot unlink ‘/sbin/pm2’: No such file or directory
unlink: cannot unlink ‘/usr/local/bin/pm2’: No such file or directory
Trying this command: chmod a+x ~/MagicMirrorPi0StretchLite/RaspberryPi0.sh && sh ~/MagicMirrorPi0StretchLite/RaspberryPi0.sh
there is an error:
/home/pi/MagicMirrorPi0StretchLite/RaspberryPi0.sh: 5: /home/pi/MagicMirrorPi0StretchLite/RaspberryPi0.sh: Syntax error: “(” unexpected
Any ideas?
Thanks in advance
Michael
Great thanks to Mich for the MM-Projekt - I love it. So I did build my 4. Mirror as an infoboard. I’m using a cheap LCD-TV (40") and a Pi zero. Everything works fine except the autostart with pm2. If I take the SD-Card with the MM to an Raspi 3, there are no problems - the mirrorsoftware starts over pm2 with no problems. The same SD card in a Pi zero w - no chance to start automaticaly. I think the problem depends on the pm2 software. Has anyone an idea to solve it?
Thanks in advance.
Michael
@jfarro said in My mini magic mirror (pyramid style) build video:
vanity
Excellent work and nice idea!