Bitcoin Forum
May 07, 2024, 05:46:12 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Help with bitcoin minimal mining software using libblkmaker  (Read 1145 times)
WiFau (OP)
Newbie
*
Offline Offline

Activity: 2
Merit: 0


View Profile
May 12, 2014, 07:57:38 PM
 #1

Hello guys,
I am involved in a project based on the Altera DE2-115 board.

The goal of the project is to learn soft core embedded systems design techniques, so we have decided to build a little bitcoin miner.
We don't care about performances, we know that it will be impossibile to reach good results with our platform. The only thing we are interested in is to show how to build a soft core system with a custom coprocessor and connected to the internet, so we have decided to make something about bitcoins which seems to fit perfectly this request.

The SHA256 coprocessor and the network interface are ready and linked to the soft core on which runs an embedded operating system provided with the NicheStack TCP/IP stack, now we have to deal with the Bitcoin protocol. We have decided to use libblkmaker but we could not understand the way we can use it. Watching the example.c file it does not show any network handshaking procedure with the mining pool server, it just show how the library processes the data, when received from the server, but it only sends and receive them from and to the stdin/stdout.

So the question is: where can we find informations about the "handshaking" with the mining pool server?
How does the connection is realized before sending the first JSON data package with the getblocktemplate method etc.?
Is there any technical guide to do it?

I am sorry, I have not been able to search the forum for such an information because the search engine kept refusing search telling me to wait 90 seconds even when many minutes have passed.
"Governments are good at cutting off the heads of a centrally controlled networks like Napster, but pure P2P networks like Gnutella and Tor seem to be holding their own." -- Satoshi
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction.
1715060772
Hero Member
*
Offline Offline

Posts: 1715060772

View Profile Personal Message (Offline)

Ignore
1715060772
Reply with quote  #2

1715060772
Report to moderator
1715060772
Hero Member
*
Offline Offline

Posts: 1715060772

View Profile Personal Message (Offline)

Ignore
1715060772
Reply with quote  #2

1715060772
Report to moderator
7queue
Full Member
***
Offline Offline

Activity: 177
Merit: 100


View Profile
May 12, 2014, 09:09:22 PM
 #2

https://bitcointalk.org/?topic=108854

https://en.bitcoin.it/wiki/Getblocktemplate
http://bitcoin.stackexchange.com/questions/13394/how-to-hash-data-from-getblocktemplate-request

8 )

8 )
WiFau (OP)
Newbie
*
Offline Offline

Activity: 2
Merit: 0


View Profile
May 13, 2014, 06:23:54 PM
Last edit: May 13, 2014, 08:18:52 PM by WiFau
 #3


Thank you, I had already read these links before asking my question.
I understand the process starting from the GBT request, as this question said http://bitcoin.stackexchange.com/a/13397.
The thing I can't understand is what to do BEFORE sending the GBT request. Is there any particular procedure to connect to the server?

For example, after subscribing to a mining pool from its website, what do I have to do to connect to its server?
I suppose I need to login in some way, giving my username or a password or something like that. Isn't it?
What kind of request should I send? An HTTP POST request? I can't find any way to understand this.

Please sorry me if I am asking silly questions.

EDIT: I have been noticed about the stratum protocol. Seems to be lightweight and this page seems to talk about everything I need.
Is there any C library for this? http://mining.bitcoin.cz/stratum-mining
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!