Raspberry Pi

We have a raspberry pi 4 for the bitcoin node. Up and running Jan 16 2021.

Install Bitcoin

https://howchoo.com/bitcoin/run-bitcoin-full-node-raspberry-pi has better (for me at least) instructions than does bitcoin.org – I got Exec format error even though I got the ARM version and 64 bit. The curl link on that page worked fine.

Disable Wi-fi and bluetooth.

If the gui methods are not working or not easy to find, use

:~ $ rfkill list
0: phy0: Wireless LAN
Soft blocked: yes
Hard blocked: no
1: hci0: Bluetooth
Soft blocked: yes
Hard blocked: no

If either is on, use sudo rfkill block wifi or sudo rfkill block bluetooth. Re-enable with sudo rfkill unblock wifi.

Make auto login

so can use VNC without having to plug in screen, mouse, keyboard after boot:

  1. Go to Preferences > Raspberry Pi Configuration > System and check the checkbox auto login as current user.
  2. Same panel, switch to Interfaces tab and switch on VNC. May as well switch on SSH too while there. 

Or if SSH is active already, login with SSH then:

sudo raspi-config
Choose option 3: Boot Options
Choose option B1: Desktop / CLI
Choose option B2: Console Autologin
Select Finish, and reboot the pi.

Boot without monitor

It will not boot unless I plug in a monitor, at least until it has finished booting. I found two possible solutions to this:

Booting headless
If you are working headless then please note that per default the RPI4 no longer creates a video output display, as a RPI4 no longer switches to Composite when it doesn’t detect a HDMI device, so a /dev/fbN frame buffer node is not created.

So with default settings and no monitor attached, VNC will NOT work, as the booted RPI4 will not have a video output system that can be used by VNC.

Adding hdmi_force_hotplug=1 to /boot/config.txt solves the problem. The Pi4 running headless, will now be able to be accessed via VNC.


Force HDMI

Uncomment the below line in the file /boot/config.txt:

#uncomment if hdmi display is not detected and composite is being output 

The latter probably requires a default resolution to be set in raspi-config (at least on the Pi4 – earlier models defaulted to VGA resolution).

Set Up File Sharing

sudo apt-get install samba samba-common-bin

After installation configure the software by opening the file /etc/samba/smb.conf using the command:

sudo nano /etc/samba/smb.conf

Make sure you have the following parameters set:

workgroup = WORKGROUP

wins support = yes

You can use anything as your workgroup name as long as it is alphanumerical and matches the workgroup you would like to join.

Setup folder to share

Next create the folder you would like to share. To create a folder called “share” in your home directory do the following:

mkdir ~/share

With the folder created we can now tell the Samba software to share it on the network. Open the file /etc/samba/smb.conf using the command:

sudo nano /etc/samba/smb.conf

Scroll to the bottom and add the following:

 comment=Raspberry Pi Share
 only guest=no
 create mask=0777
 directory mask=0777

public access is not allowed via “public=no” – this means that anyone wanting to access the shared folder must login with a valid user.

In this case the valid user is the user called “pi”. To let Samba know that “pi” is a network user run the command:

sudo smbpasswd -a pi

And enter pi’s password twice (default: raspberry).

Cooling usb firmware update

$ unzip vl805_update_0137a8.zip
$ chmod a+x vl805
$ sudo ./vl805 -w vl805_fw_0137a8.bin
$ sudo reboot

The zip file includes the current shipping firmware (013701) in case you want to revert:

$ sudo ./vl805 -w vl805_fw_013701.bin
$ sudo reboot

sudo ./vl805 with no parameters displays the version of the currently running firmware. Note that this may differ from what’s in the EEPROM if you’ve just reprogrammed it but not rebooted.