Newbie here, and wanting to get neck deep into Homebrewing, but not a CPU... - Page 1
Forum section: electronics / beginners

author: AGRGale
author_rank: Newbie
timestamp: October 19, 2015, 03:45:34 am
content: Hello people,I've had an interest in the hardware side of Bitcoin, manly the ASICs they use, what I wanted to do is attempt to get some discrete logic and slap together my own bitcoin core calculation.The problem is, I really don't understand the logic of bitcoin calculation, so I can't just attempt to layout a boolean logic map.Since you can calculate it by hand (pencil and paperlinky link)and there is a Spreadsheet calculation for SHA256 (Sha256 on Spreadsheet in google docs.) which I can just follow.Now I have posted this in the Beginner section since, well, I'm new at these forums and this concept, I'm not new at soldering, or even playing with SMDs and a hot air iron. and I'm happy to spend the time soldering 100s of 1000s discrete components on some proto board, but can I get a hand though this please?

author: tec5c
author_rank: Frequent Contributor
timestamp: October 19, 2015, 03:57:38 am
content: Quote from: AGRGale on October 19, 2015, 03:45:34 amGood, because this is exactly what you'll be doing!Just to clarify, are you asking for help with the logic layout? The wording of the quote I inserted kind of makes it seem like you're after help to solder everything together.

author: matseng
author_rank: Frequent Contributor
timestamp: October 19, 2015, 04:25:03 am
content: If the data athttps://bitcointalk.org/index.php?topic=1029536.0is correct he will be doing a metric shittonof soldering I think....QuoteSo if using 8-bit wide ICs there would be (768+640+896)*4=9216 ICs in total. And my guess is that my cellphone can calculate the hashes faster than this discrete implementation

author: AGRGale
author_rank: Newbie
timestamp: October 19, 2015, 05:11:10 am
content: Quote from: tec5c on October 19, 2015, 03:57:38 amYeah, bad wording, yeah, I meant getting things laid out, not the soldering.Quote from: matseng on October 19, 2015, 04:25:03 amjust over 9000 eh? I'm going to sit and read this post you linked for a bit, work out how that person came to that conclusion.. but yes, a cellphone could outperform a truck load of ICs wired together, but its not speed I'm after, its the curve-ball learning experience, and a large device that could outlast ww3Quote from: evb149 on October 19, 2015, 03:54:02 amYeah, I could do that, but it would negate the metric shit-ton of soldering I may want to do

author: rs20
author_rank: Super Contributor
timestamp: October 19, 2015, 05:20:43 am
content: Hey, whatever floats your boat, as long as you understand that a bitcoin miner built out of discrete gates won't outperform an average smartphone. I'd personally prefer to build a CPU or a clock or something; something that's actually nominally useful.

author: AGRGale
author_rank: Newbie
timestamp: October 19, 2015, 05:31:46 am
content: Quote from: rs20 on October 19, 2015, 05:20:43 amwell i could do a 4000 transistor 4004 clone, then get it calculating sha256d

author: Dago
author_rank: Frequent Contributor
timestamp: October 19, 2015, 05:52:03 am
content: I don't think calculating bitcoin hashes with discrete logic would be any more stupid than making a CPU, it's just something fun and interesting to do. I doubt the idea is to outperform anythingMy suggestion is that this would be a very good opportunity to learn FPGAs which is kinda the same thing as making the thing out of discrete logic. You'll get to learn a new valuable/useful skill instead of soldering 9000 logic chips.

author: tec5c
author_rank: Frequent Contributor
timestamp: October 19, 2015, 06:22:41 am
content: I get the impression that the OP is aware of the excessive amount of work involved in his project, thus it seems like he is wanting to do it purely for the sake of doing it and learning a few things along the way. Which, if so, is highly admirable.

author: Ian.M
author_rank: Super Contributor
timestamp: October 19, 2015, 08:11:12 am
content: Its a great idea, - if you are about to start a 10 year posting at an Antarctic weather station, have $10000 to blow on chips and boards and nothing better to do.

