Bitcoin Forum
April 24, 2024, 06:48:50 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 ... 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 [128] 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 ... 385 »
  Print  
Author Topic: Nexus - Pure SHA3 + CPU/GPU + nPoS + 15 Active Innovations + More to Come  (Read 785444 times)
Videlicet
Legendary
*
Offline Offline

Activity: 868
Merit: 1058


Creator of Nexus http://nexus.io


View Profile WWW
March 19, 2015, 06:08:25 AM
 #2541

It's not a fixed threshold, it is relative to other payouts. Highest balance always gets highest priority on payout, which means if it takes longer, there are miners getting higher payouts from larger amounts of mining power.

Thank You,
Viz.

[Nexus] Created by Viz. [Videlicet] : "videre licet - it may be seen; evidently; clearly"
1713941330
Hero Member
*
Offline Offline

Posts: 1713941330

View Profile Personal Message (Offline)

Ignore
1713941330
Reply with quote  #2

1713941330
Report to moderator
Every time a block is mined, a certain amount of BTC (called the subsidy) is created out of thin air and given to the miner. The subsidy halves every four years and will reach 0 in about 130 years.
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
cestballot
Sr. Member
****
Offline Offline

Activity: 318
Merit: 250


Nexus pool : http://nexusniropool.cestballot.fr/


View Profile WWW
March 19, 2015, 10:30:06 AM
Last edit: March 19, 2015, 11:10:04 AM by cestballot
 #2542

CSD pool sources :
https://github.com/VidereLicet/PrimeBetaPool
https://github.com/VidereLicet

We have 3 cpu pool now :
https://bitcointalk.org/index.php?topic=657601.0#post_Pools
Viz Beta CPU Pool: 204.27.62.234:9549  2% fee -min diff 4.5
Cestballot CPU pool faster then beta pool / more uptime: 92.222.190.111 or pool.cestballot.fr  2% fee -min diff 3.8
Nonce-pool CPU pool : http://csd-cpu.nonce-pool.com multiworkers options, 2% fee ?? min diff ??

http://coinshieldpool.cestballot.fr/ use last CSD Viz source code.
Here you can see actual CPU usage for min diff set at 4.0 with only 4 core use (16 core ready)
5843 block found Smiley


If you need more help or information, you can easily contact us here, or http://coinshieldtalk.org or https://kiwiirc.com/client/irc.freenode.net/coinshield/ or http://coinshieldpool.cestballot.fr/ at https://twitter.com/cestballot

Best regards

Cest Ballot

qwep1
Hero Member
*****
Offline Offline

Activity: 610
Merit: 500


View Profile
March 19, 2015, 10:36:23 AM
 #2543

what about GPU pool  Roll Eyes

              ▄▄██▄▄
          ▄▄██████████▄▄
      ▄▄██████████████████▄▄
  ▄▄██████████▀▀ ▀▀██████████▄▄
▄█████████▀▀          ▀▀█████████▄
██████▀▀        ▄▄        ▀▀██████
██████      ▄▄██████▄▄      ██████
██████    ██████████████    ██████
██████    ██████████████    ██████
██████    ██████████████    ██████
██████      ▀▀██████▀▀      ██████
██████          ▀▀        ▄▄██████
▀█████    ▄▄          ▄▄█████████▀
   ▀▀█    ████▄▄ ▄▄██████████▀▀
          ████████████████▀▀
          ▀▀██████████▀▀
              ▀▀██▀▀
P H O R E

     █
    █
   █
  █
   █
    █
   █
  █
 █
    KryptKoin rebranded to Phore   
     █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █ █
PoS 3.0  -  Masternodes  -  Obfuscation


     █
    █
   █
  █
   █
    █
   █
  █
 █
.


            ▄▄██▄▄
        ▄▄██████████▄▄
    ▄▄████████▀▀████████▄▄
 ▄████████▀▀      ▀▀████████▄
▐█████▀▀              ▀▀█████▌
▐████       ▄▄██▄▄       ████▌
▐████    ▄██████████▄    ████▌
▐████    ████████████    ████▌
▐████    ▀██████████▀    ████▌
▐████       ▀▀██▀▀       ████▌
 ▀███                 ▄▄█████▌
    ▀    █▄▄      ▄▄████████▀
         █████▄▄████████▀▀
         ▀██████████▀▀
            ▀▀██▀▀
AliMan
Hero Member
*****
Offline Offline

Activity: 1988
Merit: 502


Vave.com - Crypto Casino


View Profile
March 19, 2015, 11:25:46 AM
 #2544

Yea I don't think we really needed another cpu pool :p

MeGaDoOm
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250


View Profile
March 19, 2015, 11:46:03 AM
 #2545

It's not a fixed threshold, it is relative to other payouts. Highest balance always gets highest priority on payout, which means if it takes longer, there are miners getting higher payouts from larger amounts of mining power.

Thank You,
Viz.

Wouldn't it be more fair to first do balance payouts (for instance) older than 24h, then do payouts for the highest balances/fast miners.
That way small miners see something happen too !

My miner currently displays: Balance: 20.447240 CSD | Payout: 0.000000 CSD

    ▄▄
  ▐████▌
  ██████
  ▐████▌
    ▀▀
█▄  ▐▌  ▄█
██  ▐▌  ██
██  ██  ██
██  ██  ██
██▄ ██ ▄██
 ▀▀████▀▀
   ▐██▌
    ██
    ██
    ██
    ██
    ██
   ▐██▌
   ▐██▌
   ▐██▌
   ████
   ████
 
|
                         ▄▄
                    ▄▄██████
               ▄▄███████████
          ▄▄████████████████
     ▄▄█████████████████████
  ██████████████████████████

