Pages:
Author

Topic: Bitmain AntMiner U1 Tips & Tricks - page 35. (Read 106330 times)

full member
Activity: 192
Merit: 100
January 05, 2014, 01:14:44 AM
I made a few more changes to my branch of the bitmaintech branch of cgminer.  Probably most important is that I removed the need for the bmsc-options command line directive and allow overclocking settings to be stored in the config file.  My config file with a mild overclock looks like

Code:
{
"pools" : [
        {
                "url" : "stratum+tcp://stratum.btcguild.com:3333",
                "user" : "xxx",
                "pass" : "xxx"
        }
]
,
"api-listen" : true,
"api-mcast-port" : "4028",
"api-network" : true,
"api-port" : "4028",
"expiry" : "30",
"hotplug" : "5",
"log" : "5",
"no-pool-disable" : true,
"no-submit-stale" : true,
"queue" : "1",
"scan-time" : "15",
"shares" : "0",
"kernel-path" : "/usr/local/bin",
"bmsc-options" : "115200:20",
"bmsc-freq" : "0981"
}
Which I think is a lot better.  I invoke cgminer with the batch file
Code:
screen -fa -d -m -S miner ./cgminer -c myconfig.conf 
I am running 7 U1's in a cheap 6 dollar Chinese 10 port hub powered by a 5 amp power supply with this and it runs great.

As usual, you can get my latest code with

git clone https://github.com/fractalbc/cgminer.git

followed by the usual sets.
newbie
Activity: 57
Merit: 0
January 04, 2014, 07:36:26 PM
how many do you run like this?
newbie
Activity: 28
Merit: 0
January 04, 2014, 07:11:21 PM
Interesting evening getting these working on my pi.

Il detail my steps incase anyone is stuck.

Firstly, I used cgminer.config to save having my pool details in the launch string, to create this, type the following

cd
sudo nano cgminer.conf
///Paste the below info, editing the pool details\\\
{
"pools" : [
        {
                "url" : "PoolAddress:Port",
                "user" : "UserName.WorkerName",
                "pass" : "Password"
        }
]
,
   "api-listen" : true,
   "api-port" : "4028",
   "expiry" : "120",
   "failover-only" : true,
   "log" : "5",
   "no-pool-disable" : true,
   "queue" : "2",
   "scan-time" : "60",
   "worktime" : true,
   "shares" : "0",
   "kernel-path" : "/usr/local/bin",
   "api-allow" : "0/0",
}
///Press ctrl+x to exit, y to save the file and then the Enter key to confirm...\\\

Now, its time to tackle cgminer itself.....

sudo apt-get install autoconf
git pull https://github.com/bitmaintech/cgminer
wget http://ck.kolivas.org/apps/cgminer/3.8/cgminer-3.8.5.tar.bz2
tar xvf cgminer-3.8.5.tar.bz2
mv ./cgminer-3.8.5/configure ./cgminer/configure
///This is done because the next command kept moaning that there was no configure directory, so I gave it one....\\\
./autogen.sh
This takes a long time....
./configure --enable-bmsc
This also takes a long time....
make-j

Next, is that all important file change to stop cgminer crashing as discussed on page 2 of this topic, but basically...

cd
cd cgminer
sudo nano  driver-bmsc.c
///Press ctrl+w then paste this...\\\
memcpy((char *)&nonce, nonce_bin, sizeof(nonce_bin));
///Remove that and replace with this...\\\
memcpy((char *)&nonce, nonce_bin, sizeof(nonce));
///Press ctrl+x to exit, y to save the file and then the Enter key to confirm...\\\

To test, run the following...

sudo ./cgminer/cgminer --config /home/pi/cgminer.conf --bmsc-options 115200:20

You should see CGminer start mining, if you do, press CTRL+c to exit.

Then, I launch with the following line on bootup by typing...
sudo nano /etc/rc.local
Paste the line below befpore the Exit 0 line in there...
nohup ./cgminer/cgminer --config /home/pi/cgminer.conf --bmsc-options 115200:20


This was (as im sure people realise) based heavily off of the adafruit PiMiner tutorial, but im putting it here in one single place so anyone such as me finds it easier to start mining with their Antminers.
legendary
Activity: 4116
Merit: 7849
'The right to privacy matters'
January 04, 2014, 07:06:56 PM
Okay   anyone get windows vista to run the custom cgminer..  I have been selling sticks on ebay and one buyer has vista.    do I just set him up like it is windows 7?
sr. member
Activity: 333
Merit: 250
Ants Rock
January 04, 2014, 06:49:30 PM
My settings in Win7 sp1 64bit: cgminer.exe --bmsc-options 115200:20 --bmsc-freq  0981



