Refactoring

Refactoring
This commit is contained in:
Theo Arends 2019-09-04 12:58:37 +02:00
parent 1304252d08
commit 138ed6def9
2 changed files with 6 additions and 6 deletions

View File

@ -303,7 +303,7 @@ void SetLatchingRelay(power_t lpower, uint32_t state)
}
}
void SetDevicePower(power_t rpower, int source)
void SetDevicePower(power_t rpower, uint32_t source)
{
ShowSource(source);
@ -364,7 +364,7 @@ void SetDevicePower(power_t rpower, int source)
}
}
void RestorePower(bool publish_power, int source)
void RestorePower(bool publish_power, uint32_t source)
{
if (power != last_power) {
SetDevicePower(last_power, source);
@ -374,7 +374,7 @@ void RestorePower(bool publish_power, int source)
}
}
void SetAllPower(uint32_t state, int source)
void SetAllPower(uint32_t state, uint32_t source)
{
// state 0 = POWER_OFF = Relay Off
// state 1 = POWER_ON = Relay On (turn off after Settings.pulse_timer * 100 mSec if enabled)
@ -528,7 +528,7 @@ bool SendKey(uint32_t key, uint32_t device, uint32_t state)
return result;
}
void ExecuteCommandPower(uint32_t device, uint32_t state, int source)
void ExecuteCommandPower(uint32_t device, uint32_t state, uint32_t source)
{
// device = Relay number 1 and up
// state 0 = POWER_OFF = Relay Off

View File

@ -500,7 +500,7 @@ static bool WifiIsInManagerMode(){
return (HTTP_MANAGER == Web.state || HTTP_MANAGER_RESET_ONLY == Web.state);
}
void ShowWebSource(int source)
void ShowWebSource(uint32_t source)
{
if ((source > 0) && (source < SRC_MAX)) {
char stemp1[20];
@ -508,7 +508,7 @@ void ShowWebSource(int source)
}
}
void ExecuteWebCommand(char* svalue, int source)
void ExecuteWebCommand(char* svalue, uint32_t source)
{
ShowWebSource(source);
ExecuteCommand(svalue, SRC_IGNORE);