██████████████████████████████████▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
██████████████████████▀▀
█████████████████████ ▄▄███████████
████████████████████ ▐█▀  ▀████████
████████████████████ ▐█▄  ▄████████
█████████████████████ ▀▀███████████
██████████████████████▄▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
▀█████████████████████████████████▀

 
|
 
     ▄▄▀▀▀▀▀▀▀▀▀▀▀▀▄▄
    █                █
    █  █  ▄▄▄▄▄▄▄▄▄  █
    █                █
    █ ▄████████████▄
    █ ██████████████
    █ ██████████████
    █ ▀████████████▀
    █                █
    █ ▄▀▀▀▀▄  ▄▀▀▀▀▄ █
    █ █    █  █    █ █
    █  ▀▀▀▀    ▀▀▀▀  █
    █                █
     █              █
      █            █
       █          █
        █        █
         ▀▄▄▄▄▄▄▀
           ▀██▀
            ▐▌
▀▀▀▀▀▀▀▀▀▀▀▀▀
macorcina
Sr. Member
****
Offline Offline

Activity: 466
Merit: 250


View Profile
March 19, 2015, 04:23:38 PM
 #2546

It's not a fixed threshold, it is relative to other payouts. Highest balance always gets highest priority on payout, which means if it takes longer, there are miners getting higher payouts from larger amounts of mining power.

Thank You,
Viz.

Wouldn't it be more fair to first do balance payouts (for instance) older than 24h, then do payouts for the highest balances/fast miners.
That way small miners see something happen too !

My miner currently displays: Balance: 20.447240 CSD | Payout: 0.000000 CSD
if biggest miner / balances take payout first, then they can dump, and smal miner only watch they small balances on pool ?
cestballot
Sr. Member
****
Offline Offline

Activity: 318
Merit: 250


Nexus pool : http://nexusniropool.cestballot.fr/


View Profile WWW
March 19, 2015, 04:57:40 PM
Last edit: March 19, 2015, 05:11:01 PM by cestballot
 #2547

It's not a fixed threshold, it is relative to other payouts. Highest balance always gets highest priority on payout, which means if it takes longer, there are miners getting higher payouts from larger amounts of mining power.

Thank You,
Viz.

Wouldn't it be more fair to first do balance payouts (for instance) older than 24h, then do payouts for the highest balances/fast miners.
That way small miners see something happen too !

My miner currently displays: Balance: 20.447240 CSD | Payout: 0.000000 CSD
if biggest miner / balances take payout first, then they can dump, and smal miner only watch they small balances on pool ?

no, you receive payout, biggest and smallest miner, your balance is you csd.

Pool core :
Code:
#include "LLP/pool.h"
#include "LLP/server.h"
#include "LLP/daemon.h"
#include "LLP/webui.h"
#include "LLD/record.h"

#include "core.h"
#include "base58.h"
#include <algorithm>

