changed bos get_bad_boards to be consistent with hive
This commit is contained in:
@@ -1,7 +1,4 @@
|
|||||||
import asyncio
|
|
||||||
|
|
||||||
from miners.bmminer import BMMiner
|
from miners.bmminer import BMMiner
|
||||||
import json
|
|
||||||
|
|
||||||
|
|
||||||
class HiveonT9(BMMiner):
|
class HiveonT9(BMMiner):
|
||||||
|
|||||||
@@ -112,13 +112,13 @@ class BOSMiner(BaseMiner):
|
|||||||
async def get_bad_boards(self) -> list:
|
async def get_bad_boards(self) -> list:
|
||||||
"""Checks for and provides list of non working boards."""
|
"""Checks for and provides list of non working boards."""
|
||||||
devs = await self.api.devdetails()
|
devs = await self.api.devdetails()
|
||||||
bad = 0
|
bad_boards = []
|
||||||
chains = devs['DEVDETAILS']
|
chains = devs['DEVDETAILS']
|
||||||
for chain in chains:
|
for chain in chains:
|
||||||
if chain['Chips'] == 0:
|
if not chain['Chips'] == 63:
|
||||||
bad += 1
|
bad_boards.append({"board": chain["ID"], "chain": chain["ID"], "chip_count": chain['Chips'], "chip_status": "o"*chain['Chips']})
|
||||||
if bad > 0:
|
|
||||||
return [str(self.ip), bad]
|
return bad_boards
|
||||||
|
|
||||||
async def check_good_boards(self) -> str:
|
async def check_good_boards(self) -> str:
|
||||||
"""Checks for and provides list for working boards."""
|
"""Checks for and provides list for working boards."""
|
||||||
|
|||||||
Reference in New Issue
Block a user