create account

Bitcoin Mining USB ASIC Hardware Cheatsheet by asabovesobelow

View this thread on: hive.blogpeakd.comecency.com
· @asabovesobelow · (edited)
$0.04
Bitcoin Mining USB ASIC Hardware Cheatsheet
Tips, tricks and fixes for some common USB ASIC Bitcoin mining hardware issues

Here are some random things learned after years of mining cryptos. These notes began before ASICs took over in 2013/14. So, much of this info is rather dated, but may still be useful to some.
Oftentimes it seems that an obscure, reproducible issue will occur - here's a list of some of those issues and their solutions, some hardware's identifying text / Bus Device String as reported to *lsusb*, and hopefully some useful tips for many common USB ASIC mining devices:

- Hardware
    - Controllers
        - Cubieboard tips: To build on a v1 cubie, use the following:CFLAGS="-O2 -Wall -march=armv7" ./configure <build-flags-here>
        - RasPi - until the Raspberry Pi3 came out in 2016, the main issue with RasPi as controller is the lack of USB3 support, thereby limiting the high-powered hubs many USB asicminers like to use.  To build bfgminer on titan controller: CFLAGS=“-O2 -Wall -March=armv6” ./configure --enable-scrypt --disable-sha256d --enable-titan --disable-other-drivers

    - USB ASIC Hardware: A primary issue with USB ASICs  is providing them with adequate power, due to the constraints of most USB hubs & power supplies, and of the USB spec itself
        - Bitmain U1 sticks [Bus Device string: **Cygnal Integrated Products, Inc. CP210x Composite Device**]
            - Use **--enable-icarus** build option for cgminer, or use BFGMiner
            - 1.6GHs to 2-3GHs with overclocking via software (active cooling is recommended)

        - USB Dualminer sticks [Bus Device string: **Future Technology Devices International, Ltd FT2232C Dual USB-UART/FIFO IC**]
            - [cgminer fork for USB Dualminer sticks](https://github.com/dualminer/dualminer-cgminer.git) 

        - Gridseed GC3355 USB combo miner (5-chip units with attached fan) [Bus Device string: **SGS Thomson Microelectronics**]
            - [cgminer fork for Gridseed 5 chip USB combo miners](https://github.com/dtbartle/cgminer-gc3355)

        - Rockminer RBox and New RBox miners [Bus Device string: **Cygnal Integrated Products, Inc. CP210x UART Bridge / myAVR mySmartUSB light**]
            - use **--enable-icarus** build option for cgminer

        - [Dragonminer scrypt USB](https://bitcointalk.org/index.php?topic=1140837.msg12922953#msg12922953) [Device String: **Cygnal Integrated Products, Inc. CP210x UART Bridge / myAVR mySmartUSB light**]

      `$ git clone https://wareck@bitbucket.org/wareck/cgminer-dragon.git`
      `$ cd cgminer-dragon`
      `$ sh autogen.sh`
      `$ ./configure --enable-scrypt --enable-zeus`
      `$ make`

           ./cgminer --scrypt -o pool_address -u user_or_ltc-address -p password --zeus-chips 1 --zeus-clo 
        - Drill-bit systems Thumbstick miners [Device String: **Atmel Corp.**]
            - If you have USB hubs that can only provide 500mA per port, or you are aiming for best performance per watt, use the default settings **--drillbit-options int:40:1:850** for around 400mA power consumption and a hash rate around 2.2GH/s.
            - If you can power 1000mA per Thumb and have only passive cooling, try **--drillbit-options ext:230:1:950** for around 2.7GH/s.
            - If you can power 1000mA per Thumb and have active cooling , try **--drillbit-options ext:250:1:950** for up to 3GH/s (not guaranteed.)
            - In either case, experiment with the clock speed (the second field in ext:_230_:1:950) in steps of 10MHz order to find the optimal hashing rate with the least Hardware Errors (HW). See the [Thumb performance and hashing tests](http://drillbitsystem.com/forum/index.php?PHPSESSID=0nfduncgk0vq04h5qbsscug4j1&topic=193.msg743#msg743) thread for more info.

        - Butterfly Labs (really?) [ Device String: **Future Technology Devices International, Ltd FT232H Single HS USB-UART/FIFO IC**]
        - GekkoScience Compac [Bus Device: **Cygnal Integrated Products, Inc. CP210x UART Bridge / myAVR mySmartUSB light**]  
            - [gekkoscience.com/misc/cgminer-gekko.tar.gz](http://gekkoscience.com/misc/cgminer-gekko.tar.gz)
            - autogen.sh --enable-gekko
            - use **--compac-freq NNN**

        - Avalon Nano [Bus Device string: **NXP Semiconductors**]
            - cgminer 4.9.1 compiled with **--enable-icarus**, and using the following runtime flags: **--icarus-options 115200:1:1 --icarus-timing 0.22** 

        - Bitmain U3 [Bus Device string: **Cygnal Integrated Products, Inc. CP210x UART Bridge / myAVR mySmartUSB light**]
            - [cgminer v4.9.0](https://github.com/ckolivas/cgminer/releases/tag/v4.9.0) built with **--enable-icarus** most stable, with options: **--au3-freq 237.5 --au3-volt 775**

- Software
    - Scripta OS - ssh port is at 7722, username root, pw scripta; startup script is at: /opt/minepeon/startup/miner-start.sh [mega download link](https://mega.co.nz/#!ZVkACTAD!aCRXr1W860jcic5bl12fbSRpHZwSX0WEgmu4PcuZlDE)  
startup script: _sudo /usr/bin/screen -dmS cgminer /opt/minepeon/bin/cgminer --scrypt --no-submit-stale --gridseed-options=baud=115200,freq=850 -c /opt/minepeon_
    - [Starminer](https://sourceforge.net/projects/starminer/):
        - Based on Raspbian; login: root pw: live

    - MinePeon:
        - To update **MinePeon**
            `$ cd /opt/minepeon/`
            `$ git pull`

        - To update **MinePeon** WebUI (use with caution):
            `$ cd /opt/minepeon/http/`
            `$ git pull`

        - To update the OS system packages:
            `$ sudo pacman -Syu`

        - Default startup:
`$ #!/bin/bash`
`$ sleep 10`
`$ /usr/bin/screen -dmS miner /opt/minepeon/bin/bfgminer -S all -c /opt/minepeon/etc/miner.conf`

        - steps to recreate RSA & DSA keys:
`$ sudo ssh-keygen -f /etc/ssh/ssh_host_dsa_key -N '' -t dsa`
`ssh-keygen`
`sudo systemctl start sshd`
`sudo systemctl start cgminer.service`
`sudo systemctl stop bfgminer.service`
`sudo systemctl disable bfgminer.service`
`sudo systemctl enable cgminer.service`

    - [Minera](https://bitcointalk.org/index.php?topic=596620.0):
        - Default login:  user:minera, pass:minera
        - Excellent GUI, and easy to add & configure custom miner software packages
        - GUI for updating system
        - To install on existing Raspian system:
        - on a brand new system, make sure locales are set:  `sudo apt-get install --reinstall locales`

According to [There is no public key available for the following key ID](http://www.linuxquestions.org/questions/debian-26/there-is-no-public-key-available-for-the-following-key-id-705108/), this will fix it:  

`sudo aptitude install debian-keyring debian-archive-keyring`
`dpkg-reconfigure tzdata  apt-get install libusb-1.0-0-dev`
`apt-get install pkg-config`
`sudo apt-get install -y redis-server git screen php5-cli php5-curl`
`cd /var/www`
`sudo git clone https://github.com/michelem09/minera`
`cd minera`
`sudo ./install_minera.sh`
        - To install required websever & php:
`sudo apt-get install -y lighttpd php5-cgi`
`sudo lighty-enable-mod fastcgi`
`sudo lighty-enable-mod fastcgi-php`
`sudo service lighttpd force-reload`
        - To install Berkeley DB 4.8:
`sudo apt-get install libdb4.8++-dev `

miniupnpc:

` wget http://miniupnp.tuxfamily.org/files/download.php?file=miniupnpc-1.6.tar.gz`
`tar -xzvf miniupnpc-1.6.tar.gz`
`cd miniupnpc-1.6`
`make`
`sudo su`
`make install`

##### scrypt (and x11 & other GPU) mining info:
> Install AMD Drivers
EACH NEW COMMAND STARTS WITH A $
`$ sudo apt-get install fglrx-updates fglrx-amdcccle-updates fglrx-updates-dev`
`$ sudo aticonfig --lsa`
`$ sudo aticonfig --adapter=all --initial`
`$ sudo reboot`
`$ sudo aticonfig --adapter=all --odgt`

>Install Curl and package updates
`$ sudo apt-get install curl`
`$ sudo apt-get update`
`$ sudo apt-get upgrade`

>Install cgminer 
`$ wget http://ck.kolivas.org/apps/cgminer/3.7/cgminer-3.7.2-x86_64-built.tar.bz2`
`$ tar jxvf cgminer-3.7.2-x86_64-built.tar.bz2`
`$ cd cgminer-3.7.2-x86_64-built`
`$ export DISPLAY=:0`
`$ export GPU_USE_SYNC_OBJECTS=1`
`$ ./cgminer -n`
The *./cgminer -n* command will list all the mining devices cgminer & the system can see

>Make a startup file and start Mining!
`$ sudo nano start.sh`
>Plug in this body of text replacing YOUR_XUBUNTU_USERNAME, USERNAME, and PASSWORD
> !/bin/sh
> export DISPLAY=:0
export GPU_MAX_ALLOC_PERCENT=100
export GPU_USE_SYNC_OBJECTS=1
cd /home/YOUR_XUBUNTU_USERNAME/cgminer-3.7.2-x86_64-built ./cgminer -scrypt -I 19 --thread-concurrency 21712 -o stratum+tcp://pool2.d2.cc:3335 -u USERNAME -p PASSWORD

Nicehash's [extranonce support fork for cgminer](https://github.com/nicehash/cgminer-ckolivas). To get the extranonce subscription to work, you may need to append "/#xnsub" to the pool's URL

Gridseed GC3355 USB combo miner (5-chip units with attached fan)
- [cgminer fork for Gridseed 5 chip USB combo miners](https://github.com/dtbartle/cgminer-gc3355)
cgminer --gridseed-options=baud=115200,freq=650,chips=5,modules=1,usefifo=0,btc=16

##### USB Power on RasPi/2
With the release of the raspberry Pi B+, a new config.txt setting was introduced, to allow for up to 1A of power at the USB port.
**max_usb_current=1** in your /boot/config.txt file

To fix the "**paymentrequestplus.h:8:31: fatal error: paymentrequest.pb.h: No such file or directory**" issue: 
`apt-get install libqt4-dev libprotobuf-dev protobuf-compiler`

To fix the "**Unable to find current revision in submodule path 'libblkmaker'**" error: Before running autogen.sh, execute: 
`git clone https://github.com/bitcoin/libblkmaker`
👍  , , , , , , , , ,
properties (23)
authorasabovesobelow
permlinkbitcoin-mining-usb-asic-hardware-cheatsheet
categorymining-bitcoin
json_metadata{"tags":["mining-bitcoin","bitcoin","mining","usb","miner"],"links":["https://github.com/dualminer/dualminer-cgminer.git","https://github.com/dtbartle/cgminer-gc3355","https://bitcointalk.org/index.php?topic=1140837.msg12922953#msg12922953","http://drillbitsystem.com/forum/index.php?PHPSESSID=0nfduncgk0vq04h5qbsscug4j1&topic=193.msg743#msg743","http://gekkoscience.com/misc/cgminer-gekko.tar.gz","https://github.com/ckolivas/cgminer/releases/tag/v4.9.0","https://mega.co.nz/#!ZVkACTAD!aCRXr1W860jcic5bl12fbSRpHZwSX0WEgmu4PcuZlDE","https://sourceforge.net/projects/starminer/","https://bitcointalk.org/index.php?topic=596620.0","http://www.linuxquestions.org/questions/debian-26/there-is-no-public-key-available-for-the-following-key-id-705108/","https://github.com/nicehash/cgminer-ckolivas"]}
created2016-06-07 16:52:24
last_update2016-06-07 16:54:27
depth0
children5
last_payout2016-08-14 04:41:51
cashout_time1969-12-31 23:59:59
total_payout_value0.018 HBD
curator_payout_value0.018 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length9,553
author_reputation1,278,117,927,133
root_title"Bitcoin Mining USB ASIC Hardware Cheatsheet"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id25,610
net_rshares112,426,418,765
author_curate_reward""
vote details (10)
@chirale ·
It is nice to see that someone may still use scripta for some good and healthy mining! tnx!
👍  
properties (23)
authorchirale
permlinkre-asabovesobelow-bitcoin-mining-usb-asic-hardware-cheatsheet-20170613t205038024z
categorymining-bitcoin
json_metadata{"tags":["mining-bitcoin"],"app":"steemit/0.1"}
created2017-06-13 20:50:39
last_update2017-06-13 20:50:39
depth1
children1
last_payout2017-06-20 20:50:39
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length91
author_reputation36,162,172,812
root_title"Bitcoin Mining USB ASIC Hardware Cheatsheet"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id4,765,278
net_rshares0
author_curate_reward""
vote details (1)
@asabovesobelow ·
the Baikal X11 miners all use Scripta, or is the Lateral Factory Scripta something different?  From a BaikalMiner webui's footer:
>[Scripta](http://http//www.lateralfactory.com/scripta/), by [Lateral Factory](http://www.lateralfactory.com/) under GPLv3 License
properties (22)
authorasabovesobelow
permlinkre-chirale-re-asabovesobelow-bitcoin-mining-usb-asic-hardware-cheatsheet-20170704t190911103z
categorymining-bitcoin
json_metadata{"tags":["mining-bitcoin"],"links":["http://http//www.lateralfactory.com/scripta/","http://www.lateralfactory.com/"],"app":"steemit/0.1"}
created2017-07-04 19:09:09
last_update2017-07-04 19:09:09
depth2
children0
last_payout2017-07-11 19:09:09
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length260
author_reputation1,278,117,927,133
root_title"Bitcoin Mining USB ASIC Hardware Cheatsheet"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id7,312,066
net_rshares0
@pfunk ·
Thanks I have some Gridseeds I got second hand that I've wanted to resurrect.
properties (22)
authorpfunk
permlinkre-asabovesobelow-bitcoin-mining-usb-asic-hardware-cheatsheet-20160607t192237349z
categorymining-bitcoin
json_metadata{"tags":["mining-bitcoin"]}
created2016-06-07 19:23:15
last_update2016-06-07 19:23:15
depth1
children0
last_payout2016-08-14 04:41:51
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length77
author_reputation221,632,045,904,452
root_title"Bitcoin Mining USB ASIC Hardware Cheatsheet"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id25,681
net_rshares0
@tinfoilfedora ·
It takes a lot of tinkering to come up with a cheetsheet like that! Thanks for posting it. 
Do you know if gridseeds or any of the others will mine steem?
properties (22)
authortinfoilfedora
permlinkre-asabovesobelow-bitcoin-mining-usb-asic-hardware-cheatsheet-20160607t172038900z
categorymining-bitcoin
json_metadata{"tags":["mining-bitcoin"]}
created2016-06-07 17:20:42
last_update2016-06-07 17:20:42
depth1
children1
last_payout2016-08-14 04:41:51
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length154
author_reputation20,279,768,518,195
root_title"Bitcoin Mining USB ASIC Hardware Cheatsheet"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id25,622
net_rshares0
@asabovesobelow ·
Yes indeed, many many hours of tinkering ;) hopefully it can help save some time.

I believe that the 5% of POW mining that the STEEM network utilizes is a CPU mining algo, thus the gridseeds (scrypt / SHA256) are of no use, tho i could be mistaken.  If anyone else knows for sure, please chime in.
properties (22)
authorasabovesobelow
permlinkre-tinfoilfedora-re-asabovesobelow-bitcoin-mining-usb-asic-hardware-cheatsheet-20160621t135702805z
categorymining-bitcoin
json_metadata{"tags":["mining-bitcoin"]}
created2016-06-21 13:57:03
last_update2016-06-21 13:57:03
depth2
children0
last_payout2016-08-14 04:41:51
cashout_time1969-12-31 23:59:59
total_payout_value0.000 HBD
curator_payout_value0.000 HBD
pending_payout_value0.000 HBD
promoted0.000 HBD
body_length298
author_reputation1,278,117,927,133
root_title"Bitcoin Mining USB ASIC Hardware Cheatsheet"
beneficiaries[]
max_accepted_payout1,000,000.000 HBD
percent_hbd10,000
post_id39,395
net_rshares0