namespace Core
{

/** Coinbase Transaction for this Block. **/
Coinbase cGlobalCoinbase;
std::string POOL_VERSION = "1.0.0";


/** Wallet Connection Variables. **/
std::map<std::string, double> ROUND_SHARES;
std::map<std::string, uint64> ACCOUNT_BALANCE;

std::vector<LLP::DaemonHandle*> DAEMON_CONNECTIONS;
LLP::Server<LLP::PoolConnection>* SERVER;
LLP::Server<LLP::UiConnection>* WEBSERVER;

LLP::Thread_t MASTER;


/** Mutex for Thread Synchronization [std::map is not thread safe]. **/
boost::mutex              PRIMES_MUTEX;


/** Map to hold the Prime Clusters Found. **/
std::map<uint1024, double> PRIMES_MAP;


/** Global Height to flag Pool Threads there is a new Block. **/
unsigned int nBestHeight = 0;


/** The Rewards for the Current Round. **/
uint64 nRoundReward = 0;


unsigned int nDifficultyShares[] = {0, 0, 0, 0, 0};


/** Flag to track the new round and when it is setup by the Master Thread. **/
bool fCoinbasePending = false, fNewRound = false, fSubmittingBlock = false;


/** Hash of the Block being Submitted. **/
uint1024 hashBlockSubmission(0);


/** The current Round for the Pool. **/
unsigned int nCurrentRound = 1;

uint64 nMinimumShare = 45000000;

/** The Database Handles. **/
LLD::Database<uint1024, LLD::Block> BlockDB("blk.dat");
LLD::Database<std::string, LLD::Account> AccountDB("acct.dat");

/** DDOS map by Address. **/
std::map<std::string, LLP::DDOS_Filter*> DDOS_BY_ADDRESS;


/** The Address for the Last Round. **/
std::string LAST_ROUND_BLOCKFINDER = "2S4PPSznWfPVLtPJNpi8Ly46Wft3wGbayGkhaGzKLVcepmrhKTP";


/** Used to Sort the Database Account Keys by Balance. **/
bool BalanceSort(const std::string& firstElem, const std::string& secondElem) { return Core::AccountDB.GetRecord(firstElem).nAccountBalance > Core::AccountDB.GetRecord(secondElem).nAccountBalance; }


/** Return List of Accounts Sorted by Balance [Highest Balance First]. **/
std::vector<std::string> GetSortedAccounts()
{
std::vector<std::string> vAccounts = AccountDB.GetKeys();
std:sort(vAccounts.begin(), vAccounts.end(), BalanceSort);

return vAccounts;
}


/** Entry Function to Start the Daemon Threads and Pool Server. **/
void StartPool(int nMaxDaemons, int nPoolThreads, bool fDDOS, int rScore, int cScore, int nMinShare)
{
printf("\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\n\nCoinshield LLP Prime Pool %s Initializing...\n", POOL_VERSION.c_str());
printf("[MASTER] Starting Pool with %u Daemon Handles, %u Pool Threads %f Min Share %s | rScore = %u cScore = %u\n", nMaxDaemons, nPoolThreads, nMinShare / 10000000.0, fDDOS ? "With DDOS Protection" : "", rScore, cScore);

nMinimumShare = nMinShare;

InitializePrimes();
Sleep(1000);

printf("[MASTER] Initializing Databases.\n");

std::vector<std::string> vAccounts = GetSortedAccounts();
for( int nIndex = 0; nIndex < vAccounts.size(); nIndex++)
{
CoinshieldAddress cAddress(vAccounts[nIndex]);
if(!cAddress.IsValid())
{
printf("[DATABASE] Erasing Invalid Record: %s\n", vAccounts[nIndex].c_str());
AccountDB.EraseRecord(vAccounts[nIndex].c_str());
}
else
AccountDB.GetRecord(vAccounts[nIndex]).Print();
//printf("%s:%f\n", vAccounts[nIndex].c_str(), AccountDB.GetRecord(vAccounts[nIndex]).nAccountBalance / 1000000.0);
}
AccountDB.WriteToDisk();


std::vector<uint1024> vBlocks = BlockDB.GetKeys();
for( int nIndex = 0; nIndex < vBlocks.size(); nIndex++)
{
LLD::Block cBlock = BlockDB.GetRecord(vBlocks[nIndex]);
if(cBlock.nRound > nCurrentRound)
nCurrentRound = cBlock.nRound;
}

LLP::Thread_t MASTER(MasterThread);
LLP::Thread_t ORPHAN(OrphanThread);
for(int nIndex = 0; nIndex < nMaxDaemons; nIndex++)
DAEMON_CONNECTIONS.push_back(new LLP::DaemonHandle(nIndex, "127.0.0.1", "9325"));

Sleep(1000);
SERVER    = new LLP::Server<LLP::PoolConnection>(9549, nPoolThreads, fDDOS, cScore, rScore, 60);
//WEBSERVER = new LLP::Server<LLP::UiConnection>  (9555, 5, false, 0, 0, 10);
}


/** Clear the Shares for the Current Round. **/
void ClearShares()
{
std::vector<std::string> vKeys = AccountDB.GetKeys();
for(int nIndex = 0; nIndex < vKeys.size(); nIndex++)
{
LLD::Account cAccount = AccountDB.GetRecord(vKeys[nIndex]);
cAccount.nRoundShares = 0;
AccountDB.UpdateRecord(cAccount);
}
}


/** Get the Total Weight of Shares from the Current Round. **/
uint64 TotalWeight()
{
uint64 nWeight = 0;

std::vector<std::string> vKeys = AccountDB.GetKeys();
for(int nIndex = 0; nIndex < vKeys.size(); nIndex++)
nWeight += AccountDB.GetRecord(vKeys[nIndex]).nRoundShares;

return nWeight;
}


/** Refund the Payouts if the Block was Orphaned. **/
void RefundPayouts(uint1024 hashBlock)
{
/** Get a Record from the Database. **/
LLD::Block cBlock = BlockDB.GetRecord(hashBlock);


/** Set the Flag that Block is an Orphan. **/
cBlock.nRound = 0;


printf("\n---------------------------------------------------\n\n");


/** Clear out the Credits for the Round. **/
for(std::map<std::string, uint64>::iterator nIterator = cBlock.cCredits.mapCredits.begin(); nIterator != cBlock.cCredits.mapCredits.end(); nIterator++)
{
LLD::Account cAccount = AccountDB.GetRecord(nIterator->first);
if(nIterator->second > cAccount.nAccountBalance)
cAccount.nAccountBalance = 0;
else
cAccount.nAccountBalance -= nIterator->second;

printf("[MASTER] Account %s Removed %f Credits\n", nIterator->first.c_str(), nIterator->second / 1000000.0);
AccountDB.UpdateRecord(cAccount);
}


/** Refund the Payouts for the Round. **/
for(std::map<std::string, uint64>::iterator nIterator = cBlock.cCoinbase.mapOutputs.begin(); nIterator != cBlock.cCoinbase.mapOutputs.end(); nIterator++)
{
LLD::Account cAccount = AccountDB.GetRecord(nIterator->first);
cAccount.nAccountBalance += nIterator->second;

printf("[MASTER] Account %s Refunded %f CSD\n", nIterator->first.c_str(), nIterator->second / 1000000.0);
AccountDB.UpdateRecord(cAccount);
}

printf("\n---------------------------------------------------\n\n");


/** Update the Record into the Database. **/
BlockDB.UpdateRecord(cBlock);
BlockDB.WriteToDisk();
}


/** Update the Account Balances from Weights in Current Round. **/
void UpdateBalances(uint64 nReward)
{
printf("\n---------------------------------------------------\n\n");


/** Create a New Block Record to Track Payouts. **/
LLD::Block cBlock(hashBlockSubmission);
cBlock.cCoinbase = cGlobalCoinbase;
cBlock.nCoinbaseValue = cGlobalCoinbase.nMaxValue + cGlobalCoinbase.nPoolFee;
cBlock.nRound = nCurrentRound;


/** Make Sure Miners Aren't Credited the Pool Fee [2% for Now]. **/
nReward -= (nReward * 0.02);


/** The 2% Block Finder Bonus from Previous Round. **/
if(LAST_ROUND_BLOCKFINDER != "")
{
uint64 nCredit = (nReward * 0.02);
LLD::Account cAccount = AccountDB.GetRecord(LAST_ROUND_BLOCKFINDER);
cAccount.nAccountBalance += nCredit;
AccountDB.UpdateRecord(cAccount);

cBlock.cCredits.AddCredit(LAST_ROUND_BLOCKFINDER, nCredit);
nReward -= nCredit;
}


/** Calculate the Total Weight of the Last Round. **/
uint64 nTotalWeight = TotalWeight();
uint64 nTotalReward = 0;


/** Update the Accounts in the Database Handle. **/
std::vector<std::string> vKeys = AccountDB.GetKeys();
for(int nIndex = 0; nIndex < vKeys.size(); nIndex++)
{
LLD::Account cAccount = AccountDB.GetRecord(vKeys[nIndex]);

/** Update the Account Balance After Payout was Successful. **/
if(cGlobalCoinbase.mapOutputs.count(vKeys[nIndex]))
{
if(cGlobalCoinbase.mapOutputs[vKeys[nIndex]] > cAccount.nAccountBalance)
cAccount.nAccountBalance = 0;
else
cAccount.nAccountBalance -= cGlobalCoinbase.mapOutputs[vKeys[nIndex]];

AccountDB.UpdateRecord(cAccount);
}


/** Don't Credit Account if there are no Shares for this Round. **/
if(cAccount.nRoundShares == 0)
continue;


/** Credit the Account from its Weight. **/
unsigned int nCredit = (((double)cAccount.nRoundShares / nTotalWeight) * nReward);
cAccount.nAccountBalance += nCredit;
nTotalReward += nCredit;


/** Update the New Credits in the Block Database. **/
cBlock.cCredits.AddCredit(vKeys[nIndex], nCredit);


/** Commit the New Account Record to Database. **/
AccountDB.UpdateRecord(cAccount);


printf("[ACCOUNT] Account: %s | Credit: %f CSD | Balance: %f CSD\n", cAccount.cKey.c_str(), nCredit / 1000000.0, cAccount.nAccountBalance / 1000000.0);
}

/** Any Remainder of the Rewards give to Blockfinder. **/
if(nReward > nTotalReward)
{
LLD::Account cAccount = AccountDB.GetRecord(LAST_ROUND_BLOCKFINDER);
cAccount.nAccountBalance += (nReward - nTotalReward);
AccountDB.UpdateRecord(cAccount);

printf("[ACCOUNT] Block Finder Bonus to %s of %f CSD\n", LAST_ROUND_BLOCKFINDER.c_str(), (nReward - nTotalReward) / 1000000.0 );
}

/** Commit the New Block Record to the Block Database. **/
BlockDB.UpdateRecord(cBlock);
BlockDB.WriteToDisk();
cBlock.cCredits.Print();

/** Commit the Account Changes to Database. **/
AccountDB.WriteToDisk();


printf("[ACCOUNT] Balances Updated. Total Round Weight = %f | Total Round Reward: %f CSD\n", nTotalWeight / 1000000.0, nReward / 1000000.0);
printf("\n---------------------------------------------------\n\n");
}


/** Reset the Daemon Threads **/
void ResetDaemons()
{
for(int index = 0; index < DAEMON_CONNECTIONS.size(); index++)
DAEMON_CONNECTIONS[index]->fNewBlock = true;
}


/** Declare a new Round for the Pool. **/
void NewRound()
{
fNewRound = true;
fCoinbasePending = true;

LLP::Timer TIMER;
TIMER.Start();

UpdateBalances(nRoundReward);
ClearShares();
nCurrentRound++;

{ LOCK(PRIMES_MUTEX);
 PRIMES_MAP.clear();
}

fNewRound = false;

printf("[MASTER] New Round, Reset Handlers in %u ms\n", TIMER.ElapsedMilliseconds());
}


/** Determine the thread with the least amount of active connections.
This keeps the load balanced across all server threads. **/
LLP::DaemonHandle* FindDaemon()
{
int nIndex = 0, nConnections = DAEMON_CONNECTIONS[0]->nTotalConnections;
for(int index = 1; index < DAEMON_CONNECTIONS.size(); index++)
{
if(DAEMON_CONNECTIONS[index]->nTotalConnections < nConnections)
{
nIndex = index;
nConnections = DAEMON_CONNECTIONS[index]->nTotalConnections;
}
}

return DAEMON_CONNECTIONS[nIndex];
}

/** Thread to Determine what Block and Rewards the Coinshield Network is on. **/
void OrphanThread()
{
printf("[MASTER] Initialized Orphan Thread\n");
LLP::Timer TIMER;
TIMER.Start();

LLP::DaemonConnection* CLIENT = new LLP::DaemonConnection("127.0.0.1", "9325");
loop
{
Sleep(1);

/** Attempt with best efforts to keep the Connection Alive. **/
if(!CLIENT->Connected() || CLIENT->Errors() || CLIENT->Timeout(30))
{
Sleep(1000);

TIMER.Reset();
if(!CLIENT->Connect())
continue;

fSubmittingBlock = false;
fNewRound = false;

}

/** Read a Packet until it is Complete. **/
CLIENT->ReadPacket();
if(CLIENT->PacketComplete())
{
LLP::Packet PACKET = CLIENT->NewPacket();
CLIENT->ResetPacket();

if(PACKET.HEADER == CLIENT->ORPHAN_BLOCK)
{
uint1024 hashOrphan;
hashOrphan.SetBytes(PACKET.DATA);

printf("[MASTER] Block %s - Round %u Has Been Orphaned\n", hashOrphan.ToString().substr(0, 20).c_str(), BlockDB.GetRecord(hashOrphan).nRound);
Core::RefundPayouts(hashOrphan);

fCoinbasePending = true;
}

else if(PACKET.HEADER == CLIENT->GOOD_BLOCK)
{
uint1024 hashBlock;
hashBlock.SetBytes(PACKET.DATA);

printf("[MASTER] Block %s - Round: %u Is in Main Chain\n", hashBlock.ToString().substr(0, 20).c_str(), BlockDB.GetRecord(hashBlock).nRound);
}

}

/** Don't make any new requests until Master Thread is Set. **/
if(fNewRound || fSubmittingBlock || fCoinbasePending)
continue;

/** Check last 5 blocks every 20 seconds. **/
if(TIMER.ElapsedMilliseconds() > 20000)
{
std::vector<uint1024> vKeys = BlockDB.GetKeys();
for(int nIndex = 0; nIndex < vKeys.size(); nIndex++)
if(BlockDB.GetRecord(vKeys[nIndex]).nRound >= nCurrentRound)
CLIENT->CheckBlock(vKeys[nIndex]);

TIMER.Reset();
}
}
}

/** Thread to Determine what Block and Rewards the Coinshield Network is on. **/
void MasterThread()
{
printf("[MASTER] Initialized Master Thread\n");
LLP::Timer TIMER;
TIMER.Start();

LLP::Timer METER_TIMER;
METER_TIMER.Start();


LLP::DaemonConnection* CLIENT = new LLP::DaemonConnection("127.0.0.1", "9325");
loop
{
Sleep(1);

/** Let thread idle while account balances are updated. **/
if(fNewRound || fSubmittingBlock)
continue;

/** Attempt with best efforts to keep the Connection Alive. **/
if(!CLIENT->Connected() || CLIENT->Errors() || CLIENT->Timeout(30))
{
Sleep(1000);

if(!CLIENT->Connect())
continue;

CLIENT->SetChannel(1);

CLIENT->GetHeight();
CLIENT->GetRound();

TIMER.Reset();
METER_TIMER.Reset();

fNewRound = false;
fSubmittingBlock = false;
fCoinbasePending = true;

printf("[MASTER] Connect to Daemon Server...\n");
}


if(METER_TIMER.ElapsedMilliseconds() > 10000)
{

printf("[METERS] 4 ch: x %f | 5 ch: x %f | 6 ch: x %f | 7 ch: x %f\n", (double)nDifficultyShares[0] / nDifficultyShares[1],
(double)nDifficultyShares[1] / nDifficultyShares[2], (double)nDifficultyShares[2] / nDifficultyShares[3], (double)nDifficultyShares[3] / nDifficultyShares[4]);

METER_TIMER.Reset();
}


if(TIMER.ElapsedMilliseconds() > 2000)
{
CLIENT->GetHeight();
CLIENT->GetRound();

if(fCoinbasePending)
{
//printf("[MASTER] Getting Reward.\n");
CLIENT->GetReward();
}

//printf("[MASTER] Checking Round.\n");

TIMER.Reset();
}


/** Read a Packet until it is Complete. **/
CLIENT->ReadPacket();
if(!CLIENT->PacketComplete())
continue;


/** Handle the New Packet, and Interpret its Data. **/
LLP::Packet PACKET = CLIENT->NewPacket();
CLIENT->ResetPacket();

if(fCoinbasePending)
printf("[MASTER} There is a New Packet...\n");

/** Update the Global Round Height if there is a new Block. **/
if(PACKET.HEADER == CLIENT->BLOCK_HEIGHT)
{
unsigned int nHeight = bytes2uint(PACKET.DATA);
//printf("[MASTER] Height Received %u\n", nHeight);

if(nHeight > nBestHeight)
{
printf("[MASTER] Coinshield Network: New Block [Height] %u\n", nHeight);
fCoinbasePending = true;

}

nBestHeight = nHeight;
}


/** Response from Mining LLP that there is a new block. **/
else if(PACKET.HEADER == CLIENT->NEW_ROUND)
{
printf("[MASTER] Coinshield Network: New Block [Round] %u\n", nBestHeight);
fCoinbasePending = true;
}

/** After the Coinbase Transaction is Set on Master Thread, Check the Blocks for Orphans. **/
else if(PACKET.HEADER == CLIENT->COINBASE_SET)
{
printf("[MASTER] Coinbase Transaction Set on Master\n");
fCoinbasePending = false;
ResetDaemons();


/** Commit Shares to Database on New Block. **/
AccountDB.WriteToDisk();
}

/** If the Coinbase Tx Fails to Update, get data again and attempt to rebuild it. **/
else if(PACKET.HEADER == CLIENT->COINBASE_FAIL)
{
printf("[MASTER] ERROR: Coinbase Transaction Not Set. Retrying...\n");

fCoinbasePending = true;
}

/** Update the Current Round Rewards. **/
else if(PACKET.HEADER == CLIENT->BLOCK_REWARD)
{
nRoundReward = bytes2uint64(PACKET.DATA);
printf("[MASTER] Received Reward of %f\n", nRoundReward / 1000000.0);

if(nCurrentRound > 1 && fCoinbasePending)
{

cGlobalCoinbase.nPoolFee = (nRoundReward * 0.02);
cGlobalCoinbase.Reset(nRoundReward - cGlobalCoinbase.nPoolFee);


std::vector<std::string> vAccounts = GetSortedAccounts();
for(int nIndex = 0; nIndex < vAccounts.size(); nIndex++)
{
/** Read the Account Record from the Database. **/
LLD::Account cAccount = AccountDB.GetRecord(vAccounts[nIndex]);

/** Only add a Payout if Above the 0 CSD Threshold. **/
if(cAccount.nAccountBalance > 0)
{
int nValue = cGlobalCoinbase.AddTransaction(vAccounts[nIndex], cAccount.nAccountBalance);
if(nValue < 0)
{
cGlobalCoinbase.AddTransaction(vAccounts[nIndex], cAccount.nAccountBalance + nValue);

break;
}
}
}

/** Add CSD Block Finder Bonus [On top of Larger Weight] on Rounds where Coinbase is Incomplete. **/
if(!cGlobalCoinbase.IsComplete())
{
int nBonus = cGlobalCoinbase.GetRemainder();
cGlobalCoinbase.AddTransaction(LAST_ROUND_BLOCKFINDER, nBonus);
}

cGlobalCoinbase.Print();
CLIENT->SetCoinbase();
}
else
fCoinbasePending = false;

printf("[DAEMON] Round %u Block %u Rewards %f CSD\n", nCurrentRound, nBestHeight, nRoundReward / 1000000.0);
}
}
}
}

