I hacked together a perl script to show live stats. to use it, you need to install libjson-perl.
For Ubuntu people:
sudo apt-get install libjson-perl
I don't have windows, so if someone gets this running on windows please share what you needed to install.
#!/usr/bin/perl
use JSON;
$numsecs = 30; #seconds to refresh
$hashespersec = 400000; #Your mining speed
$input = `./yacoind getinfo`;
#print "Input:\n".$input."\n";
$json = JSON->new->allow_nonref;
$arrs = $json->decode($input);
$oldblocks = $arrs->{'blocks'};
sleep $numsecs;
while(1==1){
$input = `./yacoind getinfo`;
# print "Input:\n".$input."\n";
$json = JSON->new->allow_nonref;
$arrs = $json->decode($input);
# print "old: $oldblocks, new: ". $arrs->{'blocks'}."\n";
$secsperblock = ($numsecs/($arrs->{'blocks'}-$oldblocks));
print "Block: $secsperblock s ";
$hashesperblock = (2**32)*$arrs->{'difficulty'};
$blocks = $arrs->{'blocks'}-$oldblocks;
$speed = ($blocks*$hashesperblock)/$numsecs;
$time = $hashesperblock/400000;
$speed = $speed/$hashespersec;
printf "Netspeed: %.3f MH/s %.3f hrs/b\n",$speed,$time/3600;
$oldblocks = $arrs->{'blocks'};
sleep $numsecs;
}
usage:
kalgecin@laptop:~/yacoin/src$ perl ~/yacoin.pl
suggestions for improvement are being accepted. Criticism is also accepted
Donations:
Y7HPdphiDdH1Q7T2NJ4gxvNxP6XqPnVcNR