Difference between revisions of "Installation"

From bcmeter.org
Jump to navigation Jump to search
 
(40 intermediate revisions by the same user not shown)
Line 1: Line 1:


== Preconfigured Set Up the microSD Card ==
== Recommended: Use of preconfigured microSD Card image ==
1. Download the file image [https://bcmeter.org/wp-content/uploads/simple-file-list/bcMeter.img.tar.gz here], unzip it and use [https://www.balena.io/etcher/ Etcher] to copy it to your microSD card. <br>
=== Step 1: Download and Flash the Image ===
2. After the process is complete, a new drive is visible in Windows Explorer or Mac OS Finder called /boot. Open wpa_supplicant.conf with any notepad application and change the WiFi credentials to your needs. Dont use Word or Office since they might change the quotation marks. <br>
# Download the bcMeter image file [https://bcmeter.org/wp-content/uploads/simple-file-list/bcMeter_latest_img.zip here]
3. Eject the microSD card and put it into the raspberry pi and boot it up. After 1-2 Minutes it should be logged into the WiFi with hostname raspberry
# Unzip the downloaded file to extract the image
# Use [https://www.balena.io/etcher/ Etcher] to flash the image to your microSD card:
#* Insert your microSD card into your computer
#* Open Etcher and select the extracted image file
#* Select your microSD card as the target
#* Click "Flash!" and wait for the process to complete


=== Step 2: Boot and Connect ===
# Insert the flashed microSD card into your bcMeter device
# Power on the device
# Wait approximately 2 minutes for the device to boot completely
# On your computer or mobile device, connect to the WiFi network named "'''bcMeter'''"
#* Use password: '''bcMeterbcMeter'''


Alternatively, you can do that by commandline as well with dd and nano:  
=== Step 3: Configure Your Device ===
# Open a web browser
# Navigate to [http://bcmeter.local bcmeter.local]
# The bcMeter configuration interface will appear
# Follow the on-screen instructions to complete your device setup


Write the image to microSD on Linux
=== Troubleshooting ===
      sudo dd if=path/to/bcMeter.img of=/dev/diskX bs=8M
* If you cannot connect to the "bcMeter" WiFi network, try rebooting the device
Write the image to microSD on OSX
* If the web interface doesn't load, ensure you're connected to the correct WiFi network
      sudo dd if=path/to/bcMeter.img of=/dev/rdiskX bs=8m
Replace path/to/image with path to image and (r)diskX with deviceaddress of your microSD-card. Drag / drop the icon to the terminal is possible if in desktop environment.<br>


After the transfer is complete, change the WiFi credentials on /boot
== Advanced: Manual headless Set Up the microSD Card ==
      nano wpa_supplicant.conf
Safe the file with ctrl+o and exit with ctrl+x




Use the [https://www.raspberrypi.com/software/ Raspberry Imager] tool to write Raspberry OS 64bit LITE to the microSD-Card for Raspberry pi 3A+ (32bit LITE only for raspberry 2 - legacy - not suggested)
Do '''not''' install the Dyesktop variant.


== Manual Set Up the microSD Card ==
Configure the Raspberry Pi Imager tool to configure the image with username and password, use "bcmeter" and "bcmeter.org" so the installer script.<br><br>
Also enable SSH and WiFi in the tool.


0. Copy Image of [https://www.raspberrypi.org/software/operating-systems/#raspberry-pi-os-32-bit Raspberry Pi OS '''Lite'''] on your microSD card, Documentation for Linux / OSX in this file, for Windows use [https://www.raspberrypi.org/software/ this method] <br>
After finishing, eject the microSD Card from the PC and put it into the Raspberry Pi.
'''Make sure to download the Lite''' and '''not''' Desktop / Desktop and recommended software


1. For Linux use the terminal to copy the image to the microSD card by this command:
      dd if=path/to/image of=/dev/diskX bs=8M


Replace path/to/image with path to image and diskX with deviceaddress of your microSD-card. Drag / drop the icon to the terminal is possible if in desktop environment.<br>
=== Configuring the Raspberry Pi to be a bcMeter via SSH remote access and WiFi ===


Use rdiskX instead of diskX on OSX to accelerate the transfer
Put microSD-Card in Raspberry and boot it up (takes up to a minute)


== Configure the microSD Card for WiFi access ==
Log into the raspberry via terminal on Linux/OSX or cmd.exe on Windows
      ssh bcmeter@bcMeter
or alternatively if connection is refused
      ssh bcmeter@bcMeter.local


After the above steps, on Windows and OSX a new drive/partition named „boot“ is visible in Explorer or Finder. On Linux you see additionally rootfs, we can ignore this. 
Or to use with dedicated ssh client, like putty:


2. Create a new and empty file just called „ssh“ on the new boot partition. This is just for enabling ssh as Raspberry OS evaluates this file to enable the ssh configuration.
address: bcMeter
You can simply do that in Linux/OSX by navigating to the /boot partition of the microSD Card and enter
      nano ssh


Then just save the empty file and exit (ctrl+o for save, ctrl+x for exit)
login name: bcmeter


On Windows, open Notepad.exe and save the empty file as ssh on /boot. Double check in file properties that no .txt is added (but hidden)
login passwort: bcmeter.org (or whatever you chose)


'''If connections is refused, check connection first and then try to add .local to hostname (bcmeter.local)'''


3. Using the same method as above, put a file called wpa_supplicant.conf  in the same partition (/boot). This contains the credentials needed to connect to your WiFi. Add as many Networks as you like.
Then just download the bcMeter install script by entering
 
      wget -N https://raw.githubusercontent.com/bcmeter/bcmeter/main/install.sh && sudo bash install.sh
'''Be sure to edit the parameter „country“ correctly, else the pi may not be able to connect to your WiFi.'''
Copy / paste the following. Make sure quotes are pasted correctly.
 
      ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
      country=de
      update_config=1
     
     
      network={
      ssid="YourWiFiName"
      psk="Password"
      }
 
 
 
Save the file and eject the microSD Card from the PC. This file will be removed from this place as soon as the raspberry has read it. If your Raspberry does not connect to your WiFi, you can repeat this process as often as necessary. If the file is still there after an attempted boot, there has something more severe gone wrong.
 
== Configuring the Raspberry Pi to be a bcMeter ==
 
 
4. Put microSD-Card in Raspberry and boot it up (takes up to a minute)
 
Log into the raspberry via terminal on Linux/OSX 
      ssh pi@raspberrypi
 
Or any terminal client on Windows (for example Putty) with the following default credentials
 
address: raspberrypi
 
login name: pi
 
login passwort: raspberry
 
'''(For some mobile hotspots it is required to add .local to the hostname (e.g. raspberryp.local). Try this first if no connection is possible.)'''


5. Being logged in, enter
This will take you through a mainly unattended install procedure which will take a few minutes
      wget -N https://raw.githubusercontent.com/bcmeter/bcmeter/main/install.sh && sudo bash install.sh

Latest revision as of 11:16, 20 October 2025

Recommended: Use of preconfigured microSD Card image

Step 1: Download and Flash the Image

  1. Download the bcMeter image file here
  2. Unzip the downloaded file to extract the image
  3. Use Etcher to flash the image to your microSD card:
    • Insert your microSD card into your computer
    • Open Etcher and select the extracted image file
    • Select your microSD card as the target
    • Click "Flash!" and wait for the process to complete

Step 2: Boot and Connect

  1. Insert the flashed microSD card into your bcMeter device
  2. Power on the device
  3. Wait approximately 2 minutes for the device to boot completely
  4. On your computer or mobile device, connect to the WiFi network named "bcMeter"
    • Use password: bcMeterbcMeter

Step 3: Configure Your Device

  1. Open a web browser
  2. Navigate to bcmeter.local
  3. The bcMeter configuration interface will appear
  4. Follow the on-screen instructions to complete your device setup

Troubleshooting

  • If you cannot connect to the "bcMeter" WiFi network, try rebooting the device
  • If the web interface doesn't load, ensure you're connected to the correct WiFi network

Advanced: Manual headless Set Up the microSD Card

Use the Raspberry Imager tool to write Raspberry OS 64bit LITE to the microSD-Card for Raspberry pi 3A+ (32bit LITE only for raspberry 2 - legacy - not suggested) Do not install the Dyesktop variant.

Configure the Raspberry Pi Imager tool to configure the image with username and password, use "bcmeter" and "bcmeter.org" so the installer script.

Also enable SSH and WiFi in the tool.

After finishing, eject the microSD Card from the PC and put it into the Raspberry Pi.


Configuring the Raspberry Pi to be a bcMeter via SSH remote access and WiFi

Put microSD-Card in Raspberry and boot it up (takes up to a minute)

Log into the raspberry via terminal on Linux/OSX or cmd.exe on Windows

     ssh bcmeter@bcMeter 

or alternatively if connection is refused

     ssh bcmeter@bcMeter.local

Or to use with dedicated ssh client, like putty:

address: bcMeter

login name: bcmeter

login passwort: bcmeter.org (or whatever you chose)

If connections is refused, check connection first and then try to add .local to hostname (bcmeter.local)

Then just download the bcMeter install script by entering

      wget -N https://raw.githubusercontent.com/bcmeter/bcmeter/main/install.sh && sudo bash install.sh

This will take you through a mainly unattended install procedure which will take a few minutes