What modification you need ? Smiley

Best regards

Cest Ballot

macorcina
Sr. Member
****
Offline Offline

Activity: 466
Merit: 250


View Profile
March 19, 2015, 05:40:11 PM
Last edit: March 19, 2015, 06:21:39 PM by macorcina
 #2548

/** Return List of Accounts Sorted by Balance [Highest Balance First]. **/
   std::vector<std::string> GetSortedAccounts()
all coins have problem with distribution with small and big miners.
maybe smaller balance first four payout ?
that will give fast result for small miners if they see csd in wallet after few hour, and
could be stimulation for more people to mine
also that will prevent big miner to dump large amount of coins before small miner get coins
cestballot
Sr. Member
****
Offline Offline

Activity: 318
Merit: 250


Nexus pool : http://nexusniropool.cestballot.fr/


View Profile WWW
March 19, 2015, 10:03:19 PM
Last edit: March 19, 2015, 10:39:58 PM by cestballot
 #2549

/** Return List of Accounts Sorted by Balance [Highest Balance First]. **/
   std::vector<std::string> GetSortedAccounts()
all coins have problem with distribution with small and big miners.
maybe smaller balance first four payout ?
that will give fast result for small miners if they see csd in wallet after few hour, and
could be stimulation for more people to mine
also that will prevent big miner to dump large amount of coins before small miner get coins

