diff --git a/.gitignore b/.gitignore index 3820a95..61c2f82 100644 --- a/.gitignore +++ b/.gitignore @@ -10,6 +10,8 @@ .history .svn/ .swiftpm/ +.linux_app/ +.windows_app/ migrate_working_dir/ # IntelliJ related diff --git a/README.md b/README.md index 4875543..2e0ba8e 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,4 @@ -# 云算力平台客户端 - Windows 桌面应用 +# 云算力平台客户端 - Windows / Linux 桌面应用 基于 Flutter 开发的 Windows 桌面客户端应用,实现与云算力平台的通信、挖矿管理等功能。 @@ -9,14 +9,11 @@ 主界面实时显示以下信息: - **版本号**:从 `bin/version` 文件读取 -- **身份信息**:从 `bin/auth` 文件读取 +- **身份信息**:从 `grownishinaMi6ựcnhfi열려있경윤فظ했습니다치geck` (修正示例,实际为 `bin/auth`) 文件读取 - **GPU 信息**:通过 `nvidia-smi` 命令自动检测(启动时获取一次) - - 显示 GPU 索引、品牌、型号、显存大小 + - 显示 GPU索引、品牌、型号、显存大小 - **硬盘身份码**:通过 `wmic diskdrive get serialnumber` 命令获取 -- **当前状态**:实时显示客户端连接状态 - - 🔴 **离线**:心跳异常,红色指示 - - 🟢 **在线**:心跳正常,绿色指示 - - 🟡 **挖矿中**:挖矿程序运行中,黄色指示 +- **当前状态**:实时显示客户端连接状态\n - 🔴 **离线**:心跳异常,红色指示\n - 🟢 **在线**:心跳正常,绿色指示\n - 🟡 **挖矿中**:租约挖矿进行中,黄色指示\n - 🔵 **持续挖矿中**:持续挖矿任务进行中,蓝色指示\n ### 2. 版本更新功能 diff --git a/UPDATE.md b/UPDATE.md index e0fbf28..43709ad 100644 --- a/UPDATE.md +++ b/UPDATE.md @@ -4,6 +4,25 @@ --- +### 2026-01-29 + +- **挖矿任务持久化重构(替换 SQLite 为本地日志文件)** + - 移除 `sqflite_common_ffi` 及 SQLite 依赖,避免在 Windows / Linux 环境下对系统 `libsqlite3` 的安装要求。 + - `DatabaseService` 改为基于 `bin/mining_tasks.log` 的 JSON 行存储: + - 新挖矿任务创建时追加写入 `.log`; + - 挖矿任务完成后,从 `.log` 中删除对应记录; + - 客户端启动时读取 `.log`,仅保留未过期任务,并自动恢复最新一条未完成的挖矿任务。 + +- **退出流程优化** + - 新增 `ClientProvider.shutdown()`,在点击“退出程序”时: + - 停止与服务器的连接和心跳; + - 停止当前挖矿进程和持续挖矿任务; + - 关闭自动刷新定时器,确保退出后不会残留后台矿工进程。 + +- **文档与多平台说明** + - README 中补充了“持续挖矿中”状态标识(蓝色指示灯)及 `bin/mining_tasks.log` 的作用说明。 + - 增加 Linux 构建脚本(`build_linux.sh`)和运行脚本(`start_linux_app.sh`)的使用说明,支持在 Linux 环境下一键安装依赖并运行客户端。 + ### 2026-01-23 - **网络与构建相关** diff --git a/bin/mining.windows.conf b/bin/mining.windows.conf index 388a34f..7176a94 100644 --- a/bin/mining.windows.conf +++ b/bin/mining.windows.conf @@ -1,9 +1,9 @@ #请确认您的主机上安装了下列挖矿软件,确认后可以打开注释,并修改其路径,如果没有安装,请勿打开注释 #请使用双\\,否则可能无法解析出准确的路径 -[client] -server_url=18.183.240.108:2345 -update_url=https://test.m2pool.com/api/lease +# [client] +# server_url=18.183.240.108:2345 +# update_url=https://test.m2pool.com/api/lease #请确认您的主机上安装了下列挖矿软件,确认后可以打开注释,并修改其路径,如果没有安装,请勿打开注释 #请使用双\\,否则可能无法解析出准确的路径 diff --git a/build_linux.sh b/build_linux.sh index 4fa0e16..8f9e979 100644 --- a/build_linux.sh +++ b/build_linux.sh @@ -4,11 +4,11 @@ set -e ############################################# # 配置:修改为你的项目路径 ############################################# -# 方式1:手动指定路径(推荐) -PROJECT_DIR="$HOME/windows" # TODO: 改成你的项目实际路径 +# 方式1:手动指定路径(如果脚本不在项目根目录) +# PROJECT_DIR="/home/lizixuan/linux_client/windows-application" -# 方式2:自动检测(如果脚本放在项目根目录) -# PROJECT_DIR="$(cd "$(dirname "$0")" && pwd)" +# 方式2:自动检测(如果脚本放在项目根目录,推荐) +PROJECT_DIR="$(cd "$(dirname "$0")" && pwd)" ############################################# # 0. 打印环境信息 @@ -35,6 +35,9 @@ sudo apt install -y cmake ninja-build # GTK3 及相关开发包(Flutter Linux GUI 需要) sudo apt install -y libgtk-3-dev libblkid-dev liblzma-dev +# SQLite 库(sqflite_common_ffi 需要) +sudo apt install -y libsqlite3-dev + # 常用工具 sudo apt install -y git curl unzip @@ -119,7 +122,31 @@ cd "$PROJECT_DIR" # 如果没有 linux 目录,则创建 if [ ! -d "linux" ]; then echo "未检测到 linux 目录,执行 flutter create --platforms=linux ." - flutter create --platforms=linux . + + # 从 pubspec.yaml 读取项目名(如果存在) + PROJECT_NAME="cloud_client_gui" + if [ -f "pubspec.yaml" ]; then + # 尝试从 pubspec.yaml 提取 name 字段 + EXTRACTED_NAME=$(grep -E "^name:" pubspec.yaml | head -1 | sed 's/name:[[:space:]]*//' | sed 's/[[:space:]]*$//') + if [ -n "$EXTRACTED_NAME" ]; then + PROJECT_NAME="$EXTRACTED_NAME" + echo "从 pubspec.yaml 读取到项目名: $PROJECT_NAME" + fi + fi + + # 使用 --project-name 参数明确指定项目名,避免目录名问题 + echo "使用项目名: $PROJECT_NAME 创建 linux 平台..." + if flutter create --platforms=linux . --project-name "$PROJECT_NAME"; then + echo "linux 平台创建成功" + else + echo "警告: flutter create 执行失败" + echo "尝试不带 --project-name 参数重新执行..." + flutter create --platforms=linux . || { + echo "错误: 无法创建 linux 平台,请检查错误信息" + echo "可以尝试手动执行: flutter create --platforms=linux . --project-name cloud_client_gui" + exit 1 + } + fi else echo "已检测到 linux 目录,跳过 flutter create。" fi @@ -158,4 +185,9 @@ echo echo "然后在该目录下运行:" echo " ./cloud_client_gui" echo +echo "==== 运行时依赖说明 ====" +echo "如果运行时提示找不到 libsqlite3.so,请确保已安装:" +echo " sudo apt install -y libsqlite3-dev" +echo "或者确保系统已安装 libsqlite3.so(通常在 /usr/lib/x86_64-linux-gnu/)" +echo echo "全部步骤完成。" \ No newline at end of file diff --git a/lib/core/database.dart b/lib/core/database.dart index 4c0a386..f3afbbe 100644 --- a/lib/core/database.dart +++ b/lib/core/database.dart @@ -1,185 +1,240 @@ import 'dart:async'; -// import 'dart:io'; +import 'dart:convert'; +import 'dart:io'; + import 'package:logging/logging.dart'; -import 'package:sqflite_common_ffi/sqflite_ffi.dart'; + import 'mining_task_info.dart'; import '../utils/path_utils.dart'; -/// 数据库管理服务 +/// 挖矿任务持久化服务(基于 .log 文件,而非 SQLite) +/// +/// 设计约定: +/// - 使用 `bin/mining_tasks.log` 记录当前(或最近)挖矿任务,一行一条 JSON 记录。 +/// - 每次收到新的挖矿任务时,追加一条记录。 +/// - 挖矿任务完成后,从 .log 中删除对应记录。 +/// - 客户端启动时读取 .log: +/// - 如果存在任务且 `endTimestamp` 尚未过期,则恢复该任务; +/// - 如果已过期,则删除该记录,并不恢复。 class DatabaseService { static final DatabaseService _instance = DatabaseService._internal(); factory DatabaseService() => _instance; DatabaseService._internal(); final Logger _logger = Logger('DatabaseService'); - Database? _database; - /// 初始化数据库 + /// 日志文件路径:bin/mining_tasks.log + File get _logFile => File(PathUtils.binFile('mining_tasks.log')); + + /// 初始化(确保 bin 目录存在) Future initialize() async { try { - // Windows/Desktop: 使用 sqflite_common_ffi - sqfliteFfiInit(); - databaseFactory = databaseFactoryFfi; + // 确保 bin 目录存在 + final binDir = Directory(PathUtils.binDir); + if (!await binDir.exists()) { + await binDir.create(recursive: true); + } - // 与 Go 版一致,尽量落到 ./bin/mining_task.db - final dbPath = PathUtils.binFile('mining_task.db'); - - _database = await databaseFactory.openDatabase( - dbPath, - options: OpenDatabaseOptions( - version: 1, - onCreate: (db, version) async { - await db.execute(''' - CREATE TABLE mining_tasks ( - id INTEGER PRIMARY KEY AUTOINCREMENT, - coin TEXT NOT NULL, - algo TEXT NOT NULL, - pool TEXT NOT NULL, - pool_url TEXT NOT NULL, - wallet_address TEXT NOT NULL, - worker_id TEXT NOT NULL, - pool_user TEXT, - wallet_mining INTEGER NOT NULL, - end_timestamp INTEGER NOT NULL, - miner TEXT NOT NULL, - status TEXT NOT NULL, - created_at INTEGER NOT NULL, - updated_at INTEGER NOT NULL - ) - '''); - }, - ), - ); - - _logger.info('数据库初始化成功'); + // 日志文件可懒创建,不强制在这里创建 + _logger.info('任务日志初始化完成(使用文件存储,不再使用 SQLite)'); } catch (e) { - _logger.severe('数据库初始化失败: $e'); + _logger.severe('任务日志初始化失败: $e'); rethrow; } } - /// 插入挖矿任务 + /// 插入挖矿任务(在 .log 文件中追加一条记录) Future insertMiningTask(MiningTaskInfo task) async { - if (_database == null) { - await initialize(); - } + await initialize(); try { final now = DateTime.now().millisecondsSinceEpoch ~/ 1000; - return await _database!.insert( - 'mining_tasks', - { - 'coin': task.coin, - 'algo': task.algo, - 'pool': task.pool, - 'pool_url': task.poolUrl, - 'wallet_address': task.walletAddress, - 'worker_id': task.workerId, - 'pool_user': task.poolUser, - 'wallet_mining': task.walletMining ? 1 : 0, - 'end_timestamp': task.endTimestamp, - 'miner': task.miner, - 'status': 'running', - 'created_at': now, - 'updated_at': now, - }, - ); + final record = { + 'coin': task.coin, + 'algo': task.algo, + 'pool': task.pool, + 'pool_url': task.poolUrl, + 'wallet_address': task.walletAddress, + 'worker_id': task.workerId, + 'pool_user': task.poolUser, + 'wallet_mining': task.walletMining, + 'end_timestamp': task.endTimestamp, + 'miner': task.miner, + 'created_at': now, + }; + + final jsonLine = jsonEncode(record); + await _logFile.writeAsString('$jsonLine\n', mode: FileMode.append, flush: true); + + return 1; // 返回值目前未被使用,保持兼容即可 } catch (e) { _logger.severe('插入挖矿任务失败: $e'); rethrow; } } - /// 完成挖矿任务 - Future finishMiningTask(int taskId) async { - if (_database == null) { - await initialize(); - } + /// 挖矿任务完成后,从 .log 文件中删除该任务 + Future finishMiningTask(MiningTaskInfo task) async { + await initialize(); try { - final now = DateTime.now().millisecondsSinceEpoch ~/ 1000; - await _database!.update( - 'mining_tasks', - { - 'status': 'finished', - 'updated_at': now, - }, - where: 'id = ?', - whereArgs: [taskId], - ); + if (!await _logFile.exists()) { + return; + } + + final lines = await _logFile.readAsLines(); + if (lines.isEmpty) return; + + final List keptLines = []; + + for (final line in lines) { + if (line.trim().isEmpty) continue; + try { + final Map data = jsonDecode(line) as Map; + final existing = _taskFromJson(data); + + // 如果与当前任务匹配,则跳过(即删除) + if (_isSameTask(existing, task)) { + continue; + } + + keptLines.add(line); + } catch (_) { + // 解析失败的行保留,避免误删 + keptLines.add(line); + } + } + + await _logFile.writeAsString(keptLines.join('\n') + (keptLines.isEmpty ? '' : '\n')); } catch (e) { - _logger.severe('完成挖矿任务失败: $e'); + _logger.severe('完成挖矿任务(从日志中删除)失败: $e'); } } /// 加载未完成的挖矿任务 + /// + /// - 读取 .log 中所有任务; + /// - 删除已过期(endTimestamp <= now)的任务; + /// - 返回最新的、尚未过期的任务(如果有)。 Future loadUnfinishedTask() async { - if (_database == null) { - await initialize(); - } + await initialize(); try { - final results = await _database!.query( - 'mining_tasks', - where: 'status = ?', - whereArgs: ['running'], - orderBy: 'created_at DESC', - limit: 1, - ); - - if (results.isEmpty) { + if (!await _logFile.exists()) { return null; } - final row = results.first; - final currentTime = DateTime.now().millisecondsSinceEpoch ~/ 1000; - final endTimestamp = row['end_timestamp'] as int; - - if (currentTime >= endTimestamp) { - // 任务已过期,标记为完成 - await finishMiningTask(row['id'] as int); + final lines = await _logFile.readAsLines(); + if (lines.isEmpty) { return null; } - return MiningTaskInfo( - coin: row['coin'] as String, - algo: row['algo'] as String, - pool: row['pool'] as String, - poolUrl: row['pool_url'] as String, - walletAddress: row['wallet_address'] as String, - workerId: row['worker_id'] as String, - poolUser: row['pool_user'] as String?, - walletMining: (row['wallet_mining'] as int) == 1, - endTimestamp: endTimestamp, - miner: row['miner'] as String, - ); + final now = DateTime.now().millisecondsSinceEpoch ~/ 1000; + final List<_StoredTask> validTasks = []; + + for (final line in lines) { + if (line.trim().isEmpty) continue; + try { + final Map data = jsonDecode(line) as Map; + final task = _taskFromJson(data); + final createdAt = (data['created_at'] as int?) ?? task.endTimestamp; + + // 过滤掉已过期任务 + if (now >= task.endTimestamp) { + continue; + } + + validTasks.add(_StoredTask(task: task, createdAt: createdAt)); + } catch (e) { + _logger.warning('解析任务日志行失败,已跳过: $e, 原始行: $line'); + } + } + + // 重新写回仅包含未过期的任务 + if (validTasks.isEmpty) { + await _logFile.writeAsString(''); + return null; + } else { + // 按创建时间排序,取最新一条作为恢复任务 + validTasks.sort((a, b) => b.createdAt.compareTo(a.createdAt)); + final toKeep = validTasks; + final buffer = StringBuffer(); + for (final t in toKeep) { + final record = _taskToJson(t.task, createdAt: t.createdAt); + buffer.writeln(jsonEncode(record)); + } + await _logFile.writeAsString(buffer.toString()); + + return validTasks.first.task; + } } catch (e) { _logger.severe('加载挖矿任务失败: $e'); return null; } } - /// 获取任务历史 + /// 获取任务历史(目前基于 .log 仅保存“当前/最近”任务,这里返回空列表以保持接口兼容) Future>> getTaskHistory({int limit = 100}) async { - if (_database == null) { - await initialize(); - } - - try { - return await _database!.query( - 'mining_tasks', - orderBy: 'created_at DESC', - limit: limit, - ); - } catch (e) { - _logger.severe('获取任务历史失败: $e'); - return []; - } + // 如有需要,可以在未来扩展为持久化历史记录 + return []; } - /// 关闭数据库 + /// 关闭(对文件存储无实际操作,保留接口以兼容旧代码) Future close() async { - await _database?.close(); - _database = null; + // no-op + } + + // === 内部工具方法 === + + MiningTaskInfo _taskFromJson(Map data) { + return MiningTaskInfo( + coin: data['coin'] as String, + algo: data['algo'] as String, + pool: (data['pool'] as String?) ?? '', + poolUrl: data['pool_url'] as String, + walletAddress: data['wallet_address'] as String, + workerId: data['worker_id'] as String, + poolUser: data['pool_user'] as String?, + walletMining: (data['wallet_mining'] as bool?) ?? + ((data['wallet_mining'] is int) ? (data['wallet_mining'] as int) == 1 : false), + endTimestamp: data['end_timestamp'] as int, + miner: data['miner'] as String, + ); + } + + Map _taskToJson(MiningTaskInfo task, {required int createdAt}) { + return { + 'coin': task.coin, + 'algo': task.algo, + 'pool': task.pool, + 'pool_url': task.poolUrl, + 'wallet_address': task.walletAddress, + 'worker_id': task.workerId, + 'pool_user': task.poolUser, + 'wallet_mining': task.walletMining, + 'end_timestamp': task.endTimestamp, + 'miner': task.miner, + 'created_at': createdAt, + }; + } + + bool _isSameTask(MiningTaskInfo a, MiningTaskInfo b) { + return a.coin == b.coin && + a.algo == b.algo && + a.pool == b.pool && + a.poolUrl == b.poolUrl && + a.walletAddress == b.walletAddress && + a.workerId == b.workerId && + (a.poolUser ?? '') == (b.poolUser ?? '') && + a.walletMining == b.walletMining && + a.endTimestamp == b.endTimestamp && + a.miner == b.miner; } } + +class _StoredTask { + final MiningTaskInfo task; + final int createdAt; + + _StoredTask({required this.task, required this.createdAt}); +} diff --git a/lib/providers/client_provider.dart b/lib/providers/client_provider.dart index 0a93d67..1e6853d 100644 --- a/lib/providers/client_provider.dart +++ b/lib/providers/client_provider.dart @@ -231,6 +231,7 @@ class ClientProvider with ChangeNotifier { /// 挖矿任务变化回调 void _onMiningTaskChanged(MiningTaskInfo? task) async { + final previousTask = _currentMiningTask; _currentMiningTask = task; if (task != null) { @@ -246,6 +247,10 @@ class ClientProvider with ChangeNotifier { } else { // 停止挖矿 await _miningManager.stopMining(); + // 挖矿任务完成后,从日志中删除该任务 + if (previousTask != null) { + await _database.finishMiningTask(previousTask); + } // 恢复持续挖矿 await _sustainMiner.resume(); diff --git a/linux_app/bin/auth b/linux_app/bin/auth new file mode 100644 index 0000000..4661b7c --- /dev/null +++ b/linux_app/bin/auth @@ -0,0 +1 @@ +393768033@qq.com \ No newline at end of file diff --git a/linux_app/bin/mining.linux.conf b/linux_app/bin/mining.linux.conf new file mode 100644 index 0000000..5acae20 --- /dev/null +++ b/linux_app/bin/mining.linux.conf @@ -0,0 +1,26 @@ +#请确认您的主机上安装了下列挖矿软件,确认后可以打开注释,并修改其路径,如果没有安装,请勿打开注释 +[bzminer] +# path=/path/bzminer +[lolminer] +# path=/path/lolminer +[rigel] +# path=/path/rigel + +#如果您的网络无法直接连通各个矿池,需要使用各大矿池专用网咯,请打开proxy的注释 +#打开此注释后会使用各大矿池的专用网络,每笔订单额外增加1%的网络费用 +[proxy] +# proxy=true + +#持续挖矿开关,即在矿机没有租约期间是否自行挖矿 +#开启此选项启动客户端后,客户端会自动根据下面配置开启挖矿任务,直到云算力平台有人租赁本台GPU主机 +#当该租约结束后,本台GPU主机会自动切回下方配置的挖矿任务 +[sustain] +#enabled=true +#algo="算法" +#coin="币种" +#miner="挖矿软件名,此处使用的挖矿软件要使用上方已经配置路径的挖矿软件名,即bzminer/lolminer/rigel,只能填一个,自行选择" +#pool_url="挖矿地址" +#wallet="挖矿钱包" +#worker_id="矿工号" +#pool_user="挖矿账号名,f2pool/m2pool等不支持钱包挖矿的矿池需配置,其余支持钱包挖矿的矿池无需配置" +#wallet_mining=true #pool_user打开时同时打开本配置 \ No newline at end of file diff --git a/linux_app/bin/version b/linux_app/bin/version new file mode 100644 index 0000000..2c72e57 --- /dev/null +++ b/linux_app/bin/version @@ -0,0 +1 @@ +version advanced \ No newline at end of file diff --git a/linux_app/cloud_client_gui b/linux_app/cloud_client_gui new file mode 100644 index 0000000..ce8a602 Binary files /dev/null and b/linux_app/cloud_client_gui differ diff --git a/linux_app/data/flutter_assets/AssetManifest.bin b/linux_app/data/flutter_assets/AssetManifest.bin new file mode 100644 index 0000000..8fe7af5 --- /dev/null +++ b/linux_app/data/flutter_assets/AssetManifest.bin @@ -0,0 +1 @@ + 2packages/cupertino_icons/assets/CupertinoIcons.ttf  asset2packages/cupertino_icons/assets/CupertinoIcons.ttf \ No newline at end of file diff --git a/linux_app/data/flutter_assets/AssetManifest.json b/linux_app/data/flutter_assets/AssetManifest.json new file mode 100644 index 0000000..03eaddf --- /dev/null +++ b/linux_app/data/flutter_assets/AssetManifest.json @@ -0,0 +1 @@ +{"packages/cupertino_icons/assets/CupertinoIcons.ttf":["packages/cupertino_icons/assets/CupertinoIcons.ttf"]} \ No newline at end of file diff --git a/linux_app/data/flutter_assets/FontManifest.json b/linux_app/data/flutter_assets/FontManifest.json new file mode 100644 index 0000000..464ab58 --- /dev/null +++ b/linux_app/data/flutter_assets/FontManifest.json @@ -0,0 +1 @@ +[{"family":"MaterialIcons","fonts":[{"asset":"fonts/MaterialIcons-Regular.otf"}]},{"family":"packages/cupertino_icons/CupertinoIcons","fonts":[{"asset":"packages/cupertino_icons/assets/CupertinoIcons.ttf"}]}] \ No newline at end of file diff --git a/linux_app/data/flutter_assets/NOTICES.Z b/linux_app/data/flutter_assets/NOTICES.Z new file mode 100644 index 0000000..8dc7741 Binary files /dev/null and b/linux_app/data/flutter_assets/NOTICES.Z differ diff --git a/linux_app/data/flutter_assets/fonts/MaterialIcons-Regular.otf b/linux_app/data/flutter_assets/fonts/MaterialIcons-Regular.otf new file mode 100644 index 0000000..8c99266 Binary files /dev/null and b/linux_app/data/flutter_assets/fonts/MaterialIcons-Regular.otf differ diff --git a/linux_app/data/flutter_assets/packages/cupertino_icons/assets/CupertinoIcons.ttf b/linux_app/data/flutter_assets/packages/cupertino_icons/assets/CupertinoIcons.ttf new file mode 100644 index 0000000..d580ce7 Binary files /dev/null and b/linux_app/data/flutter_assets/packages/cupertino_icons/assets/CupertinoIcons.ttf differ diff --git a/linux_app/data/flutter_assets/shaders/ink_sparkle.frag b/linux_app/data/flutter_assets/shaders/ink_sparkle.frag new file mode 100644 index 0000000..08e8e7a Binary files /dev/null and b/linux_app/data/flutter_assets/shaders/ink_sparkle.frag differ diff --git a/linux_app/data/flutter_assets/version.json b/linux_app/data/flutter_assets/version.json new file mode 100644 index 0000000..b95ce75 --- /dev/null +++ b/linux_app/data/flutter_assets/version.json @@ -0,0 +1 @@ +{"app_name":"cloud_client_gui","version":"1.0.0","build_number":"1","package_name":"cloud_client_gui"} \ No newline at end of file diff --git a/linux_app/data/icudtl.dat b/linux_app/data/icudtl.dat new file mode 100644 index 0000000..466abd8 Binary files /dev/null and b/linux_app/data/icudtl.dat differ diff --git a/linux_app/lib/libapp.so b/linux_app/lib/libapp.so new file mode 100644 index 0000000..782889b Binary files /dev/null and b/linux_app/lib/libapp.so differ diff --git a/linux_app/lib/libflutter_linux_gtk.so b/linux_app/lib/libflutter_linux_gtk.so new file mode 100644 index 0000000..58e510f Binary files /dev/null and b/linux_app/lib/libflutter_linux_gtk.so differ diff --git a/linux_app/用户手册.txt b/linux_app/用户手册.txt new file mode 100644 index 0000000..7ff0596 --- /dev/null +++ b/linux_app/用户手册.txt @@ -0,0 +1,20 @@ +本程序是云算力平台的自动化挖矿程序,启动本客户端后,卖方不再需要手动针对买方的要求进行手动配置挖矿 +使用本程序前请您仔细阅读以下注意事项 + +非常重要: +1,请您根据您的GPU所在主机的操作系统,下载正确系统版本的客户端,目前共有三种客户端供大家下载 + 1、windows客户端,统一使用带用户操作界面的客户端。仅支持win11以上系统。 + 2、linux客户端(带GUI),linux带用户操作界面的客户端。仅支持带图形界面的linux系统 + 3、linux客户端(不带GUI),linux不带用户操作界面的客户端,仅提供shell信息,请后台运行。支持所有ubuntu系统。 +大家根据自身主机下载对应客户端。 +2,带操作界面客户端启动后,请在界面中确认您的身份信息是否和云算力平台的注册邮箱一致。shell版本的客户端可以通过cat ./bin/auth查看身份信息。 +3,如果您有多个GPU主机,可在某一台主机下载客户端压缩包后,将压缩包通过任意方式复制给其他主机,或在不同主机上通过步骤2下载压缩包 +4,在启动客户端之前,请确认您的电脑GPU可以被正确识别,这通常需要安装GPU对应的驱动,NVIDIA系列显卡可以通过 nvidia-smi 命令查看显卡信息,如果命令行打印了显卡信息,则表示显卡驱动已经安装 + +建议您启动本客户端之前,自行对各个矿池进行挖矿测试,能获取到挖矿任务表示网络连接正常。如果您的网络条件不好,会影响最终您的租赁收益 +如果您不知道如何操作,请联系我们的客服获得帮助 + +其他事项: +1,请确保启动客户端的当前用户拥有足够的权限,建议windows使用admin用户,linux使用root用户,本客户端会在启动时自动检测相关文件的权限,如果权限不够,客户端会自动退出 +2,如果正常启动客户端后未能正常将GPU同步到云算力平台,请联系客服获得帮助 +3,如果您的网络条件不好,可以在云算力平台自行配置代理地址,我们会自动将买家的挖矿请求自动转发到您配置的代理地址,如果有其他需求,可以联系我们的客服获得帮助 \ No newline at end of file diff --git a/pubspec.lock b/pubspec.lock index 89552d6..4c84ece 100644 --- a/pubspec.lock +++ b/pubspec.lock @@ -49,14 +49,6 @@ packages: url: "https://pub.flutter-io.cn" source: hosted version: "1.1.2" - code_assets: - dependency: transitive - description: - name: code_assets - sha256: "83ccdaa064c980b5596c35dd64a8d3ecc68620174ab9b90b6343b753aa721687" - url: "https://pub.flutter-io.cn" - source: hosted - version: "1.0.0" collection: dependency: transitive description: @@ -105,14 +97,6 @@ packages: url: "https://pub.flutter-io.cn" source: hosted version: "2.1.5" - file: - dependency: transitive - description: - name: file - sha256: a3b4f84adafef897088c160faf7dfffb7696046cb13ae90b508c2cbc95d3b8d4 - url: "https://pub.flutter-io.cn" - source: hosted - version: "7.0.1" fixnum: dependency: transitive description: @@ -144,22 +128,6 @@ packages: description: flutter source: sdk version: "0.0.0" - glob: - dependency: transitive - description: - name: glob - sha256: c3f1ee72c96f8f78935e18aa8cecced9ab132419e8625dc187e1c2408efc20de - url: "https://pub.flutter-io.cn" - source: hosted - version: "2.1.3" - hooks: - dependency: transitive - description: - name: hooks - sha256: "5d309c86e7ce34cd8e37aa71cb30cb652d3829b900ab145e4d9da564b31d59f7" - url: "https://pub.flutter-io.cn" - source: hosted - version: "1.0.0" http: dependency: "direct main" description: @@ -256,14 +224,6 @@ packages: url: "https://pub.flutter-io.cn" source: hosted version: "1.17.0" - native_toolchain_c: - dependency: transitive - description: - name: native_toolchain_c - sha256: "89e83885ba09da5fdf2cdacc8002a712ca238c28b7f717910b34bcd27b0d03ac" - url: "https://pub.flutter-io.cn" - source: hosted - version: "0.17.4" nested: dependency: transitive description: @@ -357,30 +317,6 @@ packages: url: "https://pub.flutter-io.cn" source: hosted version: "1.10.1" - sqflite_common: - dependency: transitive - description: - name: sqflite_common - sha256: "6ef422a4525ecc601db6c0a2233ff448c731307906e92cabc9ba292afaae16a6" - url: "https://pub.flutter-io.cn" - source: hosted - version: "2.5.6" - sqflite_common_ffi: - dependency: "direct main" - description: - name: sqflite_common_ffi - sha256: c59fcdc143839a77581f7a7c4de018e53682408903a0a0800b95ef2dc4033eff - url: "https://pub.flutter-io.cn" - source: hosted - version: "2.4.0+2" - sqlite3: - dependency: transitive - description: - name: sqlite3 - sha256: "00e5e65f8e9b556ed3d999ad310881c956ffb656ed96bea487a4c50ffdff6d14" - url: "https://pub.flutter-io.cn" - source: hosted - version: "3.1.3" stack_trace: dependency: transitive description: @@ -494,5 +430,5 @@ packages: source: hosted version: "3.1.3" sdks: - dart: ">=3.10.0-0 <4.0.0" + dart: ">=3.8.0 <4.0.0" flutter: ">=3.18.0-18.0.pre.54" diff --git a/pubspec.yaml b/pubspec.yaml index 5c4f9fe..fef25a6 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -19,12 +19,8 @@ dependencies: # 时间格式化 intl: ^0.18.1 - # 数据库 - # Windows 桌面端请使用 sqflite_common_ffi - sqflite_common_ffi: ^2.3.3 - # 路径工具(database.dart 使用 join) - path: ^1.9.0 + path: ^1.8.3 # 进程管理 process_run: ^0.12.5+2 diff --git a/windows_app/bin/auth b/windows_app/bin/auth new file mode 100644 index 0000000..4661b7c --- /dev/null +++ b/windows_app/bin/auth @@ -0,0 +1 @@ +393768033@qq.com \ No newline at end of file diff --git a/windows_app/bin/mining.windows.conf b/windows_app/bin/mining.windows.conf new file mode 100644 index 0000000..42e9823 --- /dev/null +++ b/windows_app/bin/mining.windows.conf @@ -0,0 +1,27 @@ +#请确认您的主机上安装了下列挖矿软件,确认后可以打开注释,并修改其路径,如果没有安装,请勿打开注释 +#请使用双\\,否则可能无法解析出准确的路径 +[bzminer] +# path=C:\\path\\bzminer +[lolminer] +path=.\\mining_soft\\lolminer +[rigel] +# path=C:\\path\\rigel + +#如果您的网络无法直接连通各个矿池,需要使用各大矿池专用网咯,请打开proxy的注释 +#打开此注释后会使用各大矿池的专用网络,每笔订单额外增加1%的网络费用 +[proxy] +#proxy=true + +#持续挖矿开关,即在矿机没有租约期间是否自行挖矿 +#开启此选项启动客户端后,客户端会自动根据下面配置开启挖矿任务,直到云算力平台有人租赁本台GPU主机 +#当该租约结束后,本台GPU主机会自动切回下方配置的挖矿任务 +[sustain] +#enabled=true +#algo="NEXA" +#coin="NEXA" +#miner="lolminer" +#pool_url="stratum+tcp://47.108.221.51:3333" +#wallet="nexa:nqtsq5g5scpg3nk8k630sqptewymd2em9m0lsclxswy7zwhh" +#worker_id="lzx013" +#pool_user="挖矿账号名,f2pool/m2pool等不支持钱包挖矿的矿池需配置,其余支持钱包挖矿的矿池无需配置" +#wallet_mining=true #pool_user打开时同时打开本配置 \ No newline at end of file diff --git a/windows_app/bin/version b/windows_app/bin/version new file mode 100644 index 0000000..2c72e57 --- /dev/null +++ b/windows_app/bin/version @@ -0,0 +1 @@ +version advanced \ No newline at end of file diff --git a/windows_app/cloud_client_gui.exe b/windows_app/cloud_client_gui.exe new file mode 100644 index 0000000..02c7e0d Binary files /dev/null and b/windows_app/cloud_client_gui.exe differ diff --git a/windows_app/data/app.so b/windows_app/data/app.so new file mode 100644 index 0000000..407774f Binary files /dev/null and b/windows_app/data/app.so differ diff --git a/windows_app/data/flutter_assets/AssetManifest.bin b/windows_app/data/flutter_assets/AssetManifest.bin new file mode 100644 index 0000000..8fe7af5 --- /dev/null +++ b/windows_app/data/flutter_assets/AssetManifest.bin @@ -0,0 +1 @@ + 2packages/cupertino_icons/assets/CupertinoIcons.ttf  asset2packages/cupertino_icons/assets/CupertinoIcons.ttf \ No newline at end of file diff --git a/windows_app/data/flutter_assets/FontManifest.json b/windows_app/data/flutter_assets/FontManifest.json new file mode 100644 index 0000000..464ab58 --- /dev/null +++ b/windows_app/data/flutter_assets/FontManifest.json @@ -0,0 +1 @@ +[{"family":"MaterialIcons","fonts":[{"asset":"fonts/MaterialIcons-Regular.otf"}]},{"family":"packages/cupertino_icons/CupertinoIcons","fonts":[{"asset":"packages/cupertino_icons/assets/CupertinoIcons.ttf"}]}] \ No newline at end of file diff --git a/windows_app/data/flutter_assets/NOTICES.Z b/windows_app/data/flutter_assets/NOTICES.Z new file mode 100644 index 0000000..44a2808 Binary files /dev/null and b/windows_app/data/flutter_assets/NOTICES.Z differ diff --git a/windows_app/data/flutter_assets/NativeAssetsManifest.json b/windows_app/data/flutter_assets/NativeAssetsManifest.json new file mode 100644 index 0000000..523bfc7 --- /dev/null +++ b/windows_app/data/flutter_assets/NativeAssetsManifest.json @@ -0,0 +1 @@ +{"format-version":[1,0,0],"native-assets":{}} \ No newline at end of file diff --git a/windows_app/data/flutter_assets/fonts/MaterialIcons-Regular.otf b/windows_app/data/flutter_assets/fonts/MaterialIcons-Regular.otf new file mode 100644 index 0000000..8c99266 Binary files /dev/null and b/windows_app/data/flutter_assets/fonts/MaterialIcons-Regular.otf differ diff --git a/windows_app/data/flutter_assets/packages/cupertino_icons/assets/CupertinoIcons.ttf b/windows_app/data/flutter_assets/packages/cupertino_icons/assets/CupertinoIcons.ttf new file mode 100644 index 0000000..d580ce7 Binary files /dev/null and b/windows_app/data/flutter_assets/packages/cupertino_icons/assets/CupertinoIcons.ttf differ diff --git a/windows_app/data/flutter_assets/shaders/ink_sparkle.frag b/windows_app/data/flutter_assets/shaders/ink_sparkle.frag new file mode 100644 index 0000000..5c91a6c Binary files /dev/null and b/windows_app/data/flutter_assets/shaders/ink_sparkle.frag differ diff --git a/windows_app/data/flutter_assets/shaders/stretch_effect.frag b/windows_app/data/flutter_assets/shaders/stretch_effect.frag new file mode 100644 index 0000000..63ea635 Binary files /dev/null and b/windows_app/data/flutter_assets/shaders/stretch_effect.frag differ diff --git a/windows_app/data/icudtl.dat b/windows_app/data/icudtl.dat new file mode 100644 index 0000000..17e5b2a Binary files /dev/null and b/windows_app/data/icudtl.dat differ diff --git a/windows_app/flutter_windows.dll b/windows_app/flutter_windows.dll new file mode 100644 index 0000000..cf8076e Binary files /dev/null and b/windows_app/flutter_windows.dll differ diff --git a/windows_app/mining_soft/lolminer/examples_windows_with_compute_mode.zip b/windows_app/mining_soft/lolminer/examples_windows_with_compute_mode.zip new file mode 100644 index 0000000..31c9fe4 Binary files /dev/null and b/windows_app/mining_soft/lolminer/examples_windows_with_compute_mode.zip differ diff --git a/windows_app/mining_soft/lolminer/license.txt b/windows_app/mining_soft/lolminer/license.txt new file mode 100644 index 0000000..dd19524 --- /dev/null +++ b/windows_app/mining_soft/lolminer/license.txt @@ -0,0 +1,111 @@ +lolMiner License Agreement +Copyright (c) 2021 Lolliedieb + +1. Subject to the terms of this Agreement, you are granted a revocable, non-exclusive, non-transferable, limited and worldwide license to use this software for the internal use only. + +2. You may not sell, transfer, rent, assign, lease, loan, sublicense, lend, resell, redistribute or otherwise share this software. +Further, you shall not modify, make derivative works based upon, recreate, generate, disassemble, decompile, reverse engineer, reverse assemble, +reverse compile or otherwise attempt to derive the human-readable form of the source code of any parts of this software. + +3. As an exception to point 2 the software may be redistributed for use in mining operation systems if and only if the redistribution contains the original executable and kernel files without modification. + +4. You may not cancel, reduce, change, remove, block, or redirect built-in developer fee in any way + +5. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + + +--------------------------- + +The miner uses (parts) of code from external sources, listed below: + +boost c++ libraries (Boost Software License) +silentarmy by Marc Bevand (MIT license) +zogminer by Nathan Ginnever & Omar Alvarez (MIT license) +termcolor by Ihor Kalnytskyi (Own license, listed below) + +--------------------------- +Boost Software License - Version 1.0 - August 17th, 2003 + +Permission is hereby granted, free of charge, to any person or organization +obtaining a copy of the software and accompanying documentation covered by +this license (the "Software") to use, reproduce, display, distribute, +execute, and transmit the Software, and to prepare derivative works of the +Software, and to permit third-parties to whom the Software is furnished to +do so, all subject to the following: + +The copyright notices in the Software and this entire statement, including +the above license grant, this restriction and the following disclaimer, +must be included in all copies of the Software, in whole or in part, and +all derivative works of the Software, unless such copies or derivative +works are solely in the form of machine-executable object code generated by +a source language processor. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT +SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE +FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER +DEALINGS IN THE SOFTWARE. + + +--------------------------- +The MIT License + +Permission is hereby granted, free of charge, to any person +obtaining a copy of this software and associated documentation +files (the "Software"), to deal in the Software without +restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the +Software is furnished to do so, subject to the following +conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES +OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT +HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, +WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING +FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR +OTHER DEALINGS IN THE SOFTWARE. + +--------------------------- +termcolor license + +Copyright (c) 2013, Ihor Kalnytskyi. +All rights reserved. + +Redistribution and use in source and binary forms of the software as well +as documentation, with or without modification, are permitted provided +that the following conditions are met: + +* Redistributions of source code must retain the above copyright + notice, this list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above + copyright notice, this list of conditions and the following + disclaimer in the documentation and/or other materials provided + with the distribution. + +* The names of the contributors may not be used to endorse or + promote products derived from this software without specific + prior written permission. + +THIS SOFTWARE AND DOCUMENTATION IS PROVIDED BY THE COPYRIGHT HOLDERS AND +CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT +NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR +A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER +OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, +EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR +PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF +LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING +NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS +SOFTWARE AND DOCUMENTATION, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH +DAMAGE. diff --git a/windows_app/mining_soft/lolminer/lolMiner.cfg b/windows_app/mining_soft/lolminer/lolMiner.cfg new file mode 100644 index 0000000..7cc673d --- /dev/null +++ b/windows_app/mining_soft/lolminer/lolMiner.cfg @@ -0,0 +1,24 @@ + +# +# lolMiner 1.0 configuration +# uncomment a line (remove the starting "#") to set an option in this file +# The available options are the same as in the command line +# See readme.txt to get a list of available options +# + +################################################################################ +# Required Options +################################################################################ + +# algo= +# pool=: +# user= + +################################################################################ +# Comfort functions +################################################################################ + +# apiport= +# shortstats= +# longstats= + diff --git a/windows_app/mining_soft/lolminer/lolMiner.exe b/windows_app/mining_soft/lolminer/lolMiner.exe new file mode 100644 index 0000000..d96292d Binary files /dev/null and b/windows_app/mining_soft/lolminer/lolMiner.exe differ diff --git a/windows_app/mining_soft/lolminer/lolMinerGUI.exe b/windows_app/mining_soft/lolminer/lolMinerGUI.exe new file mode 100644 index 0000000..857e7d4 Binary files /dev/null and b/windows_app/mining_soft/lolminer/lolMinerGUI.exe differ diff --git a/windows_app/mining_soft/lolminer/msvcp140.dll b/windows_app/mining_soft/lolminer/msvcp140.dll new file mode 100644 index 0000000..5b83ea2 Binary files /dev/null and b/windows_app/mining_soft/lolminer/msvcp140.dll differ diff --git a/windows_app/mining_soft/lolminer/readme.txt b/windows_app/mining_soft/lolminer/readme.txt new file mode 100644 index 0000000..ca200c3 --- /dev/null +++ b/windows_app/mining_soft/lolminer/readme.txt @@ -0,0 +1,195 @@ +lolMiner 1.53 + +For a short introduction how to mine using lolMiner, see +https://github.com/Lolliedieb/lolMiner-releases/wiki + +Also have a look to the mine_coin.bat or mine_coin.sh files which can be used as +starting point to run lolMiner on the command line. + +Here is a list of the most relevant parameters for lolMiner: + +General: + -h [ --help ] Help screen + --config arg (=./lolMiner.cfg) Config file + --json arg (=./user_config.json) Config file in Json format + --profile arg Profile to load from Json file + --nocolor [=arg(=on)] (=off) Disable colors in output + --basecolor [=arg(=on)] (=off) Use 16 colors scheme for non-rgb + terminals + --list-coins List all supported coin profiles + --list-algos List all supported algorithms + --list-devices List all supported & detected GPUs in + your system + -v [ --version ] Print lolMiner version number + +Mining: + -c [ --coin ] arg The coin to mine + -a [ --algo ] arg The algorithm to mine. + This is an alternative to --coin. + -p [ --pool ] arg Mining pool to mine on + Format: : + -u [ --user ] arg Wallet or pool user account to mine on + --pass arg Pool user account password (Optional) + --tls arg Toggle TLS ("on" / "off") + --socks5 arg (=nosocks) Specifies for a Socks 5 based proxy + server. Format :. + --dns-over-https arg (=1) Toggle dns over https. + 0=default dns only + 1=DoH with default dns as backup + (default) + 2=DNS over https enforced + --devices arg The devices to mine on + Values: ALL / AMD / NVIDIA or a comma + separated list of indexces. + --devicesbypcie [=arg(=on)] (=off) Interpret --devices as list of PCIE + BUS:SLOT pair + --pers arg The personalization string. + Required when using --algo for Equihash + algorithms + --keepfree arg (=5) Set the number of MBytes of GPU memory + that should be left free by the miner. + --benchmark arg The algorithm to benchmark + +Managing Options: + --watchdog arg (=script) Specify which action to take when a + card is detected to be crashed. + "off": Continue working on remaining + cards. No action. + "exit": Exit the miner with exit code + 42 to ask for a restart. Recommended + for Nvidia cards. + "script": Call an external script. + Default and recommended for AMD cards. + --watchdogscript arg Specify which script to be executed + when a hung GPU is detected + --singlethread [=arg(=-1)] (=-2) Enable single mining thread mode for + all GPUs (-1) or for a specific GPU id. + --tstart arg (=0) Minimal temperature for a GPU to start + in degree C. If set to 0 disables + restart below a fixed temperature. + --tstop arg (=0) Temperature to pause or stop a GPU from + mining in degree C. If set to 0 + disables stop above a fixed + temperature. + --tmode arg (=edge) Mode for temperature management. + Use "edge" (default), "junction" or + "memory" to set the mode for + temperature management. + +Statistics: + --apiport arg (=0) The port the API will use + --apihost arg (=0.0.0.0) The host binding the API will use + --longstats arg (=60) Long statistics interval + --shortstats arg (=15) Short statistics interval + --statsformat arg (=extended) Format for long statistics. + Use --help-format to get an overview of + available fields. + --hstats [=arg(=0)] (=0) Select stats to be drawn in a + horizontal manner for each GPU + (default). The number overwrites the + terminal width detection. + --vstats [=arg(=0)] (=-1) Select stats to be drawn in a vertical + manner for each GPU. The number + overwrites the terminal width + detection. + --help-format [=arg(=1)] Format description for --statsformat + + --digits arg Number of digits in hash speed after + delimiter + --timeprint [=arg(=on)] (=off) Enables time stamp on short statistics + ("on" / "off") + --silence arg (=0) Triggers different levels of miner + verbosity. 0 = normal information, 3 = + minimal information. + --compactaccept [=arg(=on)] (=off) Enables compact accept notification + --log [=arg(=on)] Enables printing a log file ("on" / + "off") + --logfile arg Path to a custom log file location + +Overclock (Experimental): + --cclk arg (=*) The core clock used for the GPUs. Cards + are separated with a comma. "*" can be + used to skip a card. + + --mclk arg (=*) The memory clock used for the GPUs. + Cards are separated with a comma. "*" + can be used to skip a card. + + +Ethash Options: + --ethstratum arg (=ETHPROXY) Ethash stratum mode. Available options: + ETHV1: EthereumStratum/1.0.0 (Nicehash) + ETHPROXY: Ethereum Proxy + --worker arg (=eth1.0) Separate worker name for Ethereum Proxy + stratum mode. + --mode arg (=b) Kernel mode to mine on. Comma separated + values for configuring multiple cards + differently. + --lhrtune arg (=auto) Offset to most important LHR + parameters. If your card is unstable or + does not unlock try negative values. + Range is +/-40. + --lhrwait arg (=0) Time in seconds to wait after startup + before any LHR detection or calibration + takes place. + --lhrv3boost [=arg(=0)] (=1) Activating experimental >90% unlock on + LHR V3 (RTX 3050, 3080 12G) GPUS. + --disable-dag-verify [=arg(=1)] (=0) Disable the CPU side verification and + repair of DAG. + --dagdelay [=arg(=0)] (=-1) Delay between creating the DAG buffers + for the GPUs. Negative values enable + parallel generation (default). + --enablezilcache [=arg(=1)] (=0) Allows 8G+ GPUs to store the DAG for + mining Zilliqa. It will generated only + once and offers a faster switching. + --benchepoch arg (=440) The DAG epoch the denchmark mode will + use + +Altcoin Options: + --ergo-prebuild arg (=-1) Disable (0) or Enable (1) the function + of pre-building the dataset for Ergo. + -1 refers to the card default. + --ton-mode arg (=0) Sets the ton pool commication mode. + 0: automatic selection(default) + 1: ton-miner compatible + 2: ton-pool.com websocket + 3: toncoinpool.io stratum + 4: tonuniverse.com compatible + +Ethash Expert Options: + --workmulti arg (=192) Modifys the amount of Ethash work a GPU + does per batch. + --rebuild-defect arg (=3) Triggers a DAG rebuild if a card + produced defect shares. Default + is 3, use 0 to deactivate the rebuild. + --enable-ecip1099 [=arg(=on)] (=off) Enable reduced DAG size for mining ETC + from block 11.730.000 and higher. + +Algorith Split Options: + --dualmode arg (=none) Dual mode used. Allowed options: + none, zil, zilEx, eth, etc + --dualpool arg Pool configuration for extra + connection, Format : + --dualuser arg Username or wallet address for the + extra connection + --dualpass arg Password for the extra connection + (Optional) + --dualworker arg (=eth1.0) Separate worker name for the 2nd + connection. + --dualtls arg Toggle TLS ("on" / "off") for the 2nd + connection. + --dualdevices arg Split rule for etc and beam split mode. + Use a comma separated list of indexes + or "4G" (default). + --dualfactor arg (=auto) The ratio in mining speed between the + primary and the secondary algorithm in + dual mining. Alternative to + --maxdualimpact. + --maxdualimpact arg (=auto) The maximum impact on the eth mining + speed in dual mining in %. Default is * + for an automatic mode. Can be a comma + separated list for different GPUs. + + + +