Installing Raspbian

comments edit

After starting on my Raspberry Pi project, I realized that the Raspberry Pi 2 doesn’t have onboard Bluetooth. I could either buy a Bluetooth dongle or switch to a Raspberry Pi 3. And since I have a Raspberry Pi 3 in my drawer and not a Bluetooth dongle, I decided to start over on my 3. So now I’m taking notes on exactly what I need to do in order to get a Pi up and running.

  1. Download the latest version of Raspbian. For this project I elected to have the version with a desktop. Estimated download time is about 10 minutes.
  2. Install etcher from an admin shell with cinst -y etcher. Estimated downloaded time is about 2 minutes.
  3. Open etcher. If it’s not on your desktop, then hit the start button and type in BalenaEtcher
  4. Pick the file you downloaded file from step 1, and flash it to an SD card.
  5. Insert SD card into Pi and boot it up. The initial boot takes a little longer than normal.
  6. Go through the onscreen Welcome Wizard
    1. Change the password (remember to write it down)
    2. Connect to WiFi. This will also fix the date/time.
    3. Run system updates. This may take
    4. Reboot
  7. Fix any mouse lag issues, if they exist
    1. sudo vi /bot/cmdline.txt
    2. Add ` usbhid.mousepoll=0` to the end of the line
    3. Reboot (this can be done while the Updates are being installed)
  8. [Optional] Change the host name (this comes in handy if you have multiple Pis and are using RSA keys)
    1. `sudo vi /etc/hostname
    2. Reboot (this can be done while the Updates are being installed)
  9. Enable SSH on the Interfaces pane of the Raspberry Pi Configurator (accessible from the Pi menu)
  10. Copy public key to the Pi
    1. On the new Pi: mkdir .ssh
    2. On the local machine: scp pi@pibuttons:.ssh/
    3. On the new Pi: cat .ssh/ >> .ssh/authorized_keys


  1. Install vim
    1. sudo apt-get install vim
    2. sudo update-alternatives --config editor
  2. Install screen
    1. sudo apt-get install screen
  3. Install VS Code - (Full Article)
    1. Install it
       sudo -s
       . <( wget -O - )
    2. Uninstall it and install it again! As of this writintg there’s a known issue with the current build. The easiest workaround is to just install an older version. The last command here tells the system not to upgrade VS Code when you ask it to upgrade other things. ```bash sudo apt-get remove code-oss sudo apt-get install code-oss=1.29.0-1539702286 sudo apt-mark hold code-oss
  4. Login to github
    1. Create a personal access token
    2. Configure git with your name, email, and tell it to stop asking for passwords
       git config --global "Josh Quintus"
       git config --global "[email protected]"
       git config --global credential.helper store
    3. Do a git push and use the access token as your password. You can forget it from here on out.

Back it up

Now that everything is set up just-so, it’s worth creating a backup so that we don’t have to do all of this ever again.

  1. Install Win32 Disk Imager
     choco install -y win32diskimager.portable
  2. Start up Disk Imager
     Win32DiskImager.exe %HomeDrive%\%HomePath%\Desktop\buttons.img
  3. There will be two devices that you can pick in the dropdown. Select the one that you can navigate to in Windows Explorer
  4. Press the Read button
  5. Wait
  6. [Optional] Zip it up. This took the file down from about 32GB (the size of the disk) to about 2GB