Payout first Highest balance, where is the probleme ?

Exemple payout for i5-2410M (2 core intel) :


we have to wait 1.0.3 to have better block creation, if we make little payout like 0.01 csd this can create long and big block hard to create when you send CSD like 1000+.

Example : if i mined 1000 csd during XXX day with little payout like 0.01 csd and I need to send this coin to a friend the new block I create is 0.1+0.1+0.1+ [...]+0.1 = 1000 it can stuck you wallet for big wait time Smiley

So, wait 1.0.3 and let see how Viz prepare for you Smiley

Best regards

Cest Ballot

ps : I'm not in CSD dev team, I'm just big supporter  Cool


MeGaDoOm
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250


View Profile
March 19, 2015, 11:08:47 PM
 #2550

The explanation about the payout system looks okay. Although I still wonder what happens when the number of GPU miners increases.

Perhaps the 'balance/payment'-problem lies in understanding what the miner reports on-screen.
Payout is almost always 0 csd, while balance is like 20 csd or so.
My expectation is a 'single transaction' of the 20 csd to my wallet. My Wallet does receive 0.1, 1 or 2 csd every hour or so.
-->     Perhaps an extra counter like 'Sent to wallet: x csd' would be nice,     <--
because just Balance y and payout 0.0 may give the impression that payments are stuck.

    ▄▄
  ▐████▌
  ██████
  ▐████▌
    ▀▀
