Difference between revisions of "RaspberryPi"

From Land Boards Wiki
Jump to navigation Jump to search
 
(47 intermediate revisions by 2 users not shown)
Line 8: Line 8:
  
 
<video type="youtube">drVZHDs8yGk</video>
 
<video type="youtube">drVZHDs8yGk</video>
 +
  
 
{| class="wikitable"
 
{| class="wikitable"
Line 108: Line 109:
 
| [[RPI_PSOC5]]
 
| [[RPI_PSOC5]]
 
| Raspberry Pi "Clone"
 
| Raspberry Pi "Clone"
 +
| N/A
 +
| N/A
 +
| All Raspberry Pi Models
 +
|-
 +
| [[RPI_SPI8]]
 +
| 8-Channel SPI Bus Multiplexer
 
| N/A
 
| N/A
 
| N/A
 
| N/A
Line 124: Line 131:
 
== Hardware Interfaces ==
 
== Hardware Interfaces ==
  
The Raspberry Pi has a 26-pin BERG stick style header which has the interfaces to connect up external hardware. They provide 8 GPIO pins plus access to I2C, SPI, UART), as well as +3.3 V, +5 V and GND supply lines.
+
[https://retropie-roms.co.uk/ The Raspberry Pi roms pack] has a 26-pin BERG stick style header which has the interfaces to connect up external hardware. They provide 8 GPIO pins plus access to I2C, SPI, UART), as well as +3.3 V, +5 V and GND supply lines.
  
 
WARNING: GPIO voltage levels are 3.3 V and are not 5 V tolerant. There is no over-voltage protection on the board.
 
WARNING: GPIO voltage levels are 3.3 V and are not 5 V tolerant. There is no over-voltage protection on the board.
Line 130: Line 137:
 
=== GPIO Pins ===
 
=== GPIO Pins ===
  
* [http://makezine.com/projects/tutorial-raspberry-pi-gpio-pins-and-python/ Raspberry Pi GPIO Pins and Python]
+
* [http://hackaday.com/2012/10/26/pca9517-i2c-translator-a-perfect-companion-for-raspberry-pi-hardware-add-ons/ http://makezine.com/projects/tutorial-raspberry-pi-gpio-pins-and-python/ Raspberry Pi GPIO Pins and Python]
* [http://elinux.org/RPi_Low-level_peripherals RPi Low-level peripherals at eLinux - Good description of the Raspberry Pi interfaces]
+
* [ http://elinux.org/RPi_Low-level_peripherals RPi Low-level peripherals at eLinux - Good description of the Raspberry Pi interfaces]
  
 
=== I2C Interface ===
 
=== I2C Interface ===
  
* [PCA9517 Hackaday i2c level translator - NRND]
+
* [http://hackaday.com/2012/10/26/pca9517-i2c-translator-a-perfect-companion-for-raspberry-pi-hardware-add-ons/ PCA9517 Hackaday i2c level translator] - NRND
* [PCA9306(ACTIVE) Dual Bi-Directional I2C-Bus and SMBus Voltage Level-Translator]
+
* [http://www.ti.com/product/PCA9306 PCA9306(ACTIVE) Dual Bi-Directional I2C-Bus and SMBus Voltage Level-Translator]
* [4-channel Adafruit I2C-safe Bi-directional Logic Level Converter]
+
* [http://www.adafruit.com/products/757 4-channel Adafruit I2C-safe Bi-directional Logic Level Converter]
  
 
=== SPI Interface ===
 
=== SPI Interface ===
  
Getting SPI working on the Raspberry Pi
+
* [https://www.takaitra.com/spi-device-raspberry-pi/ Controlling an SPI device with the Raspberry Pi] - Part 1
rrdtool Data logging and graphing tool
+
* [https://www.takaitra.com/mcp4151-digital-potentiometer-raspberry-pi/ Controlling the MCP4151 Digital Potentiometer with the Raspberry Pi] - Part 2
Hardware SPI
+
* [https://pimylifeup.com/raspberry-pi-spi/ Enabling SPI on the Raspberry Pi] - 01-2022
 +
* [https://learn.sparkfun.com/tutorials/raspberry-pi-spi-and-i2c-tutorial/all#spi-on-pi SPI on Pi sparkfun]
 +
* [http://oss.oetiker.ch/rrdtool/doc/rrdtool.en.html rrdtool Data logging and graphing tool]
 +
* [http://louisthiery.com/spi-python-hardware-spi-for-raspi/ Hardware SPI]
  
 
=== One Wire Interface ===
 
=== One Wire Interface ===
  
Getting One Wire working on the Raspberry Pi
+
* [http://wannabe.guru.org/scott/hobbies/temperature/ Getting One Wire working on the Raspberry Pi]
Guidelines for Reliable Long Line 1-Wire Networks
+
* [http://www.maximintegrated.com/app-notes/index.mvp/id/148 Guidelines for Reliable Long Line 1-Wire Networks]
1-Wire Temperature Sensors
+
* [http://wannabe.guru.org/scott/hobbies/temperature/ 1-Wire Temperature Sensors]
The Complete Channel One Temperature Monitor and Alarm Project - The Ultimate Raspberry Pi Bundle
+
* [http://www.element14.com/community/community/raspberry-pi/raspberrypi_projects/blog/2014/03/03/the-complete-channel-one-temperature-sensor-project--the-ultimate-raspberry-pi-bundle The Complete Channel One Temperature Monitor and Alarm Project - The Ultimate Raspberry Pi Bundle]
Raspberry Pi DS18B20 Temperature Sensing
+
* [https://learn.adafruit.com/adafruits-raspberry-pi-lesson-11-ds18b20-temperature-sensing/software Raspberry Pi DS18B20 Temperature Sensing]
  
 
=== I/O Connector ===
 
=== I/O Connector ===
  
gpio-descriptions.png
+
http://makezineblog.files.wordpress.com/2014/02/gpio-descriptions.png
  
 
=== Composite Video ===
 
=== Composite Video ===
Line 161: Line 171:
 
==== 4-Pole A/V Connector ====
 
==== 4-Pole A/V Connector ====
  
The Raspberry Pi Models A+ and B+ have a 4-pole 3.5mm connector which has right/left audio and video
+
* The Raspberry Pi Models A+ and B+ have a 4-pole 3.5mm connector which has right/left audio and video
Cheap ebay connector didn't work because of pinout
+
* Cheap ebay connector didn't work because of pinout
Cable has outer ring as ground
+
** Cable has outer ring as ground
Raspberry Pi has outer ring as video
+
** Raspberry Pi has outer ring as video
Model-B-Plus-Audio-Video-Jack-Diagram.png
 
  
Av-pinouts-zune.jpg
+
[[File:Model-B-Plus-Audio-Video-Jack-Diagram.png]]
  
Re-wired cable and it worked
+
[[File:Av-pinouts-zune.jpg]]
CompVideo-cable rewired.jpg
+
 
 +
* Re-wired cable and it worked
 +
 
 +
[[File:CompVideo-cable rewired.jpg]]
  
 
==== 3.5" Composite Output Monitor ====
 
==== 3.5" Composite Output Monitor ====
Line 176: Line 188:
 
[[File:CompVideo-Setup-2015-02-01.jpg]]
 
[[File:CompVideo-Setup-2015-02-01.jpg]]
  
3.5" LCD Display with Composite Video - Was $25 from mcmelectronics (now Newark no longer sold)
+
* 3.5" LCD Display with Composite Video - Was $25 from mcmelectronics (now Newark no longer sold)
Specifications:
+
* Specifications:
Display ratio: 4:3
+
* Display ratio: 4:3
Backlight: LED
+
* Backlight: LED
Brightness: 300 cd/m2
+
* Brightness: 300 cd/m2
Resolution: 320 x 240
+
* Resolution: 320 x 240
Viewing Angle: 40/60 60/60 (U/D/L/R)
+
* Viewing Angle: 40/60 60/60 (U/D/L/R)
Inputs: Composite Video
+
* Inputs: Composite Video
Controls: Keypad control board
+
* Controls: Keypad control board
Driving board dimension 62.0x55.2x 9.0mm
+
* Driving board dimension 62.0x55.2x 9.0mm
12~15VDC110mA±20mA
+
* 12~15VDC 110mA±20mA
83-15136.jpg
 
  
 
=== Software Setup Composite Output ===
 
=== Software Setup Composite Output ===
  
Using a Mini PAL/NTSC Display with a Raspberry Pi
+
* Using a Mini PAL/NTSC Display with a Raspberry Pi
To configure Raspian for composite output
+
* To configure Raspian for composite output
Reboot the Raspberry Pi and enter your username and password.
+
* Reboot the Raspberry Pi and enter your username and password.
To edit the configuration file, enter the command
+
* To edit the configuration file, enter the command
 +
<pre>
 
sudo nano /boot/config.txt
 
sudo nano /boot/config.txt
 +
</pre>
 
Add
 
Add
 +
<pre>
 
sdtv_mode=0    Normal NTSC
 
sdtv_mode=0    Normal NTSC
Comment out in 2 places
+
</pre>
 +
* Comment out in 2 places
 +
<pre>
 
#hdmi_force_hotplug=1
 
#hdmi_force_hotplug=1
Uncomment and add a/r
+
</pre>
 +
* Uncomment and add a/r
 +
<pre>
 
framebuffer_width=320
 
framebuffer_width=320
 
framebuffer_height=240
 
framebuffer_height=240
 +
</pre>
  
 
== Raspberry Pi Cluster Home Page ==
 
== Raspberry Pi Cluster Home Page ==
 +
 +
* [[Raspberry Pi Cluster]]
  
 
== Pi Mechanicals ==
 
== Pi Mechanicals ==
Line 210: Line 231:
 
The Raspberry Pi PCB measures 85mm x 56.2mm excluding overhanging connectors and is 20.8mm high. Pi Mechanicals are complicated due to a lack of adequate mounting holes. Various methods have been developed to deal with this deficiency. The primary method is clamping the card from the sides.
 
The Raspberry Pi PCB measures 85mm x 56.2mm excluding overhanging connectors and is 20.8mm high. Pi Mechanicals are complicated due to a lack of adequate mounting holes. Various methods have been developed to deal with this deficiency. The primary method is clamping the card from the sides.
  
Model B CAD & Mounting Info - Includes a DXF format file
+
* [http://www.raspberry-projects.com/pi/pi-hardware/model-b-cad Model B CAD & Mounting Info - Includes a DXF format file]
Raspberry Pi VESA Mount Case How to - A good mounting solution if you don't have a daughtercard
+
* [https://www.youtube.com/watch?v=-itxYEVrBxo Raspberry Pi VESA Mount Case How to] - A good mounting solution if you don't have a daughtercard
  
 
== Using a Raspberry Pi as Wireless to Ethernet Switch Bridge ==
 
== Using a Raspberry Pi as Wireless to Ethernet Switch Bridge ==
  
Raspberry Pi as Wireless to Wired Ethernet Bridge
+
[[Raspberry_Pi_as_Wireless_to_Wired_Ethernet_Bridge]]
  
 
== Setting a Static IP on the Raspberry Pi (Raspian Stretch) ==
 
== Setting a Static IP on the Raspberry Pi (Raspian Stretch) ==
  
This is for Raspian Stretch and newer (as of 2019-01)
+
* This is for Raspian Stretch and newer (as of 2019-01)
See here for configuring the IP address for older versions of Raspian (Jessie)
+
* See [http://land-boards.com/blwiki/index.php?title=RaspberryPi#Setting_a_Static_IP_on_the_Raspberry_Pi_.28Raspian_Jessie_and_earlier.29 here for configuring the IP address for older versions of Raspian (Jessie)]
 
To find out which version of Raspian is running
 
To find out which version of Raspian is running
 +
<pre>
 
cat /etc/os-release
 
cat /etc/os-release
+
</pre>
From Configuring a Static IP for a Raspberry Pi running Raspbian - (Retrieved 2019-01-19).
+
* From [http://www.techsneeze.com/configuring-static-ip-raspberry-pi-running-raspbian/ Configuring a Static IP for a Raspberry Pi running Raspbian] - (Retrieved 2019-01-19).
Open the config file for editing.
+
* Open the config file for editing.
 
+
<pre>
 
sudo nano /etc/dhcpcd.conf
 
sudo nano /etc/dhcpcd.conf
+
</pre>
 
At the bottom of the file add settings:
 
At the bottom of the file add settings:
 
+
<pre>
 
interface eth0
 
interface eth0
 
static ip_address=192.168.2.31/24
 
static ip_address=192.168.2.31/24
Line 237: Line 259:
 
static domain_search=example.com
 
static domain_search=example.com
 
static domain_name=example.com
 
static domain_name=example.com
+
</pre>
 +
 
 
== Setting a Static IP on the Raspberry Pi (Raspian Jessie and earlier) ==
 
== Setting a Static IP on the Raspberry Pi (Raspian Jessie and earlier) ==
  
This is for the older Raspian Jessie and earlier versions of Raspian
+
* This is for the older Raspian Jessie and earlier versions of Raspian
See for setting the IP on Raspian Stretch
+
* See [http://land-boards.com/blwiki/index.php?title=RaspberryPi#Setting_a_Static_IP_on_the_Raspberry_Pi_.28Raspian_Stretch.29 this for setting the IP on Raspian Stretch]
To find out which version of Raspian is running
+
* To find out which version of Raspian is running
 +
<pre>
 
cat /etc/os-release
 
cat /etc/os-release
+
</pre>
RPI-staticIP.PNG
+
 
 +
[[File:RPI-staticIP.PNG]]
  
 +
<pre>
 
sudo nano /etc/network/interfaces
 
sudo nano /etc/network/interfaces
  
Line 256: Line 282:
  
 
sudo rm /var/lib/dhcp/*
 
sudo rm /var/lib/dhcp/*
 +
</pre>
  
 
== Network Static IP Addresses ==
 
== Network Static IP Addresses ==
Line 263: Line 290:
 
=== Main .1 Network Static IP Addresses ===
 
=== Main .1 Network Static IP Addresses ===
  
192.168.1.7 = PiRouter wireless side (as seen from the main .1 network)
+
* 192.168.1.7 = PiRouter wireless side (as seen from the main .1 network)
192.168.1.XXX - MotionEyes camera
+
* 192.168.1.XXX - MotionEyes camera
PiCluster Addresses
+
* PiCluster Addresses
Intend to move the below addresses to the .2 secondary network
+
* Intend to move the below addresses to the .2 secondary network
 +
* RP2-01 192.168.1.18
  
 
=== Secondary .2 Network Static IP Addresses ===
 
=== Secondary .2 Network Static IP Addresses ===
Line 295: Line 323:
 
rpp3-15 = 192.168.2.165
 
rpp3-15 = 192.168.2.165
 
rpp3-16 = 192.168.2.166
 
rpp3-16 = 192.168.2.166
 +
</pre>
 +
 +
== Router/Bridge ==
 +
 +
* wifi-to-eth-route.sh
 +
 +
<pre>
 +
#!/bin/bash
 +
 +
# Share Wifi with Eth device
 +
# Loaded from on 2019-01-19
 +
# https://github.com/arpitjindal97/raspbian-recipes/blob/master/wifi-to-eth-rout
 +
e.sh
 +
#
 +
# This script is created to work with Raspbian Stretch
 +
# but it can be used with most of the distributions
 +
# by making few changes.
 +
#
 +
# Make sure you have already installed `dnsmasq`
 +
# Please modify the variables according to your need
 +
# Don't forget to change the name of network interface
 +
# Check them with `ifconfig`
 +
 +
ip_address="192.168.2.1"
 +
netmask="255.255.255.0"
 +
dhcp_range_start="192.168.2.2"
 +
dhcp_range_end="192.168.2.200"
 +
dhcp_time="12h"
 +
eth="eth0"
 +
wlan="wlan0"
 +
 +
sudo systemctl start network-online.target &> /dev/null
 +
 +
sudo iptables -F
 +
sudo iptables -t nat -F
 +
sudo iptables -t nat -A POSTROUTING -o $wlan -j MASQUERADE
 +
sudo iptables -A FORWARD -i $wlan -o $eth -m state --state RELATED,ESTABLISHED -
 +
j ACCEPT
 +
sudo iptables -A FORWARD -i $eth -o $wlan -j ACCEPT
 +
 +
sudo sh -c "echo 1 > /proc/sys/net/ipv4/ip_forward"
 +
 +
sudo ifconfig eth0 $ip_address netmask $netmask
 +
 +
# Remove default route created by dhcpcd
 +
sudo ip route del 0/0 dev eth0 &> /dev/null
 +
 +
sudo systemctl stop dnsmasq
 +
 +
sudo rm -rf /etc/dnsmasq.d/* &> /dev/null
 +
 +
echo -e "interface=eth0\n\
 +
bind-interfaces\n\
 +
server=8.8.8.8\n\
 +
domain-needed\n\
 +
bogus-priv\n\
 +
dhcp-range=$dhcp_range_start,$dhcp_range_end,$dhcp_time" > /tmp/custom-dnsmasq.c
 +
onf
 +
 +
sudo cp /tmp/custom-dnsmasq.conf /etc/dnsmasq.d/custom-dnsmasq.conf
 +
sudo systemctl start dnsmasq
 
</pre>
 
</pre>
  
 
== Other Pi/Linux Stuff ==
 
== Other Pi/Linux Stuff ==
  
* Raspberry Pi Documentation page
+
* [https://www.raspberrypi.org/documentation/ Raspberry Pi Documentation page]
* GitHub for Raspberry Pi Documentation page - can copy to local git repo
+
* [https://github.com/raspberrypi/documentation GitHub for Raspberry Pi Documentation page - can copy to local git repo]
* Shell programming with bash: by example, by counter-example
+
* [http://matt.might.net/articles/bash-by-example/ Shell programming with bash: by example, by counter-example]
* How to Use the Command Line for Apple macOS and Linux
+
* [https://www.taniarascia.com/how-to-use-the-command-line-for-apple-macos-and-linux/ How to Use the Command Line for Apple macOS and Linux]
 +
* [https://installvirtual.com/how-to-install-python-3-8-on-raspberry-pi-raspbian/ How to install Python 3.8 on Raspberry Pi (Raspbian)]
  
 
== Game Machines ==
 
== Game Machines ==
  
 
* RetroPie - The one we use
 
* RetroPie - The one we use
* PiPlay, formerly called PiMAME
+
* [http://pimame.org/ PiPlay, formerly called PiMAME]
* EmulationStation
+
* [https://github.com/Aloshi/EmulationStation EmulationStation]
* MAME4ALL for Pi by Squid
+
* [http://code.google.com/p/mame4all-pi/ MAME4ALL for Pi by Squid]
* GroovyGameGear.com
+
* [http://groovygamegear.com/ GroovyGameGear.com]
 +
 
 +
== Raspberry Pi Pico ==
 +
 
 +
* [[Raspberry Pi Pico]]

Latest revision as of 18:31, 5 May 2022

Tindie-mediums.png

Raspberry Pi Page

Raspberry Pi Cards


Documentation Function 3.3V GPIO 5V GPIO Compatible with
RasPi-GVS GVS card 0 16 All Raspberry Pi Models
RPP-UIO-16 GVS card 3.3V/5V 26 0-16 Raspberry Pi Models A+, B+, Pi 2
RASPI-PLUS-GVS GVS card 5V 9 16 Raspberry Pi Models A+, B+, Pi 2
RASPI-PLUS-GVS-CFG Configurable GVS hat 26 0-8 Raspberry Pi Models A+, B+, Pi 2
RPIO-TINY GVS card 17 0 All Raspberry Pi Models
RPIO-TINY-2 GVS card 17 0-8 All Raspberry Pi Models
RPIO-TINY-3 GVS card 17 0 All Raspberry Pi Models
RPI-MDI Servo card 3 0 All Raspberry Pi Models
RPI-CONSOLE Console extender card (Mini USB) N/A N/A All Raspberry Pi Models
RPI-CONSOLE-U Console extender card (Micro USB) N/A N/A All Raspberry Pi Models
RPI-I2C-HUB I2C Hub/repeater/level translator card N/A N/A All Raspberry Pi Models
RPPSOC Programmable System On a Chip N/A N/A Raspberry Pi Models A+, B+, Pi 2, Pi 3
RPI-PWR Raspberry Pi Recessed Power Card N/A N/A All Raspberry Pi Models
PIATX Raspberry Pi <> ATX Case Connections N/A N/A All Raspberry Pi Models
PC-Case-USB ATX Case USB Connections N/A N/A All Raspberry Pi Models
RPI_PSOC5 Raspberry Pi "Clone" N/A N/A All Raspberry Pi Models
RPI_SPI8 8-Channel SPI Bus Multiplexer N/A N/A All Raspberry Pi Models

Prototyping plate

The Adafruit prototyping "plate" (ie, daughtercard) is available here.

Adafruit prototyping plate 801-04.jpg

If you put a mini-breadboard in the middle it obscures the silkscreen markings for the port numbers so the above picture can help determine which header pin corresponds to which channel.

Hardware Interfaces

The Raspberry Pi roms pack has a 26-pin BERG stick style header which has the interfaces to connect up external hardware. They provide 8 GPIO pins plus access to I2C, SPI, UART), as well as +3.3 V, +5 V and GND supply lines.

WARNING: GPIO voltage levels are 3.3 V and are not 5 V tolerant. There is no over-voltage protection on the board.

GPIO Pins

I2C Interface

SPI Interface

One Wire Interface

I/O Connector

http://makezineblog.files.wordpress.com/2014/02/gpio-descriptions.png

Composite Video

4-Pole A/V Connector

  • The Raspberry Pi Models A+ and B+ have a 4-pole 3.5mm connector which has right/left audio and video
  • Cheap ebay connector didn't work because of pinout
    • Cable has outer ring as ground
    • Raspberry Pi has outer ring as video

Model-B-Plus-Audio-Video-Jack-Diagram.png

Av-pinouts-zune.jpg

  • Re-wired cable and it worked

CompVideo-cable rewired.jpg

3.5" Composite Output Monitor

CompVideo-Setup-2015-02-01.jpg

  • 3.5" LCD Display with Composite Video - Was $25 from mcmelectronics (now Newark no longer sold)
  • Specifications:
  • Display ratio: 4:3
  • Backlight: LED
  • Brightness: 300 cd/m2
  • Resolution: 320 x 240
  • Viewing Angle: 40/60 60/60 (U/D/L/R)
  • Inputs: Composite Video
  • Controls: Keypad control board
  • Driving board dimension 62.0x55.2x 9.0mm
  • 12~15VDC 110mA±20mA

Software Setup Composite Output

  • Using a Mini PAL/NTSC Display with a Raspberry Pi
  • To configure Raspian for composite output
  • Reboot the Raspberry Pi and enter your username and password.
  • To edit the configuration file, enter the command
sudo nano /boot/config.txt

Add

sdtv_mode=0    Normal NTSC
  • Comment out in 2 places
#hdmi_force_hotplug=1
  • Uncomment and add a/r
framebuffer_width=320
framebuffer_height=240

Raspberry Pi Cluster Home Page

Pi Mechanicals

The Raspberry Pi PCB measures 85mm x 56.2mm excluding overhanging connectors and is 20.8mm high. Pi Mechanicals are complicated due to a lack of adequate mounting holes. Various methods have been developed to deal with this deficiency. The primary method is clamping the card from the sides.

Using a Raspberry Pi as Wireless to Ethernet Switch Bridge

Raspberry_Pi_as_Wireless_to_Wired_Ethernet_Bridge

Setting a Static IP on the Raspberry Pi (Raspian Stretch)

To find out which version of Raspian is running

cat /etc/os-release
sudo nano /etc/dhcpcd.conf

At the bottom of the file add settings:

interface eth0
static ip_address=192.168.2.31/24
static routers=192.168.2.1
static domain_name_servers=192.168.2.1 8.8.8.8 4.2.2.1
static domain_search=example.com
static domain_name=example.com

Setting a Static IP on the Raspberry Pi (Raspian Jessie and earlier)

cat /etc/os-release

RPI-staticIP.PNG

sudo nano /etc/network/interfaces

address 192.168.1.81
netmask 255.255.255.0
network 192.168.1.0
broadcast 192.168.1.255
gateway 192.168.1.1

sudo rm /var/lib/dhcp/*

Network Static IP Addresses

There are two networks. The .1 network connects to the router to the Internet. The .2 network connects to the PiRouter.

Main .1 Network Static IP Addresses

  • 192.168.1.7 = PiRouter wireless side (as seen from the main .1 network)
  • 192.168.1.XXX - MotionEyes camera
  • PiCluster Addresses
  • Intend to move the below addresses to the .2 secondary network
  • RP2-01 192.168.1.18

Secondary .2 Network Static IP Addresses

192.168.2.1 = PiRouter wired Ethernet side (as seen from the .2 network)
192.168.2.51 = hpg7i3 - HP laptop
192.168.2.101 = RPP2-02
192.168.2.102 = RP2-01
192.168.2.103 = rpp01
192.168.2.104 = rp256
192.168.2.105 = B256
192.168.2.109 = BBB_RevC
192.168.2.110 = BBB_RevB
rpp3-01 = 192.168.2.151
rpp3-02 = 192.168.2.152
rpp3-03 = 192.168.2.153
rpp3-04 = 192.168.2.154
rpp3-05 = 192.168.2.155
rpp3-06 = 192.168.2.156
rpp3-07 = 192.168.2.157
rpp3-08 = 192.168.2.158
rpp3-09 = 192.168.2.159
rpp3-10 = 192.168.2.160
rpp3-11 = 192.168.2.161
rpp3-12 = 192.168.2.162
rpp3-13 = 192.168.2.163
rpp3-14 = 192.168.2.164
rpp3-15 = 192.168.2.165
rpp3-16 = 192.168.2.166

Router/Bridge

  • wifi-to-eth-route.sh
#!/bin/bash

# Share Wifi with Eth device
# Loaded from on 2019-01-19
# https://github.com/arpitjindal97/raspbian-recipes/blob/master/wifi-to-eth-rout
e.sh
#
# This script is created to work with Raspbian Stretch
# but it can be used with most of the distributions
# by making few changes.
#
# Make sure you have already installed `dnsmasq`
# Please modify the variables according to your need
# Don't forget to change the name of network interface
# Check them with `ifconfig`

ip_address="192.168.2.1"
netmask="255.255.255.0"
dhcp_range_start="192.168.2.2"
dhcp_range_end="192.168.2.200"
dhcp_time="12h"
eth="eth0"
wlan="wlan0"

sudo systemctl start network-online.target &> /dev/null

sudo iptables -F
sudo iptables -t nat -F
sudo iptables -t nat -A POSTROUTING -o $wlan -j MASQUERADE
sudo iptables -A FORWARD -i $wlan -o $eth -m state --state RELATED,ESTABLISHED -
j ACCEPT
sudo iptables -A FORWARD -i $eth -o $wlan -j ACCEPT

sudo sh -c "echo 1 > /proc/sys/net/ipv4/ip_forward"

sudo ifconfig eth0 $ip_address netmask $netmask

# Remove default route created by dhcpcd
sudo ip route del 0/0 dev eth0 &> /dev/null

sudo systemctl stop dnsmasq

sudo rm -rf /etc/dnsmasq.d/* &> /dev/null

echo -e "interface=eth0\n\
bind-interfaces\n\
server=8.8.8.8\n\
domain-needed\n\
bogus-priv\n\
dhcp-range=$dhcp_range_start,$dhcp_range_end,$dhcp_time" > /tmp/custom-dnsmasq.c
onf

sudo cp /tmp/custom-dnsmasq.conf /etc/dnsmasq.d/custom-dnsmasq.conf
sudo systemctl start dnsmasq

Other Pi/Linux Stuff

Game Machines

Raspberry Pi Pico