Rapberry Pi 2 Antminer U2 CGMiner

Fix Formatting and figure out startup script.

  1. Setup a bitcoin wallet. You can find a list of available wallets at https://bitcoin.org/en/choose-your-wallet. I decided to https://www.coinbase.com to start.

  2. Sign up for a bitcoin pool. A comparison of mining pools can be found at https://en.bitcoin.it/wiki/Comparison_of_mining_pools. I found this a bit overwhelming so I decide to start with Slush's pool, (https://mining.bitcoin.cz), as a few tutorials were using it. This video contains some info on setting it up. https://www.youtube.com/watch?v=blDhGFTGuhU

  3. ssh into your raspberry pi

  4. Pull down any updates to any packages you have currently installed, $ sudo apt-get update

  5. Install the updates you just downloaded, $ sudo apt-get upgrade

  6. Install our depencies $ sudo apt-get install libusb-1.0-0-dev libusb-1.0-0 libcurl4-openssl-dev libncurses5-dev libudev-dev libtool automake pkg-config libjansson-dev tmux

  7. If not already there go to your home directory/ $ cd

  8. Clone cgminer from github. $ https://github.com/ckolivas/cgminer.git

  9. Go to the cgminer directory you just cloned. $ cd cgminer

  10. We first need to do some configuration before compiling cgminer. There seems to be a number of options to set. I wasn't 100% sure what needed to be set for using the U2, so I decided to keep following https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=103046 for this step.

$ sudo ./autogen.sh
$ export LIBCURL_CFLAGS=’-I/usr/include/curl’
$ ./configure --enable-icarus

Note: Running autogen and configure may take a bit to start after running the command, so be patient.

  1. Now it's time to compile. $ make.

  2. $ sudo make install

  3. Time for a snack break. You are now on your way to this. hacking gif or this frustration gif

  4. Time to start up our miner. Open a tmux session so we can detach without closing the program. $ tmux

  5. $ cd cgminer Changes working directory to cgminer directory. Assumes you are in your home directory. $ cd if you are unsure.

  6. Start up cgminger. This setup is for Antminer U2's your setup may differ. $ sudo ./cgminer --bmsc-options 115200:20 -o POOL -u USERNAME -p PASSWORD --bmsc-freq 0981

Since I am using slush's pool, I replaced "POOL" with stratum+tcp://stratum.bitcoin.cz:3333. Yours will be different if you are using a pool other than Slush. Some tutorials say you need to add your devices, but since I am running 2 U2's only, cgminer automatically detects and runs both. If I was running different miners, say a U2 and a U3 I would need to specify the correct device to apply the correct settings.

Reference:(Clean Me!) https://github.com/AntMiner/AntGen1/tree/master/cgminerhttp://bitcoinrigs.org/instructions/antminer-u1/http://denis-gobo.squarespace.com/denisgobo/2014/5/17/how-to-install-and-overclock-a-bitmain-antminer-u2-2ghs-usb-bitcoin-asic-miner-on-windows, [http://www.granthamm.com/bitcoin-mining-raspberry-pi-antminer-u1-fun/](http://www.granthamm.com/bitcoin-mining-raspberry-pi-a ntminer-u1-fun/), https://learn.adafruit.com/piminer-raspberry-pi-bitcoin-miner/install-cgminerhttps://www.youtube.com/watch?v=dPWTSytzN7g&index=2&list=PLPedo-T7QiNseMLPwm6xdknAAbZMGpQtBhttps://www.raspberrypi.org/forums/viewtopic.php?f=66&t=103046https://www.youtube.com/watch?v=blDhGFTGuhUhttps://bitcointalk.org/index.php?topic=259574.0https://bitcointalk.org/index.php?topic=585225.0,


  1. Deciphering the interface http://bitcoin.stackexchange.com/questions/19260/deciphering-cgminer-interface-in-terminal

AntMiner U3

  1. https://www.raspberrypi.org/forums/viewtopic.php?f=66&t=103046
  2. https://bitcointalk.org/index.php?topic=827356.840

Multidevice Resources

  1. http://askubuntu.com/questions/184526/how-to-get-bus-and-device-relationship-for-a-dev-ttyusb
  2. http://unix.stackexchange.com/questions/144029/command-to-determine-ports-of-a-device-like-dev-ttyusb0

Additional Info:

Bình luận

Vui lòng đăng nhập để gửi bình luận