BE's mining with Overclocked Ants  Cool



member
Activity: 116
Merit: 10
January 04, 2014, 05:53:01 PM
does anyone know what a safe overclock is on theses and do they need extra cooling?

Im using 0981 and a Artic usb cooling fan and they are getting between 1.8 - 2.1GH/s

newbie
Activity: 39
Merit: 0
January 04, 2014, 04:47:41 PM
does anyone know what a safe overclock is on theses and do they need extra cooling?
newbie
Activity: 15
Merit: 0
January 04, 2014, 03:22:26 PM
Hi all; I've been following this thread for a few days, initially pointing my efforts to getting my U1's working under OSX.

Firstly, I'll state that I'm running a VM of Win7 on OSX because I can't get the AntGen1/AnMiner repo to make on OSX. Therefore, I'm having some trouble with 2x U1 sticks under Win7.

What I'm experiencing on Win7, now that I have all drivers installed, is a rollercoaster ride of hashing.

Inserting the first U1, it hashes up to the desired speed (1.6GH/s+), and then stabilizes. Inserting the second U1, it too hashes up to the desired speed, and then stabilizes. It's stable for approximately 20 seconds. Then, the hashrate plummets slowly (down to >100MH/s) for each device. Wait another 20 seconds, and both will bounce back to the desired speed. Additionally, my HW error rate is around 7-10%, with the vast majority of the errors appears in the "plummet" phase.

I can't figure out what the heck is going on; if anyone has any advice I'd love to hear it.

Hi I'm running on OSX but my setup will be quite different as I've a couple of aftermarket USB 3.0 cards in it: an old one I can't remember the name of and a CalDigit.  I've tried running various miners off it.  Got a similar sounding USB polling weirdness messing with me.  To stamp on that I played with "USB Prober" in Developer/Applications/Utilities. (You need the developer tools installed)  I went to USB logger and hit start.  My USB polling problems went away.  I've not bothered digging further than that as the last few bitcoin-qt's were discouraging so've given up on the OSX version for now and went the VM route for that part.  USB logger also gives a nice log of what's plugging in and out.

I too am running my miners of an externally powered USB hub, but what I'm most curious about is how you built the AntGen1/AntMiner cgminer repo on OSX. I've been hit with a dozen errors that I simply can't troubleshoot because a dozen more open up after each one I squash.

Could you please provide some additional information on your cgminer make, setup, and run procedures for OSX? I would be very grateful.
sr. member
Activity: 280
Merit: 250
Helperizer
January 04, 2014, 02:10:52 PM
@fasmax

Sorry, I'm not entirely clear on what I need to do with the driver file... I take it you mean driver-bmsc.c?
Do I need to just paste the code from post #37 into that, or does it need to go somewhere in particular... Do I need to recompile after doing that?...

Yes You need to change the driver-bmsc.c file.

Change this line
memcpy((char *)&nonce, nonce_bin, sizeof(nonce_bin));
to
memcpy((char *)&nonce, nonce_bin, sizeof(nonce));

Then build.

Hey thx 4 your help, but I have a problem I didn't find driver-bmsc.c on my SD Card. Do I have to configure it directly in Minepeon? Or do I have to make the file on the SD by myself? Would be awesome if somebody can help.
Thank you in advance
Greetings

Weeekeda

Aha, there's your poblem - you're trying to use the linux executable rather than compiling your own.  The linux executable only runs on x86 or x86-64 processors, which the RaspberryPI does not have, even though it is linux.  You need to "git clone" the source as per earlier instructions in this threat, then make the change suggested (i.e. delete the "_bin" portion), and then "./configure --enable-bmsc" and then "make" and "make install" then you should be good to go with your very own "custom" executable for your PI.
sr. member
Activity: 322
Merit: 250
January 04, 2014, 01:59:23 PM
I've done a crash course in cgmier and got my U1 miners working as expected, but do the U1 miners have to be plugged in manually every time cgminer restarts?

On Windows 7, starting cgminer with all the U1's connected causes a "Program not responding" state.
Unplugging them all, re starting cgminer, and pluging them all in one by one seems to be the only solution.
Is there a work around for this problem?

I have to do that as well on a 7 port Antec USB hub with six, fully over-clocked, U1s. In fact, I felt like I was trying to save Apollo 13--I had to figure out which U1s had to go in which slots in which order to keep cgminer from going wonky on me.

In theory, and we'll need our resident Big Toe Twib2 to confirm, once cg(bfg?)miner starts supporting the U1, that should go away.
newbie
Activity: 42
Merit: 0
January 04, 2014, 01:20:26 PM
@fasmax

Sorry, I'm not entirely clear on what I need to do with the driver file... I take it you mean driver-bmsc.c?
Do I need to just paste the code from post #37 into that, or does it need to go somewhere in particular... Do I need to recompile after doing that?...

Yes You need to change the driver-bmsc.c file.

Change this line
memcpy((char *)&nonce, nonce_bin, sizeof(nonce_bin));
to
memcpy((char *)&nonce, nonce_bin, sizeof(nonce));

Then build.

Thanks very much... I'll give it a shot now (it'll probably be this time tomorrow before the RPI finishes building!)

/edit
Success!!! Thanks for all of the help!
full member
Activity: 165
Merit: 100
Just mining my own business...
January 04, 2014, 12:55:12 PM
As far as I know, that's the only solution... My way around it is to disconnect the USB hub, plug 1 antminer into the PC and start cgminer, then plug in the USB hub and wait for it to pick up the devices, then unplug the device from your PC and plug it into the hub... Bit of a PITA, but not much effort really. Hopefully a proper fix will be on the way soon.
On a Win7 machine, I leave one U1 plugged into the powered usb-2 hub, start cgminer (I use a freq code of 0981 with a re-purposed cpu fan blowing on them), wait until the first U1 is running, then plug in the next, wait until it's running, repeat until my 4 are all in. Sometimes I've had to reload the usb driver for one of the U1s, but not always.  It's been reasonably stable of the last couple of days (though the machine rebooted once for updates, and last night the machine mysteriously crashed - can't say it's related to the U1s). The 4 U1s run about as fast as my 22 BEs (running on a separate machine because of the compatibility issues).  

I very much agree that the U1 offers a much better price/performance than the BE or the furys.  Now we just need to mature the software driving them (ideally to allow them to play nice with my BEs!)
full member
Activity: 126
Merit: 100
January 04, 2014, 12:51:13 PM
@fasmax

Sorry, I'm not entirely clear on what I need to do with the driver file... I take it you mean driver-bmsc.c?
Do I need to just paste the code from post #37 into that, or does it need to go somewhere in particular... Do I need to recompile after doing that?...

Yes You need to change the driver-bmsc.c file.

Change this line
memcpy((char *)&nonce, nonce_bin, sizeof(nonce_bin));
to
memcpy((char *)&nonce, nonce_bin, sizeof(nonce));

Then build.

Hey thx 4 your help, but I have a problem I didn't find driver-bmsc.c on my SD Card. Do I have to configure it directly in Minepeon? Or do I have to make the file on the SD by myself? Would be awesome if somebody can help.
Thank you in advance
Greetings

Weeekeda
newbie
Activity: 14
Merit: 0
January 04, 2014, 12:22:33 PM
I've done a crash course in cgmier and got my U1 miners working as expected, but do the U1 miners have to be plugged in manually every time cgminer restarts?

On Windows 7, starting cgminer with all the U1's connected causes a "Program not responding" state.
Unplugging them all, re starting cgminer, and pluging them all in one by one seems to be the only solution.
Is there a work around for this problem?
As far as I know, that's the only solution... My way around it is to disconnect the USB hub, plug 1 antminer into the PC and start cgminer, then plug in the USB hub and wait for it to pick up the devices, then unplug the device from your PC and plug it into the hub... Bit of a PITA, but not much effort really. Hopefully a proper fix will be on the way soon.

Good idea. Thanks.
That speeds the process up.
sr. member
Activity: 378
Merit: 250
January 04, 2014, 12:10:37 PM
@fasmax

Sorry, I'm not entirely clear on what I need to do with the driver file... I take it you mean driver-bmsc.c?
Do I need to just paste the code from post #37 into that, or does it need to go somewhere in particular... Do I need to recompile after doing that?...

Yes You need to change the driver-bmsc.c file.

Change this line
memcpy((char *)&nonce, nonce_bin, sizeof(nonce_bin));
to
memcpy((char *)&nonce, nonce_bin, sizeof(nonce));

Then build.
newbie
Activity: 42
Merit: 0
January 04, 2014, 12:05:04 PM
I've done a crash course in cgmier and got my U1 miners working as expected, but do the U1 miners have to be plugged in manually every time cgminer restarts?

On Windows 7, starting cgminer with all the U1's connected causes a "Program not responding" state.
Unplugging them all, re starting cgminer, and pluging them all in one by one seems to be the only solution.
Is there a work around for this problem?
As far as I know, that's the only solution... My way around it is to disconnect the USB hub, plug 1 antminer into the PC and start cgminer, then plug in the USB hub and wait for it to pick up the devices, then unplug the device from your PC and plug it into the hub... Bit of a PITA, but not much effort really. Hopefully a proper fix will be on the way soon.
newbie
Activity: 14
Merit: 0
January 04, 2014, 12:00:18 PM
I've done a crash course in cgmier and got my U1 miners working as expected, but do the U1 miners have to be plugged in manually every time cgminer restarts?

On Windows 7, starting cgminer with all the U1's connected causes a "Program not responding" state.
Unplugging them all, re starting cgminer, and pluging them all in one by one seems to be the only solution.
Is there a work around for this problem?
sr. member
Activity: 434
Merit: 250
January 04, 2014, 11:58:51 AM
ppl, please help!

I run 4xAntminer u1 directly from my PC-Ports. I get lots of HW on default  settings:

I use custom Anminer -cgminer version.
First i  start batch file with:
Quote
cgminer  --bmsc-options 115200:20 --bmsc-freq 0781
After  all frequencies are set, the cmd-window crashes, but it doesnt matter.

Then i start  another batch. file with:
Quote
cgminer -o pool.50btc.com:3333 -u xxxxxx -p yyyyy
.
And the software starts mining.
But still the HW rate is way to high, and the pool seems not to see my full hash rate...
What do i do wrong? Maybe not enough power for 4 Miners and i need separate USB3.0 hub? ( my PC has 600Watt power supply).
I am new  to BTC mining, need help.
sr. member
Activity: 280
Merit: 250
Helperizer
January 04, 2014, 11:58:36 AM
make (I've also tried "make -j 6" as mentioned in an earlier post)

Wink  I originally put -j 6 in there (which I think iluvpcs carried over too) just for my system - it uses all six processors when compiling.  Just use the correct number of cores for your system, or leave it off; it's not that much slower on such a small program.  I'm just in the habit of using all cores especially for the xxxcoin-qt programs that take an appreciable time to compile.


Quote
When I try running cgminer with the same command line parameters which work for me in Windows (see below), I get the error "Segmentation fault"

Code:
./cgminer --bmsc-options 115200:20 -o stratum+tcp://un.coinmine.pl:6200 -u ####.### -p ##### --bmsc-freq 0881

lsusb shows the following;
Bus 001 Device 002: ID 0424:9512 Standard Microsystems Corp.
Bus 001 Device 001: ID 1d6b:0002 Linux Foundation 2.0 root hub
Bus 001 Device 009: ID 0835:8502 Action Star Enterprise Co., Ltd
Bus 001 Device 003: ID 0424:ec00 Standard Microsystems Corp.
Bus 001 Device 004: ID 7392:7711 Edimax Technology Co., Ltd EW-7711UTn nLite Wireless Adapter [Ralink RT2870]
Bus 001 Device 005: ID 0835:8500 Action Star Enterprise Co., Ltd
Bus 001 Device 006: ID 0835:8501 Action Star Enterprise Co., Ltd
Bus 001 Device 007: ID 10c4:ea60 Cygnal Integrated Products, Inc. CP210x UART Bridge / myAVR mySmartUSB light
Bus 001 Device 008: ID 0835:8500 Action Star Enterprise Co., Ltd


Any ideas where I'm going wrong?...

You probably need to edit the driver file.  In the diff output given you can see that there is only one small thing to change.  I think it was to find the matching line and delete "_bin" but you should make sure.  Anyway, to answer your other question, no, a cut and paste of that whole change posted won't work - you either need to run it through diff or just do the small edit by hand to make it match the updated line.
newbie
Activity: 42
Merit: 0
January 04, 2014, 11:54:23 AM
@fasmax

Sorry, I'm not entirely clear on what I need to do with the driver file... I take it you mean driver-bmsc.c?
Do I need to just paste the code from post #37 into that, or does it need to go somewhere in particular... Do I need to recompile after doing that?...
Pages:
Jump to: