@Jopyth
Hi! First of all thanks a lot for creating this awesome module, it really expands the capability of what a Magic Mirror can do.
I just wanted to point out that I had an issue turning on the screen after turn it it off using the module. I went to the “node_helper.js” file to see which function you were using:
if (query.action === “MONITORON”)
{
exec(“tvservice --preferred && sudo chvt 6 && sudo chvt 7”, opts, function(error, stdout, stderr){ self.checkForExecError(error, stdout, stderr, res); });
return true;
}
if (query.action === “MONITOROFF”)
{
exec(“tvservice -o”, opts, function(error, stdout, stderr){ self.checkForExecError(error, stdout, stderr, res); });
return true;
}
This function wasn’t really working for me and it seems a bit outdated. You can go further on the reasons why on this links:
https://raspberrypi.stackexchange.com/questions/52042/turning-tvservice-on-and-off-leaves-screen-blank
http://www.elinux.org/RPI_vcgencmd_usage
I just changed that code to:
if (query.action === “MONITORON”)
{
exec(“vcgencmd display_power 1”, opts, function(error, stdout, stderr){ self.checkForExecError(error, stdout, stderr, res); });
return true;
}
if (query.action === “MONITOROFF”)
{
exec(“vcgencmd display_power 0”, opts, function(error, stdout, stderr){ self.checkForExecError(error, stdout, stderr, res); });
return true;
}
And everything seems to work perfectly for me now. I’m using a Raspberry pi 1 and Midori as a web browser.
My question is, would you be able to implement this changes in order to solve this issue for another users? (and also to keep my same valid configuration in case of an update)
Thanks!