SinricPro Library
|
Public Member Functions | |
bool | sendPowerSensorEvent (float voltage, float current, float power=-1.0f, float apparentPower=-1.0f, float reactivePower=-1.0f, float factor=-1.0f, String cause="PERIODIC_POLL") |
Send PowerSensor event to SinricPro Server. More... | |
bool sendPowerSensorEvent | ( | float | voltage, |
float | current, | ||
float | power = -1.0f , |
||
float | apparentPower = -1.0f , |
||
float | reactivePower = -1.0f , |
||
float | factor = -1.0f , |
||
String | cause = "PERIODIC_POLL" |
||
) |
Send PowerSensor event to SinricPro Server.
voltage | float voltage |
current | float current |
power | float (optional) if not provided, it is calculated automaticly (power = voltage * current) |
apparentPower | float (optional) if not provided it is set to -1 |
reactivePower | float (optional) if not provided it is set to -1 |
factor | float (optional) if not provided it is set to -1 if apparentPower is provided, factor is calculated automaticly (factor = power / apparentPower) |
cause | String (optional) Reason why event is sent (default = "PERIODIC_POLL" ) |
true | event has been sent successfully |
false | event has not been sent, maybe you sent to much events in a short distance of time |