Pages:
Author

Topic: Arduino Miner? (Read 31550 times)

legendary
Activity: 1624
Merit: 1130
Bitcoin FTW!
August 07, 2016, 09:24:31 AM
#27
I have designed a portable raspberry pi zero computer.
The raspberry pi is already in use for folding.
Now i want a low powerd computer a arduino for mining bitcoins or other currency doesnt really matter.
I know i never get my money back but it is more for the fun.
Now is my quastion is there already somen one who had done it on a arduino?

Sorry for my bad english hope you understand.

AFAIK no, and especially not for anything besides SHA256, let alone folding or even Scrypt. I don't see many people working on something like this in the future, either, as the hashrate will probably be so low that you'll never get any shares. The CPU in most arduino units are pretty obsolete, even compared with many smartphones. I'd just recommend that you buy some more pis to mine with, as it'll take at least a few months for anything to get started with this, if at all anything happens.
newbie
Activity: 1
Merit: 0
August 04, 2016, 05:06:07 AM
#26
I have designed a portable raspberry pi zero computer.
The raspberry pi is already in use for folding.
Now i want a low powerd computer a arduino for mining bitcoins or other currency doesnt really matter.
I know i never get my money back but it is more for the fun.
Now is my quastion is there already somen one who had done it on a arduino?

Sorry for my bad english hope you understand.
alh
legendary
Activity: 1846
Merit: 1052
May 20, 2016, 11:46:23 AM
#25
While this might be an interesting or fun project, it's clearly in the "Can I make it work" category, kinda like that guy that implemented the SHA256 algorithm on a late 1950's IBM system (i.e. the 1401 CPU). It's important to understand the realities of such an effort.

For a moment, let's assume you could make a single Arduino do 1 MILLION hashes in a second. Sounds like a lot doesn't it? To put it in perspective though, the $25 Compac USB stick from sidehack does 8 BILLION hashes in one second. So to match the Compac hashrate you'll need 8 THOUSAND Arduino gadgets.

Just something to consider.
legendary
Activity: 1456
Merit: 1000
May 19, 2016, 06:03:06 PM
#24
is there any update on this ?

Arduino's were just not made for running mining software.  You can program them... but the project is not something like running a full linux OS.   You just will find it's made for other things.

What you need is a RPI for 30 dollars or so.  And it works fine as it was made as a mini computer. 
sr. member
Activity: 504
Merit: 250
InvestnTrade. Latest from the crypto space.
May 19, 2016, 02:29:34 AM
#23
This is interesting but mining needs a lot of processing power. I don't think Arduino can run the mining software. Most CPUs are working at GHz clockspeeds and Arduinos are not. There were RPis made for it but still they are weak.
newbie
Activity: 2
Merit: 0
May 18, 2016, 08:29:01 PM
#22
is there any update on this ?
legendary
Activity: 1442
Merit: 1005
May 30, 2011, 01:31:09 PM
#21
Some of the LPCs can be had for 60 cents for 1K chip count. That's a 75MHz ARM core instead of a 20MHz AVR core... So a much lower cost per core, a much higher performance per core. I'm a fan of AVRs, but still, there's such a thing as trying too hard -- which is why I laugh at everyone still trying to do "real work" on their CP/M system.

--Keith
Let us read from the Big Book of things and witness it's power....
- ARM Cortex-M3 processor, running at frequencies of up to 120 MHz on high speed versions (LPC1769 and LPC1759), up to 100 MHz on other versions, around 100 MIPS?
- Price around 7.5$ for large quantities for most package forms
- no power usage details, possibly less than100mW at 2-5V?
- requires board components for development/implementation worth around 10-20$?



So it looks like 100Khash/s for 10$/core using 300mW. Maybe you can buy them cheaper.
member
Activity: 112
Merit: 10
May 30, 2011, 11:59:46 AM
#20
Some of the LPCs can be had for 60 cents for 1K chip count. That's a 75MHz ARM core instead of a 20MHz AVR core... So a much lower cost per core, a much higher performance per core. I'm a fan of AVRs, but still, there's such a thing as trying too hard -- which is why I laugh at everyone still trying to do "real work" on their CP/M system.

--Keith
legendary
Activity: 1442
Merit: 1005
May 30, 2011, 11:41:47 AM
#19
All the arguments about profitability aside, how would one actually go about implementing it in a sensible way?  what's the compatibility list?  How much memory do we actually need to calculate the hash, and how do we send/receive it efficiently?

All these questions are good ones to answer in an arduino implementation, and could have efficiency consequences for custom boards/IC's afterward.

Looking at the numbers, I don't think anyone is going to find out anytime soon Cheesy

The fact that the hardware breakeven is longer than the duration of life for the device, and that while interesting to get a C/lua/python/ASM implementation running in single-core or multi-core configurations, the lessons would provide too little for benefits on other platforms. My suggestion is to start with the public code in public repositories on all the miners published so far and attempt to rewrite parts of them for the arduino.

