fixed some bugs with older versions of braiins OS +, and fixed a bug in testbench
This commit is contained in:
@@ -336,7 +336,11 @@ class MinerFactory(metaclass=Singleton):
|
|||||||
"BOSminer" in string for string in version["VERSION"][0].keys()
|
"BOSminer" in string for string in version["VERSION"][0].keys()
|
||||||
):
|
):
|
||||||
api = "BOSMiner"
|
api = "BOSMiner"
|
||||||
if "plus" in version["VERSION"][0]["BOSminer"]:
|
if version["VERSION"][0].get("BOSminer"):
|
||||||
|
if "plus" in version["VERSION"][0]["BOSminer"]:
|
||||||
|
api = "BOSMiner+"
|
||||||
|
|
||||||
|
if "BOSminer+" in version["VERSION"][0].keys():
|
||||||
api = "BOSMiner+"
|
api = "BOSMiner+"
|
||||||
|
|
||||||
# if all that fails, check the Description to see if it is a whatsminer
|
# if all that fails, check the Description to see if it is a whatsminer
|
||||||
|
|||||||
@@ -80,7 +80,7 @@ def bind_ctrl_a(key):
|
|||||||
|
|
||||||
|
|
||||||
async def ui():
|
async def ui():
|
||||||
window.read(0)
|
window.read(1)
|
||||||
TableManager().update_tables()
|
TableManager().update_tables()
|
||||||
|
|
||||||
for key in [*TABLE_KEYS["table"], *TABLE_KEYS["tree"]]:
|
for key in [*TABLE_KEYS["table"], *TABLE_KEYS["tree"]]:
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import datetime
|
|||||||
from network import ping_miner
|
from network import ping_miner
|
||||||
from miners.miner_factory import MinerFactory
|
from miners.miner_factory import MinerFactory
|
||||||
from miners.antminer import BOSMinerS9
|
from miners.antminer import BOSMinerS9
|
||||||
from miners._backends.bosminer import BOSMinerOld
|
from miners._backends.bosminer_old import BOSMinerOld
|
||||||
from miners.unknown import UnknownMiner
|
from miners.unknown import UnknownMiner
|
||||||
from tools.web_testbench.connections import ConnectionManager
|
from tools.web_testbench.connections import ConnectionManager
|
||||||
from tools.web_testbench.feeds import get_local_versions
|
from tools.web_testbench.feeds import get_local_versions
|
||||||
@@ -29,7 +29,6 @@ if (
|
|||||||
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
|
asyncio.set_event_loop_policy(asyncio.WindowsSelectorEventLoopPolicy())
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
class TestbenchMiner:
|
class TestbenchMiner:
|
||||||
def __init__(self, host: ip_address):
|
def __init__(self, host: ip_address):
|
||||||
self.host = host
|
self.host = host
|
||||||
@@ -348,14 +347,30 @@ class TestbenchMiner:
|
|||||||
return {
|
return {
|
||||||
"IP": str(self.host),
|
"IP": str(self.host),
|
||||||
"Light": "show",
|
"Light": "show",
|
||||||
"Fans": {'fan_0': {'RPM': 0}, 'fan_1': {'RPM': 0}, 'fan_2': {'RPM': 0}, 'fan_3': {'RPM': 0}},
|
"Fans": {
|
||||||
"HR": {'board_6': {'HR': 0}, 'board_7': {'HR': 0}, 'board_8': {'HR': 0}},
|
"fan_0": {"RPM": 0},
|
||||||
'Temps': {'board_8': {'Board': 0, 'Chip': 0}, 'board_6': {'Chip': 0, 'Board': 0}, 'board_7': {'Chip': 0, 'Board': 0}},
|
"fan_1": {"RPM": 0},
|
||||||
|
"fan_2": {"RPM": 0},
|
||||||
|
"fan_3": {"RPM": 0},
|
||||||
|
},
|
||||||
|
"HR": {
|
||||||
|
"board_6": {"HR": 0},
|
||||||
|
"board_7": {"HR": 0},
|
||||||
|
"board_8": {"HR": 0},
|
||||||
|
},
|
||||||
|
"Temps": {
|
||||||
|
"board_8": {"Board": 0, "Chip": 0},
|
||||||
|
"board_6": {"Chip": 0, "Board": 0},
|
||||||
|
"board_7": {"Chip": 0, "Board": 0},
|
||||||
|
},
|
||||||
"online": self.get_online_time(),
|
"online": self.get_online_time(),
|
||||||
"Tuner": {'board_6': {'power_limit': 275, 'real_power': 0, 'status': 'None'}, 'board_7': {'power_limit': 275, 'real_power': 0, 'status': 'None'}, 'board_8': {'power_limit': 275, 'real_power': 0, 'status': 'None'}},
|
"Tuner": {
|
||||||
|
"board_6": {"power_limit": 275, "real_power": 0, "status": "None"},
|
||||||
|
"board_7": {"power_limit": 275, "real_power": 0, "status": "None"},
|
||||||
|
"board_8": {"power_limit": 275, "real_power": 0, "status": "None"},
|
||||||
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
async def install_done(self):
|
async def install_done(self):
|
||||||
await self.add_to_output("Waiting for disconnect...")
|
await self.add_to_output("Waiting for disconnect...")
|
||||||
try:
|
try:
|
||||||
|
|||||||
Reference in New Issue
Block a user