A python SDK for interacting with the bobcat miner.
Project description
bobcat-miner
A python SDK for interacting with the bobcat miner.
Install
pip install bobcat-miner
Autopilot Usage
Run bobcat autopilot
$ BOBCAT_IP_ADDRESS="x.x.x.x" bobcat-autopilot
2022-01-03 20:26:30,433 INFO starting bobcat autopilot...
2022-01-03 20:26:33,494 INFO refreshing status data...
2022-01-03 20:26:34,999 INFO refreshing miner data...
2022-01-03 20:26:45,749 INFO bobcat is healthy
Bobcat Usage
import bobcat_miner
bobcat = bobcat_miner.Bobcat(ip_address="x.x.x.x")
# data refresh
bobcat.refresh_status()
print(bobcat.status)
# {"status": "Synced", "gap": "0", "miner_height": "1148539", "blockchain_height": "1148539", "epoch": "30157"}
bobcat.refresh_miner()
print(bobcat.miner)
# {"ota_version": "1.0.2.66", "region": "region_us915", "frequency_plan": "us915", "animal": "my-mocked-miner", ... }
bobcat.refresh_speed()
print(bobcat.speed)
# {"DownloadSpeed": "94 Mbit/s", "UploadSpeed": "57 Mbit/s", "Latency": "7.669083ms"}
bobcat.refresh_dig()
print(bobcat.dig)
# {"name": "seed.helium.io.", "DNS": "Local DNS", "records": [{"A": "54.232.171.76", ... ]}
# actions
bobcat.reboot()
bobcat.resync()
bobcat.fastsync()
bobcat.reset()
# diagnostics
bobcat.is_healthy()
bobcat.is_running()
bobcat.is_synced()
bobcat.is_temp_safe()
bobcat.has_errors()
bobcat.is_relayed()
bobcat.should_reboot())
bobcat.should_resync()
bobcat.should_fastsync()
bobcat.should_reset()
# autopilot
bobcat.autopilot()
:warning: bobcat.refresh_speed()
takes about 30 seconds to complete and you should not call it repeatedly. Doing so will slow down your internet speed, which in turn will slow down your miner.
Troubleshooting
Please see No Witness's Troubleshooting Guide for more information troubleshooting your bobcat miner.
Donations
Donations are welcome and appreciated!
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
bobcat-miner-0.2.2.tar.gz
(8.6 kB
view hashes)
Built Distribution
Close
Hashes for bobcat_miner-0.2.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | fc08b3b3619c01e2227f6689a4db67b56ee0254d506307f6b479b3bee394d218 |
|
MD5 | 84111a919cd60a92c2d62ea53e48fcbd |
|
BLAKE2b-256 | 58f017df99264325d2fe06b0834e65f5c42face55432e2ce048d75df179c4c3f |