Bitcoin Forum
May 28, 2024, 05:14:26 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: JavaScript LTC Miner - Proof of Concept  (Read 2219 times)
esenminer (OP)
Full Member
***
Offline Offline

Activity: 126
Merit: 100


View Profile
May 26, 2013, 10:18:50 PM
 #1

I've been interested for a while in getting Javascript to do scrypt hashing after I noticed pooler's JMiner for Java here https://github.com/pooler/JMiner.

I spent a little bit of time and ported over most the code adjusting it for Javascript and for the replacement libraries it requires. After a bit I managed to get it hashing!

The source code can be found here:

https://github.com/esenminer/js_ltc_miner/

Just copy all the files into a web accessible directory and open up the index.html file. Click on start and it will start hashing a harcoded share. My older computer with and AMD X2 from 2009 managed a whopping 40 hashes a second on chrome! I'm sure there is a lot that could be done to optimize the code and get it running faster but I wanted to just put it out there for others.
 
Comments / criticisms and hash rates are of course welcome but please take it easy it was only meant as a proof of concept Smiley Please post if you have issues getting it to run.

Obvious applications are having the script run in the background of web pages. However before you attempt to do this it is unlikely to work with this code. This can already hash and submit real data but at those hashing rates it would take so long to find a share that by the time you found one it would have gone stale. Now I am not advocating this but with this low hash rate the only way that idea MIGHT ever work is if you had hundreds or thousands of computers running the script at the same time all working on the same share with different nonces. For example a 10000 computers running at 40 hashes second could effectively be hashing around 390 kh/s if done right just to give you an idea of the scale you would need - That might be interesting but it would be much more sophisticated than the code here.

If you found this useful please feel free to donate some LTC:
LRt1KkirdbiBf3vPQR3tEQZQrVxPAA9Bb4
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!