█▄  ▐▌  ▄█
██  ▐▌  ██
██  ██  ██
██  ██  ██
██▄ ██ ▄██
 ▀▀████▀▀
   ▐██▌
    ██
    ██
    ██
    ██
    ██
   ▐██▌
   ▐██▌
   ▐██▌
   ████
   ████
 
|
                         ▄▄
                    ▄▄██████
               ▄▄███████████
          ▄▄████████████████
     ▄▄█████████████████████
  ██████████████████████████

██████████████████████████████████▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
██████████████████████▀▀
█████████████████████ ▄▄███████████
████████████████████ ▐█▀  ▀████████
████████████████████ ▐█▄  ▄████████
█████████████████████ ▀▀███████████
██████████████████████▄▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
▀█████████████████████████████████▀

 
|
 
     ▄▄▀▀▀▀▀▀▀▀▀▀▀▀▄▄
    █                █
    █  █  ▄▄▄▄▄▄▄▄▄  █
    █                █
    █ ▄████████████▄
    █ ██████████████
    █ ██████████████
    █ ▀████████████▀
    █                █
    █ ▄▀▀▀▀▄  ▄▀▀▀▀▄ █
    █ █    █  █    █ █
    █  ▀▀▀▀    ▀▀▀▀  █
    █                █
     █              █
      █            █
       █          █
        █        █
         ▀▄▄▄▄▄▄▀
           ▀██▀
            ▐▌
▀▀▀▀▀▀▀▀▀▀▀▀▀
cestballot
Sr. Member
****
Offline Offline

Activity: 318
Merit: 250


Nexus pool : http://nexusniropool.cestballot.fr/


View Profile WWW
March 20, 2015, 12:01:02 AM
 #2551

The explanation about the payout system looks okay. Although I still wonder what happens when the number of GPU miners increases.

