Bitcoin Forum
November 05, 2024, 04:33:42 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Structure of cryptocoin-source  (Read 532 times)
centurionMiner (OP)
Sr. Member
****
Offline Offline

Activity: 401
Merit: 251

Still learning


View Profile WWW
April 28, 2017, 11:11:08 AM
Merited by ABCbits (1)
 #1

I'm quite new to crypto, and i start studying/develop some tool to ease the trading/mining.

Can someone more expert than me tell us How a coin i structured?

I mean the "high-level" chart for designed/develop a coin and where that info are stored in the source.

Specifically:

1) Where is the difficulty retarget system?

3) Where are the "hot" info like : number of coin produced on time, algo, stake, ecc ecc

\-> http://steneumpool.ddns.net/stats <-/       \-> http://campuspool.ddns.ne/stats <-/      \-> http://godserver.ddns.net <-/       \-> https://electroneum-classic.ddns.net <-/
                          Steneum-Pool                                                        CampusCoin-Pool                    .                          MultiPool                 .                Electroneum-Classic [DEDICATED]
achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 3542
Merit: 6885


Just writing some code


View Profile WWW
April 28, 2017, 01:13:31 PM
Merited by ABCbits (2)
 #2

I'm quite new to crypto, and i start studying/develop some tool to ease the trading/mining.

Can someone more expert than me tell us How a coin i structured?

I mean the "high-level" chart for designed/develop a coin and where that info are stored in the source.
It depends on what version of the Bitcoin Core source that the coin you are working on forked from. The names of each file is fairly self explanatory and should be obvious as to what it does. The only not so obvious one is main.cpp. main.cpp contains all of the processing of network messages and validation of blocks and transactions. If they forked from Core 0.14.0+, main.cpp does not exist. Rather it has been split into validation.cpp and net_processing.cpp. You can probably guess what the stuff in those files do.

Specifically:

1) Where is the difficulty retarget system?
It is either located in main.cpp or pow.cpp, depending on the version of Bitcoin Core that the coin was forked from. The name of the function is CalculateNextWorkRequired.

3) Where are the "hot" info like : number of coin produced on time, algo, stake, ecc ecc
Those are the blockchain parameters, hence they would be located in the chainparams.cpp file.

centurionMiner (OP)
Sr. Member
****
Offline Offline

Activity: 401
Merit: 251

Still learning


View Profile WWW
April 28, 2017, 03:14:47 PM
 #3

Thank you master, all clear now Cool Cheesy
 If someone going to reply and add info about where the information about a coin are stored in the source, I update the post with the coin description and file link

\-> http://steneumpool.ddns.net/stats <-/       \-> http://campuspool.ddns.ne/stats <-/      \-> http://godserver.ddns.net <-/       \-> https://electroneum-classic.ddns.net <-/
                          Steneum-Pool                                                        CampusCoin-Pool                    .                          MultiPool                 .                Electroneum-Classic [DEDICATED]
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!