Not only has Decker from the Komodo team added equihash as a mining algorithm for the Yiimp mining pool software, he fixed a bug about coin switching preferences. Where a user had opted for mining 3 coins – the specific order ignored any custom requests made after mining had started. Decker’s version fixes this. For example, if a miner wanted to mine KMD, RICK & MORTY and wanted to switch to mining RICK, Decker’s version of Yiimp will honour this request. The original Yiimp code will ignore the request and send KMD jobs to process.#equihash #mining pool with #coin switching has been made available by @KomodoPlatform #blockchain developers Click To Tweet
To quote the man: Also, it contains few fixes for coin change (mean `-c=COIN` in password field) that original Yiimp stratum implementation haven’t. Mean, original Yiimp stratum code with big probability gives miner other work, than expected. For example pool have 3 coins on algo equihash, like KMD, RICK, MORTY … user wants to mine MORTY and put `-c=MORTY` in password field. But with 99% probablity pool will give him work from the first coin on that algo, so, user want to mine MORTY, but instead of that receives KMD jobs. This behaviour is fixed in my version.
The work took approximately 60 hours in marathon 20 hour sessions. The hardest part was understanding other people’s code. Hardest part was to understand code written by others (mean in Yiimp Stratum and in ccminer), sometimes it was 100% not clear. All of these LE to BE conversions … partially from ASCII strings, partially from binary representation … but anyway, seems I did it.
The source code is available from Decker’s yiimp github repo. Another community developer and contributor is phm87, who discussed some of the changes Decker made. Phm87 has his own patches to the yiimp codebase.
The two mining pool experts discussed the changes further with Decker giving us this info:
My implementation have two non-documented options, see the line: https://github.com/DeckerSU/yiimp-stratum-equihash/blob/f9e5c48d8e018f4873683883224bfaffad8f50d8/client_submit.cpp#L218
1. With `templ->nbits` stratum will send block to daemon when `share_hash <= net_target` , where net target is calculated from `nbits` received in `getblocktemplate`.
2. With `templ->nbits_from_target` stratum will send block to daemon when `share_hash <= net_target` also, but `net_target` here will be exactly match `target` from `getblocktemplate` .