Perhaps the 'balance/payment'-problem lies in understanding what the miner reports on-screen.
Payout is almost always 0 csd, while balance is like 20 csd or so.
My expectation is a 'single transaction' of the 20 csd to my wallet. My Wallet does receive 0.1, 1 or 2 csd every hour or so.
-->     Perhaps an extra counter like 'Sent to wallet: x csd' would be nice,     <--
because just Balance y and payout 0.0 may give the impression that payments are stuck.


We will add worker setting with payout set by users.
This probably come with GPU pool.  Wink

thx for your post, all this question help use to found new feature.

If you have any question about csd, csd pool and more, just ask use, we will give the best Smiley

Best regards

CestBallot

macorcina
Sr. Member
****
Offline Offline

Activity: 466
Merit: 250


View Profile
March 20, 2015, 12:33:30 AM
Last edit: March 20, 2015, 12:44:00 AM by macorcina
 #2552

 worker setting with payout set by users.
That will fix problems for small miners.
Nice.  Smiley
And  Coinshield database : http://www.cestballot.fr/downn/coinshield/blkindex20150318.zip
link missing form OP. 
COOLERbyPSP
Member
**
Offline Offline

Activity: 124
Merit: 10


View Profile
March 20, 2015, 01:04:09 AM
 #2553

http://joxi.ru/DBA0MJDCPnzjry.png
Useless
Quote from: db.log
file unknown has LSN 176/2282454, past end of log at 1/68429
Commonly caused by moving a database from one database environment
to another without clearing the database LSNs, or by removing all of
the log files from a database environment
__db_meta_setup: C:\Users\Лaypa\AppData\Roaming\Coinshield\blkindex.dat: unexpected file type or format
Database handles still open at environment close
Open database handle: addr.dat/main
Open database handle: time.dat/main
Undecided
cestballot
Sr. Member
****
Offline Offline

Activity: 318
Merit: 250


Nexus pool : http://nexusniropool.cestballot.fr/


View Profile WWW
March 20, 2015, 01:26:10 AM
Last edit: March 20, 2015, 12:52:41 PM by cestballot
 #2554

http://joxi.ru/DBA0MJDCPnzjry.png
Useless
Quote from: db.log
file unknown has LSN 176/2282454, past end of log at 1/68429
Commonly caused by moving a database from one database environment
to another without clearing the database LSNs, or by removing all of
the log files from a database environment
__db_meta_setup: C:\Users\Лaypa\AppData\Roaming\Coinshield\blkindex.dat: unexpected file type or format
Database handles still open at environment close
Open database handle: addr.dat/main
Open database handle: time.dat/main
Undecided

I tested this database save on new wallet using windows 7, windows 8.1 and 2012 R2

for exemple pool wallet was resync in just 5 minutes after database corruption. ( my bad Smiley )

Todo list :  

1/Start sync your wallet For testing I wait 25000 blocks sync first

2/close the wallet (you have to wait like 5 minutes to be sure wallet close properly)
3/ copy/paste file : blkindex.dat and blk0001.dat



4/ restart wallet and finish sync

Now you are ready.



Best regards

Cest Ballot

Edit : Pool min diff is now set at 3.9, I'll decrease tomorow at 3.8 if all works good.

MeGaDoOm
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250


View Profile
March 20, 2015, 03:05:42 AM
 #2555

Just curious,,
  why do you manually have to set the (min) difficulty ?

    ▄▄
  ▐████▌
  ██████
  ▐████▌
    ▀▀
█▄  ▐▌  ▄█
██  ▐▌  ██
██  ██  ██
██  ██  ██
██▄ ██ ▄██
 ▀▀████▀▀
   ▐██▌
    ██
    ██
    ██
    ██
    ██
   ▐██▌
   ▐██▌
   ▐██▌
   ████
   ████
 
|
                         ▄▄
                    ▄▄██████
               ▄▄███████████
          ▄▄████████████████
     ▄▄█████████████████████
  ██████████████████████████

██████████████████████████████████▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
██████████████████████▀▀
█████████████████████ ▄▄███████████
████████████████████ ▐█▀  ▀████████
████████████████████ ▐█▄  ▄████████
█████████████████████ ▀▀███████████
██████████████████████▄▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
▀█████████████████████████████████▀

 
|
 
     ▄▄▀▀▀▀▀▀▀▀▀▀▀▀▄▄
    █                █
    █  █  ▄▄▄▄▄▄▄▄▄  █
    █                █
    █ ▄████████████▄
    █ ██████████████
    █ ██████████████
    █ ▀████████████▀
    █                █
    █ ▄▀▀▀▀▄  ▄▀▀▀▀▄ █
    █ █    █  █    █ █
    █  ▀▀▀▀    ▀▀▀▀  █
    █                █
     █              █
      █            █
       █          █
        █        █
         ▀▄▄▄▄▄▄▀
           ▀██▀
            ▐▌
▀▀▀▀▀▀▀▀▀▀▀▀▀
cestballot
Sr. Member
****
Offline Offline

Activity: 318
Merit: 250


Nexus pool : http://nexusniropool.cestballot.fr/


View Profile WWW
March 20, 2015, 03:20:13 AM
 #2556

Just curious,,
  why do you manually have to set the (min) difficulty ?

auto diff is not dev yet  Roll Eyes

Namsbreh
Sr. Member
****
Offline Offline

Activity: 318
Merit: 250


View Profile
March 20, 2015, 09:10:09 AM
 #2557

Thanks for your work with the CPU pool Cestballot.  Providing a solution to the payouts for smaller miners is good and important.

No rush with the GPU pool....solo works fine......
MeGaDoOm
Sr. Member
****
Offline Offline

Activity: 308
Merit: 250


View Profile
March 20, 2015, 04:39:20 PM
 #2558

Just curious,,
  why do you manually have to set the (min) difficulty ?