Might as well start directly on those other platforms. I'm going to watch for an android implementation now, surely that's more accessible and powerful than any arduino implementation might go.
legendary
Activity: 1386
Merit: 1004
May 30, 2011, 11:06:25 AM
#18
The arduino advantage is once you have a working prototype, it costs around 2.5$ per core to build your implementation, very little costs for the surrounding parts, and can be implemented with low-tech tools like a soldering iron, some PCBs and etching solution. The proposed alternatives require more development work, more expensive parts and assemblies.

What does a 5870 cost per core?  1600 cores/$320 (for easy calc) so maybe 5 cents a core?
full member
Activity: 294
Merit: 100
May 30, 2011, 08:03:15 AM
#17
All the arguments about profitability aside, how would one actually go about implementing it in a sensible way?  what's the compatibility list?  How much memory do we actually need to calculate the hash, and how do we send/receive it efficiently?

All these questions are good ones to answer in an arduino implementation, and could have efficiency consequences for custom boards/IC's afterward.
AVR has a GNU toolchain so you'd just need to split the code above, do the hashing on an AVR that doesn't need much RAM and pass it back to a PC say over a serial port. For the reasons above anything using an AVR would be a waste of time for a custom board, and a custom IC would be an ASIC. Apart from being very expensive starting with an AVR isn't even vaguely how you'd go about starting an ASIC design. There's a thread here about an open source FPGA design which would be more likely a starting point for an ASIC:

http://forum.bitcoin.org/index.php?topic=9047.0

But for an ASIC you'd want to count on dropping over $100K even if you were an expert in the area.
newbie
Activity: 12
Merit: 0
May 30, 2011, 07:43:01 AM
#16
All the arguments about profitability aside, how would one actually go about implementing it in a sensible way?  what's the compatibility list?  How much memory do we actually need to calculate the hash, and how do we send/receive it efficiently?

All these questions are good ones to answer in an arduino implementation, and could have efficiency consequences for custom boards/IC's afterward.
full member
Activity: 294
Merit: 100
May 30, 2011, 07:12:04 AM
#15
So I stand corrected, each core requires 55mAV (or 83mAV overclocked).
Sounds about right, so if my "extremely optimistic" 10khash/s at the higher clock rate was realised it would be 8.3W per mhash/s. To match a 5970 at 700mhash/s you'd need 70,000 chips and 5810W. Must reiterate I think it's a cool project, just once anyone does it you're probably better to offer your newly developed skills in exchange for BTC rather than using it to mine with Grin.
legendary
Activity: 1442
Merit: 1005
May 30, 2011, 06:58:25 AM
#14
Sure arduino is slow as hell, but it's virtually free to use in terms of electricity 0.7mAV per core? Or say you build a 100 cores board (250$), that would draw 70mW?
I use AVRs a lot but have never used an Arduino as such. But for example first one I just found was a nano using an ATmega168, you need 4.5V to get 20MHz and the datasheet lists 12mA @5V for 8MHz. It would be higher than that for 20MHz but even if it wasn't that would still be 4.5 x 12mA (current would be a little lower at 4.5V at 8MHz) = 54mW per chip. The lower currents you see in sales blurbs are normally running at 32KHz and/or using the various standy modes. The relationship to clock rate is normally "somewhat" linear, so I'd expect under 100mW a chip at 20MHz, maybe more like 70mW like you said but for each chip not 100.
I read the "active" figure for the [email protected], and extrapolated to 5V. Don't know how to compensate for speed. So let's look at the document again

http://www.atmel.com/dyn/resources/prod_documents/doc2545.pdf

page 304 - Active 8Mhz@12mA (5V)
page 315 - Active supply current vs. frequency (1MHz - 24MHz) chart, it seems that 24Mhz, 5.5V needs 15mA. The number we were looking for was that 20Mhz 5V needed 11mA.
page 319 - Idle supply current vs. frequency (1MHz - 24MHz) chart, it seems that 24Mhz, 5.5V needs 4mA.

