Pages:
Author

Topic: Building Armory on Raspberry Pi (Read 10059 times)

newbie
Activity: 2
Merit: 0
April 09, 2014, 03:32:00 PM
#43
For those interested I did a complete write up on my blog: http://moritzpfeiffer.ch/.
newbie
Activity: 2
Merit: 0
March 26, 2014, 02:55:21 PM
#42
Anyways.. have compiled armory with no errors...
running it on the pi i get the following:

Code:
root@raspberrypi:/home/pi/Desktop/BitcoinArmoryRPi# python ArmoryQt.py
********************************************************************************
Loading Armory Engine:
   Armory Version:       0.90
   PyBtcWallet  Version: 1.35
Detected Operating system: Linux
   OS Variant            : ('debian', '7.2', '')
   User home-directory   : /root
   Satoshi BTC directory : /root/.bitcoin/
   Armory home dir       : /root/.armory/
   LevelDB directory     : /root/.armory/databases
   Armory settings file  : /root/.armory/ArmorySettings.txt
   Armory log file       : /root/.armory/armorylog.txt
(ERROR) Traceback (most recent call last):
  File "ArmoryQt.py", line 32, in
    from armoryengine import *
  File "/home/pi/Desktop/BitcoinArmoryRPi/armoryengine.py", line 10916, in
    from jsonrpc import ServiceProxy, authproxy
ImportError: cannot import name authproxy

Error in sys.excepthook:
Traceback (most recent call last):
  File "/home/pi/Desktop/BitcoinArmoryRPi/armoryengine.py", line 618, in logexcept_override
    sys.__excepthook__(type, value, tback)
AttributeError: 'NoneType' object has no attribute '__excepthook__'

Original exception was:
Traceback (most recent call last):
  File "ArmoryQt.py", line 32, in
    from armoryengine import *
  File "/home/pi/Desktop/BitcoinArmoryRPi/armoryengine.py", line 10916, in
    from jsonrpc import ServiceProxy, authproxy
ImportError: cannot import name authproxy

The packaging instructions earlier in this thread are out of date for the current BitcoinArmory version.
I have done a successful cross compile of BitcoinArmory for Raspberry Pi and will do a complete write up and post it here in a couple of days.

To fix your error you need to do the following after compiling succeeds:
Code:
mkdir -p /tmp/BitcoinArmoryRPi/img/
mkdir -p /tmp/BitcoinArmoryRPi/extras/
mkdir -p /tmp/BitcoinArmoryRPi/jsonrpc/
mkdir -p /tmp/BitcoinArmoryRPi/dialogs/