author: matseng
author_rank: Frequent Contributor
timestamp: October 19, 2015, 08:29:09 am
content: Yea, it's not really an experience with a lot of learning-something potential - except that it is very boring to make 200 000 solder joints. Hm, that's not too bad. Soldering for 10 hours per day it will be done in a month :-)It will basically be same-same-same sets of boards 128 times over and a lot of interconnects. So this is something more suited for a PnP machine or a trained monkey.

author: matseng
author_rank: Frequent Contributor
timestamp: October 19, 2015, 08:46:16 am
content: [replying to myself is bad manners but I don't care :-) ]But to be a bit more on the constructive side I just wanted to say that maybe there are better things to build if you want to spend a lot of time and money.An arcade game from the seventies comes to mind. Many of them was made without any microcontrollers, just pure logic. That is a challenge to tackle and would (at least in my mind) give a lot more cred than a copy-paste-repeat*128 design as a sha256 would be.

author: tggzzz
author_rank: Super Contributor
timestamp: October 19, 2015, 09:42:12 am
content: Quote from: AGRGale on October 19, 2015, 05:11:10 amI think the scale of this is too large for a first project; I doubt you would ever get it working correctly.I suggest you find a smaller project, one that can be done with maybe a dozen ICs, and take that to completion. You will learn a lot about decoupling, layout, controlled impedance, speed of light, schematic tools, layout tools - especially if you take the time and effort to examine all the non-idealities of what you've created.

author: crispy_tofu
author_rank: Super Contributor
timestamp: October 19, 2015, 10:06:32 am
content: If you're doing this, I think it'll be a huge undertaking (too huge?) for you. Most people (like me) would probably lose interest after the first 20 000 solder joints!

author: AGRGale
author_rank: Newbie
timestamp: October 19, 2015, 11:54:16 am
content: Quote from: crispy_tofu on October 19, 2015, 10:06:32 amthis could happen, but if i lay out a plan on a whiteboard at my workbench, few hundred post-it notes, i should be able to hold on. Also to note, i have found it relaxing soldering 100s of LEDs to proto boards, so i might find making ALUs entertaining..Quote from: tggzzz on October 19, 2015, 09:42:12 amWell, i may need to start at the communications side of it, so, serial to parallel would be a start

author: amyk
author_rank: Super Contributor
timestamp: October 20, 2015, 03:57:08 am
content: Quote from: matseng on October 19, 2015, 04:25:03 amThat is only if you do all the rounds in essentially combinatorial logic. Since the OP's goal is not to make the fastest implementation, perhaps he should attempt to make thesmallest(in terms of gate count)? I think using bit-serial operations, and registers to keep the intermediate results, would make it rather small.

author: fivefish
author_rank: Frequent Contributor
timestamp: October 20, 2015, 05:07:20 am
content: QuoteHow are you going to deal with all the propagation delays?

author: AGRGale
author_rank: Newbie
timestamp: October 20, 2015, 05:25:21 am
content: Quote from: amyk on October 20, 2015, 03:57:08 amwell since the sha256 calculation is done in 64 rounds, I could store that 4-bytes of data each operation, using only 1 hashing logic unit.so basically, one hashing unit consist of:6 x 32-bit adders5 x 32-bit ORs and7 x 32-bit XORs

author: amyk
author_rank: Super Contributor
timestamp: October 20, 2015, 08:15:11 am
content: You could compress that down into a few gates if you use bit-serial addition/logical operations along with a lot of shift registers...

author: tggzzz
author_rank: Super Contributor
timestamp: October 20, 2015, 10:51:47 am
content: Quote from: amyk on October 20, 2015, 08:15:11 amNice to see the old techniques for making commercial computers haven't been forgotten

author: Kalvin
author_rank: Super Contributor
timestamp: October 20, 2015, 12:52:59 pm
content: Just buy truck load of resistors, 1N4148s and2N3904s, and make your own "FPGA".

author: SeanB
author_rank: Super Contributor
timestamp: October 20, 2015, 07:02:35 pm
content: Quote from: tggzzz on October 20, 2015, 10:51:47 amGoing to be a little difficult getting the MK4007 serial memories for it though. Went obsolete in the 1970's, and i have not seen much data on it online either, most are the regular 4007 CMOS chip.