auto diff is not dev yet  Roll Eyes

No Kimoto Gravity Well ?

    ▄▄
  ▐████▌
  ██████
  ▐████▌
    ▀▀
█▄  ▐▌  ▄█
██  ▐▌  ██
██  ██  ██
██  ██  ██
██▄ ██ ▄██
 ▀▀████▀▀
   ▐██▌
    ██
    ██
    ██
    ██
    ██
   ▐██▌
   ▐██▌
   ▐██▌
   ████
   ████
 
|
                         ▄▄
                    ▄▄██████
               ▄▄███████████
          ▄▄████████████████
     ▄▄█████████████████████
  ██████████████████████████

██████████████████████████████████▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
██████████████████████▀▀
█████████████████████ ▄▄███████████
████████████████████ ▐█▀  ▀████████
████████████████████ ▐█▄  ▄████████
█████████████████████ ▀▀███████████
██████████████████████▄▄
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
███████████████████████████████████
▀█████████████████████████████████▀

 
|
 
     ▄▄▀▀▀▀▀▀▀▀▀▀▀▀▄▄
    █                █
    █  █  ▄▄▄▄▄▄▄▄▄  █
    █                █
    █ ▄████████████▄
    █ ██████████████
    █ ██████████████
    █ ▀████████████▀
    █                █
    █ ▄▀▀▀▀▄  ▄▀▀▀▀▄ █
    █ █    █  █    █ █
    █  ▀▀▀▀    ▀▀▀▀  █
    █                █
     █              █
      █            █
       █          █
        █        █
         ▀▄▄▄▄▄▄▀
           ▀██▀
            ▐▌
▀▀▀▀▀▀▀▀▀▀▀▀▀
starblocks
Hero Member
*****
Offline Offline

Activity: 1344
Merit: 502



View Profile
March 20, 2015, 11:26:18 PM
Last edit: March 22, 2015, 07:04:30 AM by starblocks
 #2559

Hello Everyone, Viz. Here  Smiley

I am introducing this account for use in the Coin Shield Alerts System.
This will be driven by a collection of bots performing specific analysis to then feed alerts to BitcoinTalk.

These alerts will be Clone Alerts, Scam Alerts, Scam BCT Accounts, etc.
They will be developed for better informing of the public as to current Red Zones in the industry.

"Red Zones" defined is "Threads in which you will surely be scammed and lose most if not all of your money. These places will hold no way for profit unless you are adept in the game of alt coin scams"

Thank You,
Viz.

Interesting concept but is it the most objective way to go

Edit: To be more specific how does this account work work does it post in this thread or the scammers threads or?

Razerglass
Legendary
*
Offline Offline

Activity: 1036
Merit: 1000


https://bmy.guide


View Profile
March 21, 2015, 12:15:40 AM
 #2560

Just curious,,
  why do you manually have to set the (min) difficulty ?

auto diff is not dev yet  Roll Eyes

No Kimoto Gravity Well ?

kgw was the easiest to instamine. im glad Vid redid everything from scratch

██░                                             
 ▓██▓░                                           
  ▓█████▓▒░                                  ░▒██░
    ▓███████▓▒░                           ░▓▓██▓ 
      ▒█████████▓▒                     ░▓████▓   
        ░█████▓████▓▒                 ▓████▓░   
          ░▓███▓▓▓▓███▓░            ▒██▓▓█▒     
             ▓██▓▓▓▓▓▓██▒         ░███▓▓█▒       
               ▓█▓▓▓▓▓▓▓█▓       ▓███▓▓█▒       
                ▒██▓▓▓▓▓▓██▒   ▒███████▓         
                 ░██▓▓▓▓▓▓▓█▓░  ▒▓▓▓▓▓▓         
                   ▓█▓▓▓▓▓▓▓▓█▓▒                 
                    ▒█▓▓▓▓▓▓▓▓▓▓█▓▓▓▓▓▓▓▒▒░     
                      ▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▒   
                   ░▒▒▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓▓███   
              ▒▓▓█████▓▓▓▓▓▓▓▓▓████▓▓▓▓▒▒░   ░   
         ▒▓██████▓▓▓▓▓▓▓▓▒▒▒▒▒░                   
|
|
🛵 Connecting Travellers All Around The World 🛵 

Socially Powered Search Engine for the Travel & Tourism Industry
|

█████████████████████████
██ ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ██
██ ███████████▀     ██ ██
██ ██████████▌   ▄▄▄██ ██
██ ██████████   ██████ ██
██ ███████          ██ ██
██ ███████▄▄▄   ▄▄▄▄██ ██
██ ██████████   ██████ ██
██ ██████████   ██████ ██
██ ██████████   ██████ ██
██▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄██
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀

█████████████████████████
██ ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ██
██ █████████████▀█████ ██
██ ███ ▀█████▀      ▀█ ██
██ ███     ▀▀      ▐██ ██
██ ███▌            ███ ██
██ ████▌          ▄███ ██
██ ██████       ▄█████ ██
██ ████▄▄▄▄▄▄▄████████ ██
██ ███████████████████ ██
██▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄██
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀

█████████████████████████
██ ▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄ ██
██ ████████████▀▀▀████ ██
██ ████████▀▀     ████ ██
██ █████▀    ▄▀  ▐████ ██
██ ██▀     ▄▀    ▐████ ██
██ ████▄▄ █▀     █████ ██
██ ██████ ▄▄█   ▐█████ ██
██ ████████████ ██████ ██
██ ███████████████████ ██
██▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄██
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
|
Whitepaper
One-Pager
Ann Thread
|
Medium
Youtube
Instagram
Pages: « 1 ... 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 [128] 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 ... 385 »
  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!