So I stand corrected, each core requires 55mAV (or 83mAV overclocked).
full member
Activity: 294
Merit: 100
May 30, 2011, 06:27:19 AM
#13
Sure arduino is slow as hell, but it's virtually free to use in terms of electricity 0.7mAV per core? Or say you build a 100 cores board (250$), that would draw 70mW?
I use AVRs a lot but have never used an Arduino as such. But for example first one I just found was a nano using an ATmega168, you need 4.5V to get 20MHz and the datasheet lists 12mA @5V for 8MHz. It would be higher than that for 20MHz but even if it wasn't that would still be 4.5 x 12mA (current would be a little lower at 4.5V at 8MHz) = 54mW per chip. The lower currents you see in sales blurbs are normally running at 32KHz and/or using the various standy modes. The relationship to clock rate is normally "somewhat" linear, so I'd expect under 100mW a chip at 20MHz, maybe more like 70mW like you said but for each chip not 100.
legendary
Activity: 1442
Merit: 1005
May 30, 2011, 06:11:26 AM
#12
The arduino advantage is once you have a working prototype, it costs around 2.5$ per core to build your implementation, very little costs for the surrounding parts, and can be implemented with low-tech tools like a soldering iron, some PCBs and etching solution. The proposed alternatives require more development work, more expensive parts and assemblies.
newbie
Activity: 12
Merit: 0
May 30, 2011, 05:37:10 AM
#11
I think it would be both interesting and useful to have a working codebase and example that could be used with microcontrollers.  This project's aim isn't to produce something with a superior efficiency to current solutions, but if somebody does want to try going down that path it would be nice to have a codebase and/or ideas to work from. 

I think something that could use one or more arduino's to do the calculations in an efficient manner would be a net positive for other projects as well.
full member
Activity: 294
Merit: 100
May 30, 2011, 05:07:39 AM
#10
Could someone do the math in terms of Mhash/s for them? (would it be something like 20Khash/s for a single one which needs 20 years for hardware breakeven?)
Looking at the hash code above there's close to 1000 opcodes, and it's not entirely unrolled, if it was that would be 20k SHA hashes. That would be 10khash/s in Bitcoin terms (2 SHA per hash) but briefly looking I'd expect < 1khash/s. I can't be bothered but the free AVR Studio package has a simulator you could run it through to see the instruction cycles taken.

If you were seriously contemplating it a small ARM is less than a dollar more expensive, and I'd expect would be about 8 times faster because most of the calcs are 32 bit and they run over double the clock rate. The CPU mining comparison suggests 110khash for a 528MHz ARM 11 so I suspect a low-cost ARM (50MHz odd) would only come in around 10khash. Compared to say the 5970 I use that would need about 7000 of them at $2 a pop to compete. Also to compete on power it would need to use about 4mA a chip, even most AVRs you more than that at full tilt.

I think the OP had the right idea to just treat it as an interesting little project Wink

Edit - just realised above is out by an order of magintude, making it even worse.
newbie
Activity: 1
Merit: 0
May 30, 2011, 05:01:07 AM
#9
I'd recommend that this is not done using Arduinos - it'd be more power efficient, and better MH/$ to use PIC32MX microcontrollers.
(Although it can be damn hard to get a toolchain set up on Linux because they only released the source for what they have to release... Sad)

Assuming it takes 1984 cycles to do a single SHA256(which it should), you'd get (80MHz/(1984*2)) = (80 * 100 000 000) / 3968 = 2 016 129.03 hashes per second. (I bet I've screwed something up there, somehow Smiley)
Of course, I've only included the time for the two hashes. (which is wrong, because you can optimise away part of the last hash, if my beliefs are correct, anyway?), and none of the checking/control stuff. Smiley
In this case, I still think you'd only get ~50MH/s for $200. Sad
(THIS IS NOT AT BULK PRICING THOUGH! If you were to buy say, a thousand of them, you might find it to be very different Smiley)


And that's at a maximum cost of 8$ + support components. (decoupling capacitors, PCBs, etc)(quite probably less, I can't be bothered to check Cheesy)

An Arduino would take more clock cycles to do it, I don't know how many, because it's not 32Bit. And it runs more slowly too, so it's unlikely to get you as much money in return.
legendary
Activity: 1442
Merit: 1005
May 30, 2011, 04:27:34 AM
#8
The Arduino microprocessors are really weak so you'll probably not get much out of them in terms of Hash/s. What might work is wiring up some custom SHA256 IC's and using the Arduino to farm work to them - of course with the PC doing the comms.

Indeed, they are weak, but let's not forget once you have the right chip and board schematics, you can put them in a small "farm".



As you can see above, after prototyping, the actual implementation surface could be as little as 2cm^2 per core. Also consider running a parallel algorithm on them, such that they use all cores on a board for a single hash, instead of each core doing it's own complete hashing. An USB chip and an USB connection and a PC are needed to actually validate the hashes and collect the results. It's sunny outside, plug them into a PV cell and when the sun shines you get free bitcoins straight from the source...

Could someone do the math in terms of Mhash/s for them? (would it be something like 20Khash/s for a single one which needs 20 years for hardware breakeven?)

From the specs:
- Up to 20 MIPS throughput at 20MHz
- Operating voltage: ATmega48/88/168: 0 - 10MHz @ 2.7V - 5.5V, 0 - 20MHz @ 4.5V - 5.5V
- Power consumption: 250μA at 1MHz, 1.8V
- Price per 1000 units: < 2.5$


How 1000 of them look like:
Pages:
Jump to: