Author

Topic: FPGA mining using a Raspberry Pi (Read 7929 times)

sr. member
Activity: 467
Merit: 250
October 01, 2012, 05:44:42 PM
#5

here (https://bitcointalksearch.org/topic/m.1229746) too, in the cgminer thread.


legendary
Activity: 1027
Merit: 1005
October 01, 2012, 05:31:54 PM
#4
I plan on trying this later this week. I had my pi setup with a MMQ and it would run for about a day before locking up. I'll try your process and see if that solves the issue.

thanks!
member
Activity: 63
Merit: 10
October 01, 2012, 04:31:01 PM
#3
thx for the summary, will look into it later this week  Smiley
sr. member
Activity: 850
Merit: 331
October 01, 2012, 03:33:05 PM
#2
Of course is usefull, I've  received last friday mi RaspBerry Pi, I've installed cgminer and bfgminer, and seems to work but I have no  FPGA to test, ASIC's are on the way.

Regards
newbie
Activity: 24
Merit: 0
October 01, 2012, 02:43:52 PM
#1
Some quick instructions on how to use the Raspberry Pi for mining using FPGA's.
I wrote this one since I got a few private messages asking for tips, so it might be useful for some people.
I'm mining using a single Cairnsmore-1 using cgminer, but the instructions should also work for any other FPGA miner.

First of all: make sure you have the maximum amount of memory available for the Raspberry Pi system.
By default the PI has 128MB available for itself, and 128MB for the GPU. If you're only mining with it, you don't want to waste that memory reserved for an unused GPU.
The following command will make 224MB of memory available for the Raspberry PI (execute under root or using sudo):
cp /boot/arm224_start.elf /boot/start.elf

Install some pre-req's for cgminer:
apt-get update
apt-get install autoconf
apt-get install libcurl4-openssl-dev

Download cgminer (you can also use other miner software) and install. In the cgminer directory:
autoconf
./configure --disable-opencl --disable-cpumining --enable-icarus
make
make install

Install screen so you can disconnect and reconnect to the mining session later on:
apt-get install screen

Install some USB libs (might not all be needed, but I installed them just in case):
apt-get install libftdi1
apt-get install libusb-dev

Now, putting the udev rules in the /lib/udev/rules.d/ directory won't work (well, you can put them there, but apparently they aren't used when booting), so you'll have to type the following command every time after booting the Raspberry PI (or put it in some start-up script):
modprobe ftdi_sio product=0x8350 vendor=0x0403

So after all previous actions are done, reboot your Raspberry PI and do NOT connect any miner to it yet.
You'll need to execute the following steps every time you're rebooting your PI:

- login
- su to root (or use sudo) to execute: modprobe ftdi_sio product=0x8350 vendor=0x0403
- connect your FPGA device (you should see it's connected in the dmesg output)
- start a screen session: screen
- start your miner: cgminer --quiet --disable-gpu --icarus-timing long -S /dev/ttyUSB0 -S /dev/ttyUSB1 -S /dev/ttyUSB2 -S /dev/ttyUSB3 -o http://: -O :

You should now be mining.

press CTRL-a-d to exit the screen session, and after that exit to log off from your PI.
Next time you want to check the cgminer status, just login, and type screen -r to reconnect to the screen session (and after that CTRL-a-d to disconnect again).

Hope this is useful for somebody.
Jump to: