improve how the fault light looks on whatsminers
This commit is contained in:
@@ -439,8 +439,8 @@ class BTMinerAPI(BaseMinerAPI):
|
|||||||
self,
|
self,
|
||||||
auto: bool = True,
|
auto: bool = True,
|
||||||
color: str = "red",
|
color: str = "red",
|
||||||
period: int = 2000,
|
period: int = 60,
|
||||||
duration: int = 1000,
|
duration: int = 20,
|
||||||
start: int = 0,
|
start: int = 0,
|
||||||
) -> dict:
|
) -> dict:
|
||||||
"""Set the LED on the miner using the API.
|
"""Set the LED on the miner using the API.
|
||||||
|
|||||||
@@ -144,6 +144,9 @@ class BTMiner(BaseMiner):
|
|||||||
async def fault_light_on(self) -> bool:
|
async def fault_light_on(self) -> bool:
|
||||||
try:
|
try:
|
||||||
data = await self.api.set_led(auto=False)
|
data = await self.api.set_led(auto=False)
|
||||||
|
await self.api.set_led(
|
||||||
|
auto=False, color="green", start=0, period=1, duration=0
|
||||||
|
)
|
||||||
except APIError:
|
except APIError:
|
||||||
return False
|
return False
|
||||||
if data:
|
if data:
|
||||||
|
|||||||
Reference in New Issue
Block a user