cp *.py *.so README LICENSE /tmp/BitcoinArmoryRPi/
cp img/* /tmp/BitcoinArmoryRPi/img/
cp extras/*.py /tmp/BitcoinArmoryRPi/extras/
cp jsonrpc/*.py /tmp/BitcoinArmoryRPi/jsonrpc/
cp dialogs/*.py /tmp/BitcoinArmoryRPi/dialogs/

cd /tmp
tar cvfz BitcoinArmoryRPi.tar.gz BitcoinArmoryRPi
hero member
Activity: 956
Merit: 1001
March 08, 2014, 07:47:31 PM
#41
Got the above fixed... there's stuff in the makefile that needs fixing... seems the script that makes the pypaths.txt doesn't make it right...

Anyways.. have compiled armory with no errors...
running it on the pi i get the following:

Code:
root@raspberrypi:/home/pi/Desktop/BitcoinArmoryRPi# python ArmoryQt.py
********************************************************************************
Loading Armory Engine:
   Armory Version:       0.90
   PyBtcWallet  Version: 1.35
Detected Operating system: Linux
   OS Variant            : ('debian', '7.2', '')
   User home-directory   : /root
   Satoshi BTC directory : /root/.bitcoin/
   Armory home dir       : /root/.armory/
   LevelDB directory     : /root/.armory/databases
   Armory settings file  : /root/.armory/ArmorySettings.txt
   Armory log file       : /root/.armory/armorylog.txt
(ERROR) Traceback (most recent call last):
  File "ArmoryQt.py", line 32, in
    from armoryengine import *
  File "/home/pi/Desktop/BitcoinArmoryRPi/armoryengine.py", line 10916, in
    from jsonrpc import ServiceProxy, authproxy
ImportError: cannot import name authproxy

Error in sys.excepthook:
Traceback (most recent call last):
  File "/home/pi/Desktop/BitcoinArmoryRPi/armoryengine.py", line 618, in logexcept_override
    sys.__excepthook__(type, value, tback)
AttributeError: 'NoneType' object has no attribute '__excepthook__'

Original exception was:
Traceback (most recent call last):
  File "ArmoryQt.py", line 32, in
    from armoryengine import *
  File "/home/pi/Desktop/BitcoinArmoryRPi/armoryengine.py", line 10916, in
    from jsonrpc import ServiceProxy, authproxy
ImportError: cannot import name authproxy

I have done the following:

Code:
git clone https://github.com/joshmarshall/jsonrpclib
cd jsonrpclib/
python setup.py install

Same error.
Then tried:

Code:
apt-get install bzr
bzr checkout http://bzr.json-rpc.org/trunk ; cd trunk/python-jsonrpc
sudo python setup.py install


Same error...
help is appreciated..
hero member
Activity: 956
Merit: 1001
March 08, 2014, 01:40:00 PM
#40
Code:
/opt/cross/x-tools/arm-unknown-linux-gnueabi/lib/gcc/arm-unknown-linux-gnueabi/4.8.2/../../../../arm-unknown-linux-gnueabi/bin/ld: libleveldb.a(db_impl.o): Relocations in generic ELF (EM: 3)
libleveldb.a: could not read symbols: File in wrong format
collect2: error: ld returned 1 exit status
make[1]: *** [../_CppBlockUtils.so] Error 1
make[1]: Leaving directory `/home/user/src/Crosstool/RaspberryPi/staging/BitcoinArmory/cppForSwig'
make: *** [all] Error 2

Trying to cross compile on ubuntu.

Full output is here:

http://pastebin.com/8MKevDbS

Any ideas?

Thanks!
newbie
Activity: 49
Merit: 0
December 29, 2013, 06:07:26 PM
#39
In case anyone is still interested in compiling the Bitcoin Armory on the RPi, you can download the compiled source code from http://coldpi.com.

That is Bitcoin Armory 0.88, compiled for Raspbian.
newbie
Activity: 37
Merit: 0
September 27, 2013, 03:27:30 AM
#38
After reading through the guide now months after i wrote it i realize its note all that clear which parts are run on you pi, and which are run on your crosscompiling computer…

I'll try to make this clearer if while I'm making the repo/gist this weekend (if i get around to it, still not making any promises Tongue )
newbie
Activity: 37
Merit: 0
September 27, 2013, 03:24:06 AM
#37
I'm trying to follow bektars instructions back in post #15 where it gives instructs

Quote
scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/lib/libpython2.7.so ~/src/Crosstool/RaspberryPi/lib

but when I look at my RPI, I cannot find libpython2.7.so only libpython2.7.so.0 and libpython2.7.so.1
I've searched the entire drive high and low and these are the only files vaguely relevant.

Can anyone please advise what I can do?

Thanks

Do you get any error when you do this step? You are doing it from your crosscompiling computer and not your Pi, right?
newbie
Activity: 37
Merit: 0
September 27, 2013, 03:21:07 AM
#36
I'll try to take some time this weekend to make a gist or repo of the entire process… not making any promises though Smiley
newbie
Activity: 37
Merit: 0
September 27, 2013, 03:18:50 AM
#35
Ugh, i completly forgot all about this thread…

After having a quick look I would guess that the problem is copy pasting from the forum… it adds whitespace. I've created a gist at https://gist.github.com/bektar/6725546.

Use this by creating a file inside the "BitcoinArmory" directory called "BitcoinArmory.patch" and instead of doing:

Quote
cat > BitcoinArmory.patch

paste the raw contents in the gist into this file (please use a text editor, not a word editor).

And then go on with step "Apply the patch".


Please note, I havent tried this myself so please let me know how it goes.
newbie
Activity: 20
Merit: 0
August 26, 2013, 01:41:01 PM
#34
Mr bektar, sir....are you there?  Grin
newbie
Activity: 20
Merit: 0
August 26, 2013, 08:41:36 AM
#33
I'm trying to follow bektars instructions back in post #15 where it gives instructs

Quote
scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/lib/libpython2.7.so ~/src/Crosstool/RaspberryPi/lib

but when I look at my RPI, I cannot find libpython2.7.so only libpython2.7.so.0 and libpython2.7.so.1
I've searched the entire drive high and low and these are the only files vaguely relevant.

Can anyone please advise what I can do?

Thanks
newbie
Activity: 2
Merit: 0
August 11, 2013, 11:33:06 AM
#32
Any more word on this, Bektar?

I also tried going ahead and creating the patch file but I am receiving an error there too:

(Patch is indented 3 spaces.)
patching file cppForSwig/cryptopp/Makefile
(Patch is indented 3 spaces.)
patching file cppForSwig/Makefile
Hunk #1 FAILED at 1.
Hunk #2 FAILED at 37.
2 out of 2 hunks FAILED -- saving rejects to file cppForSwig/Makefile.rej

Help:(
I'm getting this error too. You can fix the indentation error though by making sure that lines that begin with either a "+", "-" or "@" don't have a space at the beginning and that all the other lines do

I have got up to this part...
scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/lib/libpython2.7.so ~/src/Crosstool/RaspberryPi/lib

except my pi does not have a libpython2.7.so directory... Have I done something wrong?

This line worked though so I'm confused:
scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/include/python2.7 ~/src/Crosstool/RaspberryPi/include

This is also confusing me, I'm pretty sure my Pi has the python libraries but they do not seem to be in that directroy... strange.
newbie
Activity: 37
Merit: 0
July 30, 2013, 12:34:29 AM
#31
I'll have a look at it tonight or tomorrow and get back to you… I thought I was pretty thorough when I tested everything, but apparently I messed up somewhere Smiley
legendary
Activity: 817
Merit: 1000
July 28, 2013, 06:23:14 PM
#30
I also tried going ahead and creating the patch file but I am receiving an error there too:

(Patch is indented 3 spaces.)
patching file cppForSwig/cryptopp/Makefile
(Patch is indented 3 spaces.)
patching file cppForSwig/Makefile
Hunk #1 FAILED at 1.
Hunk #2 FAILED at 37.
2 out of 2 hunks FAILED -- saving rejects to file cppForSwig/Makefile.rej

Help:(
legendary
Activity: 817
Merit: 1000
July 28, 2013, 05:58:22 PM
#29
I have got up to this part...
scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/lib/libpython2.7.so ~/src/Crosstool/RaspberryPi/lib

except my pi does not have a libpython2.7.so directory... Have I done something wrong?

This line worked though so I'm confused:
scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/include/python2.7 ~/src/Crosstool/RaspberryPi/include
newbie
Activity: 37
Merit: 0
July 28, 2013, 01:35:15 AM
#28
Just to make sure, you are replacing [user] with your username? If not start by doing that Smiley

In general, to change permissions in *nix you need to use the command "chmod". Perhaps in combination with "sudo" (depending on if you are the owner of the file). What you do is write

Code:
chmod 777 [filename goes here]

and thats it.

Please note that 777 gives read/write permissions to everyone. I believe its ok in this particular case since i expect you are going to be using this offline with no user except for yourself. In general though you should read the man pages for chmod and tailor the permissions as required.
newbie
Activity: 37
Merit: 0
May 13, 2013, 08:01:33 AM
#27

IP_of_PI is the ip number of your Raspberry Pi, I use the command ifconfig to find it.


IP_of_PI is the Internet Protocol address of your Pi. like 192.168.0.11

Thanks for responding, bektar & whiskers75.

So, the raspberry pi would be connected to the ubuntu computer, in a closed network?  I'd disconnect the ubuntu computer from the internet and connect to the raspberry pi so that the raspberry pi never touches the actual network?

Yes that would work. Or you could use a usb stick. As long as you get the files from the Pi to the Ubuntu computer any way is fine.
newbie
Activity: 46
Merit: 0
May 12, 2013, 11:17:35 AM
#26

IP_of_PI is the ip number of your Raspberry Pi, I use the command ifconfig to find it.


IP_of_PI is the Internet Protocol address of your Pi. like 192.168.0.11

Thanks for responding, bektar & whiskers75.

So, the raspberry pi would be connected to the ubuntu computer, in a closed network?  I'd disconnect the ubuntu computer from the internet and connect to the raspberry pi so that the raspberry pi never touches the actual network?
newbie
Activity: 1
Merit: 0
May 12, 2013, 03:42:48 AM
#25
I assume this is why I'm copying the libpython2.7.so file from the pi? Any idea what I might be doing wrong this time?
hero member
Activity: 658
Merit: 502
Doesn't use these forums that often.
May 12, 2013, 03:16:53 AM
#24
   
## Copy libraries from Pi
Quote
   scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/include/python2.7 ~/src/Crosstool/RaspberryPi/include
   scp -r pi@[IP_OF_PI_GOES_HERE]:/usr/lib/libpython2.7.so ~/src/Crosstool/RaspberryPi/lib


I'm stuck on this one.  Can an example of IP_of_PI be given?  Thanks for any help provided.
IP_of_PI is the Internet Protocol address of your Pi. like 192.168.0.11
Pages:
Jump to: