From 24980cee6f5c09f5ef12256f26959ce84c4702e3 Mon Sep 17 00:00:00 2001 From: yuriy0803 <68668177+yuriy0803@users.noreply.github.com> Date: Fri, 8 Sep 2023 18:44:02 +0200 Subject: [PATCH] Update miner.go --- proxy/miner.go | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/proxy/miner.go b/proxy/miner.go index 15035d8..f75ad31 100644 --- a/proxy/miner.go +++ b/proxy/miner.go @@ -85,8 +85,16 @@ func (s *ProxyServer) processShare(login, id, ip string, t *BlockTemplate, param } if s.config.Proxy.Debug { - hashrate := formatHashrate(shareDiffCalc) - log.Printf("Difficulty pool/block/share = %d / %d / %d(%s) from %v@%v", shareDiff, t.Difficulty, shareDiffCalc, hashrate, login, ip) + hashrateShareDiff := formatHashrate(shareDiffCalc) + hashrateBlockDiff := formatHashrate(t.Difficulty.Int64()) // Konvertieren zu int64 + hashrateShare := formatHashrate(shareDiff) + + // Ausgabe der formatierten Informationen in der Kommandozeile (cmd) + log.Printf("Mining Information:") + log.Printf("Pool Difficulty: %d (%s)", shareDiff, hashrateShareDiff) + log.Printf("Block Difficulty: %d (%s)", t.Difficulty.Int64(), hashrateBlockDiff) + log.Printf("Share Difficulty: %d (%s)", shareDiffCalc, hashrateShare) + log.Printf("Submitted by: %v@%v", login, ip) } h, ok := t.headers[hashNoNonce]