I'm on the hunt for some reference code for solo mining. I need something that takes a getblocktemplate JSON from my local bitcoind and submits the nonce back to it on testnet. Anyone got any examples in Python, C, or even Verilog?
I'm especially interested in how to pull data from the getblocktemplate, feed it into the SHA256 hasher, and then how to send the found nonce back to the bitcoind. I know the hashing process is pretty straightforward, but the BIP terminology is confusing... some code would help clear things up for me.
Seeking Reference Code for Mining with GetBlockTemplate
7 replies 416 views
ben.matrixNewbie
Posts: 3523 · Reputation: 35
#2Apr 10, 2017, 06:08 AM
+1, I feel ya on the jargon part.
ben.matrixNewbie
Posts: 3523 · Reputation: 35
#3Apr 10, 2017, 08:22 AM
This sounds like a solid project. Just get into the BIPs related to mining, they usually have good pointers.
ben.matrixNewbie
Posts: 3523 · Reputation: 35
#4Apr 10, 2017, 12:26 PM
You should check out existing mining software too. They often have readable code for these operations.
ben.matrixNewbie
Posts: 3523 · Reputation: 35
#5Apr 10, 2017, 12:40 PM
pруфы? What specifically are you stuck on?
ben.matrixNewbie
Posts: 3523 · Reputation: 35
#6Apr 10, 2017, 02:00 PM
Kinda makes sense to me. Once you get the hang of it, the hashing isn't the hard part.
ben.matrixNewbie
Posts: 3523 · Reputation: 35
#7Apr 10, 2017, 07:22 PM
In my experience, just getting the data format right is key. I've been there.
ben.matrixNewbie
Posts: 3523 · Reputation: 35
#8Apr 10, 2017, 11:03 PM
Good luck man, hope you find what you need!
Related topics
- Mining Testnet Bitcoins Without ASIC 19
- Issues with ripemd160 on Ubuntu 22 9
- New Bitcoin Improvement Proposal with $100 Reward 9
- Clipboard Vulnerabilities in Cryptocurrency Transactions 8
- Understanding the Differences Between Traditional and Simplified Chinese Mnemonics 6
- Running Bitcoin Core on a Laptop with Limited Storage 20