Hoping someone can help with this query
I am try to debug why one of my rules is not working using System.out.println, but I cannot find where this output goes,
I am running Controller 2.6 on a Raspberry pi with the below rules file.
The rules in question are SkyPowerOn, and SkyPowerOff.
SkypowerOn works successfully, but SkyPowerOff does not seem to work, the only difference being that the Command is a Macro, whereas the powerOn
command is a simple command (TCP/IP) I have added the System.out.println(s) to try to debug it but where I expected the output to be
in openremote/logs/container/standardoutput.log this is not present, and there is no output on the screen.
package org.openremote.controller.protocol
global org.openremote.controller.statuscache.CommandFacade execute;
global org.openremote.controller.statuscache.SwitchFacade switches;
import java.util.;
import java.io.
import org.openremote.controller.model.event.*;
rule “Evening”
timer (cron: 0 30 22 * * ?) when eval(true) then
execute.command(“setmedium”);
end
rule “Morning”
timer (cron: 0 0 8 * * ?) when eval(true) then
execute.command(“sethigh”);
end
rule “SkyPowerOn” when
Event( source == “VirtualSensor”, value == “on”)
then
System.out.println(“Running PWRONSKY”);
execute.command(“PwrOnSKY”);
end
rule “SkyPowerOff” when
Event( source == “VirtualSensor”, value == “off”)
then
System.out.println(“Running Sky Off”);
execute.command(“SkyOff”);
end