Compare commits
13 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4c104a59ff | ||
|
|
e708ae3728 | ||
|
|
a4352816ee | ||
|
|
336bd9c002 | ||
|
|
e3c917efde | ||
|
|
4d71012ed6 | ||
|
|
1acdba8ae0 | ||
|
|
5567f26c03 | ||
|
|
0027485582 | ||
|
|
c9bcb7bab6 | ||
|
|
0ee261930e | ||
|
|
3cfc8dded9 | ||
|
|
655cf6d0ac |
@@ -677,6 +677,19 @@
|
||||
show_root_heading: false
|
||||
heading_level: 0
|
||||
|
||||
## S19k Pro Dual (ePIC)
|
||||
|
||||
- [x] Shutdowns
|
||||
- [ ] Power Modes
|
||||
- [ ] Setpoints
|
||||
- [ ] Presets
|
||||
|
||||
::: pyasic.miners.antminer.epic.X19.S19.ePICS19kProDual
|
||||
handler: python
|
||||
options:
|
||||
show_root_heading: false
|
||||
heading_level: 0
|
||||
|
||||
## S19 (Hive)
|
||||
|
||||
- [ ] Shutdowns
|
||||
|
||||
@@ -40,6 +40,19 @@
|
||||
show_root_heading: false
|
||||
heading_level: 0
|
||||
|
||||
## S21+ (Stock)
|
||||
|
||||
- [x] Shutdowns
|
||||
- [x] Power Modes
|
||||
- [ ] Setpoints
|
||||
- [ ] Presets
|
||||
|
||||
::: pyasic.miners.antminer.bmminer.X21.S21.BMMinerS21Plus
|
||||
handler: python
|
||||
options:
|
||||
show_root_heading: false
|
||||
heading_level: 0
|
||||
|
||||
## T21 (Stock)
|
||||
|
||||
- [x] Shutdowns
|
||||
|
||||
@@ -27,3 +27,16 @@
|
||||
show_root_heading: false
|
||||
heading_level: 0
|
||||
|
||||
## BlockMiner eLITE 1.0 (ePIC)
|
||||
|
||||
- [x] Shutdowns
|
||||
- [ ] Power Modes
|
||||
- [ ] Setpoints
|
||||
- [ ] Presets
|
||||
|
||||
::: pyasic.miners.blockminer.epic.blockminer.blockminer.ePICBlockMinerELITE1
|
||||
handler: python
|
||||
options:
|
||||
show_root_heading: false
|
||||
heading_level: 0
|
||||
|
||||
|
||||
@@ -103,6 +103,7 @@ details {
|
||||
<li><a href="../antminer/X21#s21-stock">S21 (Stock)</a></li>
|
||||
<li><a href="../antminer/X21#s21-stock">S21 (Stock)</a></li>
|
||||
<li><a href="../antminer/X21#s21-stock">S21 (Stock)</a></li>
|
||||
<li><a href="../antminer/X21#s21_1-stock">S21+ (Stock)</a></li>
|
||||
<li><a href="../antminer/X21#s21-pro-stock">S21 Pro (Stock)</a></li>
|
||||
<li><a href="../antminer/X21#t21-stock">T21 (Stock)</a></li>
|
||||
<li><a href="../antminer/X21#s21-hydro-stock">S21 Hydro (Stock)</a></li>
|
||||
@@ -736,6 +737,7 @@ details {
|
||||
<li><a href="../antminer/X19#s19k-pro-epic">S19k Pro (ePIC)</a></li>
|
||||
<li><a href="../antminer/X19#s19-xp-epic">S19 XP (ePIC)</a></li>
|
||||
<li><a href="../antminer/X19#s19j-pro-dual-epic">S19j Pro Dual (ePIC)</a></li>
|
||||
<li><a href="../antminer/X19#s19k-pro-dual-epic">S19k Pro Dual (ePIC)</a></li>
|
||||
</ul>
|
||||
</details>
|
||||
<details>
|
||||
@@ -751,6 +753,7 @@ details {
|
||||
<ul>
|
||||
<li><a href="../blockminer/blockminer#blockminer-520i-epic">BlockMiner 520i (ePIC)</a></li>
|
||||
<li><a href="../blockminer/blockminer#blockminer-720i-epic">BlockMiner 720i (ePIC)</a></li>
|
||||
<li><a href="../blockminer/blockminer#blockminer-elite-1.0-epic">BlockMiner eLITE 1.0 (ePIC)</a></li>
|
||||
</ul>
|
||||
</details>
|
||||
</ul>
|
||||
|
||||
@@ -258,18 +258,18 @@ class MiningModePowerTune(MinerConfigValue):
|
||||
sd_cfg = {}
|
||||
if self.scaling.shutdown is not None:
|
||||
sd_cfg = self.scaling.shutdown.as_boser()
|
||||
cfg["set_dps"] = (
|
||||
SetDpsRequest(
|
||||
enable=True,
|
||||
**sd_cfg,
|
||||
target=DpsTarget(
|
||||
power_target=DpsPowerTarget(
|
||||
power_step=Power(self.scaling.step),
|
||||
min_power_target=Power(self.scaling.minimum),
|
||||
)
|
||||
),
|
||||
),
|
||||
power_target_kwargs = {}
|
||||
if self.scaling.step is not None:
|
||||
power_target_kwargs["power_step"] = Power(self.scaling.step)
|
||||
if self.scaling.minimum is not None:
|
||||
power_target_kwargs["min_power_target"] = Power(self.scaling.minimum)
|
||||
cfg["set_dps"] = SetDpsRequest(
|
||||
save_action=SaveAction.SAVE_AND_APPLY,
|
||||
enable=True,
|
||||
**sd_cfg,
|
||||
target=DpsTarget(power_target=DpsPowerTarget(**power_target_kwargs)),
|
||||
)
|
||||
|
||||
return cfg
|
||||
|
||||
def as_auradine(self) -> dict:
|
||||
@@ -330,7 +330,6 @@ class MiningModeHashrateTune(MinerConfigValue):
|
||||
conf["hashrate_target"] = self.hashrate
|
||||
return {"autotuning": conf}
|
||||
|
||||
@property
|
||||
def as_boser(self) -> dict:
|
||||
cfg = {
|
||||
"set_performance_mode": SetPerformanceModeRequest(
|
||||
@@ -350,18 +349,24 @@ class MiningModeHashrateTune(MinerConfigValue):
|
||||
sd_cfg = {}
|
||||
if self.scaling.shutdown is not None:
|
||||
sd_cfg = self.scaling.shutdown.as_boser()
|
||||
cfg["set_dps"] = (
|
||||
SetDpsRequest(
|
||||
enable=True,
|
||||
**sd_cfg,
|
||||
target=DpsTarget(
|
||||
hashrate_target=DpsHashrateTarget(
|
||||
hashrate_step=TeraHashrate(self.scaling.step),
|
||||
min_hashrate_target=TeraHashrate(self.scaling.minimum),
|
||||
)
|
||||
),
|
||||
hashrate_target_kwargs = {}
|
||||
if self.scaling.step is not None:
|
||||
hashrate_target_kwargs["hashrate_step"] = TeraHashrate(
|
||||
self.scaling.step
|
||||
)
|
||||
if self.scaling.minimum is not None:
|
||||
hashrate_target_kwargs["min_hashrate_target"] = TeraHashrate(
|
||||
self.scaling.minimum
|
||||
)
|
||||
cfg["set_dps"] = SetDpsRequest(
|
||||
save_action=SaveAction.SAVE_AND_APPLY,
|
||||
enable=True,
|
||||
**sd_cfg,
|
||||
target=DpsTarget(
|
||||
hashrate_target=DpsHashrateTarget(**hashrate_target_kwargs)
|
||||
),
|
||||
)
|
||||
|
||||
return cfg
|
||||
|
||||
def as_auradine(self) -> dict:
|
||||
|
||||
@@ -58,6 +58,7 @@ class AntminerModels(MinerModelType):
|
||||
S19jXP = "S19j XP"
|
||||
T19 = "T19"
|
||||
S21 = "S21"
|
||||
S21Plus = "S21+"
|
||||
S21Pro = "S21 Pro"
|
||||
S21Hydro = "S21 Hydro"
|
||||
T21 = "T21"
|
||||
@@ -480,7 +481,9 @@ class GoldshellModels(MinerModelType):
|
||||
class ePICModels(MinerModelType):
|
||||
BM520i = "BlockMiner 520i"
|
||||
BM720i = "BlockMiner 720i"
|
||||
eLITE1 = "BlockMiner eLITE 1.0"
|
||||
S19jProDual = "S19j Pro Dual"
|
||||
S19kProDual = "S19k Pro Dual"
|
||||
|
||||
def __str__(self):
|
||||
return self.value
|
||||
|
||||
@@ -15,13 +15,17 @@
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
from pyasic.miners.backends import AntminerModern
|
||||
from pyasic.miners.device.models import S21, S21Hydro, S21Pro
|
||||
from pyasic.miners.device.models import S21, S21Hydro, S21Plus, S21Pro
|
||||
|
||||
|
||||
class BMMinerS21(AntminerModern, S21):
|
||||
pass
|
||||
|
||||
|
||||
class BMMinerS21Plus(AntminerModern, S21Plus):
|
||||
pass
|
||||
|
||||
|
||||
class BMMinerS21Pro(AntminerModern, S21Pro):
|
||||
pass
|
||||
|
||||
|
||||
@@ -13,5 +13,5 @@
|
||||
# See the License for the specific language governing permissions and -
|
||||
# limitations under the License. -
|
||||
# ------------------------------------------------------------------------------
|
||||
from .S21 import BMMinerS21, BMMinerS21Hydro, BMMinerS21Pro
|
||||
from .S21 import BMMinerS21, BMMinerS21Hydro, BMMinerS21Plus, BMMinerS21Pro
|
||||
from .T21 import BMMinerT21
|
||||
|
||||
@@ -59,3 +59,9 @@ class ePICS19jProDual(ePIC, S19jPro):
|
||||
raw_model = MinerModel.EPIC.S19jProDual
|
||||
expected_fans = S19jPro.expected_fans * 2
|
||||
expected_hashboards = S19jPro.expected_hashboards * 2
|
||||
|
||||
|
||||
class ePICS19kProDual(ePIC, S19kPro):
|
||||
raw_model = MinerModel.EPIC.S19kProDual
|
||||
expected_fans = S19kPro.expected_fans * 2
|
||||
expected_hashboards = S19kPro.expected_hashboards * 2
|
||||
|
||||
@@ -21,6 +21,7 @@ from .S19 import (
|
||||
ePICS19jProDual,
|
||||
ePICS19jProPlus,
|
||||
ePICS19kPro,
|
||||
ePICS19kProDual,
|
||||
ePICS19Pro,
|
||||
ePICS19XP,
|
||||
)
|
||||
|
||||
@@ -21,7 +21,7 @@ from pyasic.config import MinerConfig
|
||||
from pyasic.data import Fan, HashBoard
|
||||
from pyasic.data.error_codes import MinerErrorData, X19Error
|
||||
from pyasic.data.pools import PoolMetrics, PoolUrl
|
||||
from pyasic.device.algorithm import AlgoHashRate
|
||||
from pyasic.device.algorithm import AlgoHashRate, ScryptAlgo
|
||||
from pyasic.errors import APIError
|
||||
from pyasic.logger import logger
|
||||
from pyasic.miners.data import DataFunction, DataLocations, DataOptions, WebAPICommand
|
||||
@@ -138,6 +138,8 @@ class ePIC(ePICFirmware):
|
||||
await self.web.set_ptune_algo(conf["ptune"])
|
||||
|
||||
## Pools
|
||||
if self.algo == ScryptAlgo:
|
||||
conf["pools"]["coin"] = "Ltc"
|
||||
await self.web.set_pools(conf["pools"])
|
||||
except APIError:
|
||||
pass
|
||||
|
||||
@@ -86,6 +86,7 @@ class LUXMiner(LuxOSFirmware):
|
||||
|
||||
supports_shutdown = True
|
||||
supports_presets = True
|
||||
supports_autotuning = True
|
||||
|
||||
data_locations = LUXMINER_DATA_LOC
|
||||
|
||||
@@ -191,10 +192,10 @@ class LUXMiner(LuxOSFirmware):
|
||||
try:
|
||||
if await self.atm_enabled():
|
||||
re_enable_atm = True
|
||||
await self.rpc.atmset("enabled=false")
|
||||
await self.rpc.atmset(enabled=False)
|
||||
result = await self.rpc.profileset(new_preset)
|
||||
if re_enable_atm:
|
||||
await self.rpc.atmset("enabled=true")
|
||||
await self.rpc.atmset(enabled=True)
|
||||
except APIError:
|
||||
raise
|
||||
except Exception as e:
|
||||
|
||||
@@ -14,4 +14,4 @@
|
||||
# limitations under the License. -
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
from .blockminer import ePICBlockMiner520i, ePICBlockMiner720i
|
||||
from .blockminer import *
|
||||
|
||||
@@ -15,7 +15,11 @@
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
from pyasic.miners.backends import ePIC
|
||||
from pyasic.miners.device.models import BlockMiner520i, BlockMiner720i
|
||||
from pyasic.miners.device.models import (
|
||||
BlockMiner520i,
|
||||
BlockMiner720i,
|
||||
BlockMinerELITE1,
|
||||
)
|
||||
|
||||
|
||||
class ePICBlockMiner520i(ePIC, BlockMiner520i):
|
||||
@@ -24,3 +28,7 @@ class ePICBlockMiner520i(ePIC, BlockMiner520i):
|
||||
|
||||
class ePICBlockMiner720i(ePIC, BlockMiner720i):
|
||||
pass
|
||||
|
||||
|
||||
class ePICBlockMinerELITE1(ePIC, BlockMinerELITE1):
|
||||
pass
|
||||
|
||||
@@ -27,6 +27,15 @@ class S21(AntMinerMake):
|
||||
algo = MinerAlgo.SHA256
|
||||
|
||||
|
||||
class S21Plus(AntMinerMake):
|
||||
raw_model = MinerModel.ANTMINER.S21Plus
|
||||
|
||||
expected_chips = 55
|
||||
expected_fans = 4
|
||||
expected_hashboards = 3
|
||||
algo = MinerAlgo.SHA256
|
||||
|
||||
|
||||
class S21Pro(AntMinerMake):
|
||||
raw_model = MinerModel.ANTMINER.S21Pro
|
||||
|
||||
|
||||
@@ -14,5 +14,5 @@
|
||||
# limitations under the License. -
|
||||
# ------------------------------------------------------------------------------
|
||||
|
||||
from .S21 import S21, S21Hydro, S21Pro
|
||||
from .S21 import S21, S21Hydro, S21Plus, S21Pro
|
||||
from .T21 import T21
|
||||
|
||||
@@ -19,3 +19,12 @@ class BlockMiner720i(ePICMake):
|
||||
expected_fans = 4
|
||||
expected_hashboards = 3
|
||||
algo = MinerAlgo.SHA256
|
||||
|
||||
|
||||
class BlockMinerELITE1(ePICMake):
|
||||
raw_model = MinerModel.EPIC.eLITE1
|
||||
|
||||
expected_chips = 105
|
||||
expected_fans = 4
|
||||
expected_hashboards = 3
|
||||
algo = MinerAlgo.SCRYPT
|
||||
|
||||
@@ -120,6 +120,7 @@ MINER_CLASSES = {
|
||||
"ANTMINER S21": BMMinerS21,
|
||||
"ANTMINER BHB68601": BMMinerS21, # ???
|
||||
"ANTMINER BHB68606": BMMinerS21, # ???
|
||||
"ANTMINER S21+": BMMinerS21Plus,
|
||||
"ANTMINER S21 PRO": BMMinerS21Pro,
|
||||
"ANTMINER T21": BMMinerT21,
|
||||
"ANTMINER S21 HYD.": BMMinerS21Hydro,
|
||||
@@ -592,8 +593,10 @@ MINER_CLASSES = {
|
||||
"ANTMINER S21 PRO": ePICS21Pro,
|
||||
"ANTMINER T21": ePICT21,
|
||||
"ANTMINER S19J PRO DUAL": ePICS19jProDual,
|
||||
"ANTMINER S19K PRO DUAL": ePICS19kProDual,
|
||||
"BLOCKMINER 520I": ePICBlockMiner520i,
|
||||
"BLOCKMINER 720I": ePICBlockMiner720i,
|
||||
"BLOCKMINER ELITE 1.0": ePICBlockMinerELITE1,
|
||||
},
|
||||
MinerTypes.HIVEON: {
|
||||
None: HiveonModern,
|
||||
@@ -876,8 +879,6 @@ class MinerFactory:
|
||||
return MinerTypes.INNOSILICON
|
||||
if "Miner UI" in web_text:
|
||||
return MinerTypes.AURADINE
|
||||
if "<title>Antminer</title>" in web_text:
|
||||
return MinerTypes.MSKMINER
|
||||
|
||||
async def _get_miner_socket(self, ip: str) -> MinerTypes | None:
|
||||
commands = ["version", "devdetails"]
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
[project]
|
||||
name = "pyasic"
|
||||
version = "0.72.1"
|
||||
version = "0.72.4"
|
||||
|
||||
description = "A simplified and standardized interface for Bitcoin ASICs."
|
||||
authors = [{name = "UpstreamData", email = "brett@upstreamdata.ca"}]
|
||||
|
||||
Reference in New Issue
Block a user