Background An OTG (On-The-Go) device is a device that can act as both a host and a peripheral on a USB network. The PiZero is an OTG device. This guide pertains specifically to the PiZero and PiZero 2, but similar concepts also apply to other Raspberry Pi products (more information here). USB Ethernet Gadget A Beginner's Guide USB Mass Storage Gadget - A Beginner's Guide Host mode Used for…
I've been using a RPi4 for running Pi-hole. The RPi4 is way overpowered for Pi-hole so I decided to switch to using the Pi Zero 2 W. The Pi Zero 2 supports WiFi but does not come with an ethernet port. WiFi works perfectly well for Pi-hole, but for personal reasons, I wanted to use ethernet instead. I've read many posts that setting up an ethernet USB dongle is as easy as plugging it in. I decided…
I wrote a library that lets you cycle through the available themes in Emacs. F10 and shift-F10 keys will cycle forward and backward through the themes. The theme name is printed for reference. https://github.com/tsengf/theme-cycle Installation Download theme-cycle.el into ~/.emacs.d. Add the following to your Emacs configuration (add-to-list 'load-path (expand-file-name "~/.emacs.d) (require…
If you set the geometry of your Emacs window in elisp, you may find that the window redraws itself upon resizing. Note that I try to avoid using Xresources to set the geometry which is another solution to this problem. I'd like to control all of my settings in Emacs elisp. To do this, we will replace default-frame-alist by setting it in the set-initial-frame function which will be associated with…
I use use-package and wanted to use it to bootstrap quelpa and loading quelpa-use-package. The project pages had instructions without use-package. Here is what I had to do. (require 'package) (setq package-archives '(("melpa" . "https://melpa.org/packages/")) use-package-always-ensure t) (package-initialize) (require 'use-package-ensure) (use-package quelpa :ensure) (use-package quelpa-use-package…
I have experimented with using many ZSH prompts. On some slow systems, the latency of rendering the prompt matters. I ended up going with the following solution which is by far the fastest prompt I have come across. function git_prompt_info() { ref=$(git-branch-name -q -h 12 -b 64) || return echo " ${ref}" } function git_prompt() { #BRANCH=$(git branch 2> /dev/null | sed -e '/^[^*]/d' -e…
FreshTomato is an alternative firmware for routers. It runs very well on the Netgear R7000. Here is a list of useful FreshTomato resources for the Netgear R7000. discussion forums LinksysInfo.org| FreshTomato-ARM - development discussion only OpenLinksys| FreshTomato-ARM Reddit| r/TomatoFTW download freshtomato.org| Index of /downloads/freshtomato-arm/ installation Jays Homebrew| Netgear R7000…
If you have set your Wireless Country / Region to USA and lose the broadcast of your 5GHz radio, make sure you also set your Country Rev to 0. References https://wiki.freshtomato.org/doku.php/wireless?s[]=%2Aregion%2A#country_region
Here's a bash script that loops through 4-digit codes and prints the Unicode character associated with the code. Make sure your terminal supports Unicode characters References https://unix.stackexchange.com/questions/65803/why-is-printf-better-than-echo https://stackoverflow.com/questions/5517500/generating-hex-numbers-of-a-certain-range
If you have a USB MCE remote and it stopped working in LibreELEC 9, it could be due to interaction with a feature on the TV called CEC. If your television supports CEC and it is enabled on the television, make sure that support for CEC is also enabled in LibreELEC. On LibreELEC, you can find this setting in System->Settings->System->Input Devices->Peripherals->CEC Select CEC and enable CEC. If CEC…
BgInfo is a utility that updates your Windows desktop image with relevant static information about the system. Linux has a similar utility called Conky . Conky supports updating your background with dynamic information such as CPU load and memory usage.
Jivelite is a visualization application. Install the git and luajit development packages. apt install git libluajit-5.1-dev Install additional dependencies apt install git libsdl1.2-dev libsdl-ttf2.0-dev libsdl-image1.2-dev libsdl-gfx1.2-dev libexpat1-dev Clone the repository git clone git@github.com:ralph-irving/jivelite.git cd jivelite Update the path to the luajit header files. find . -type f…
The following instructions document how to enable a kiosk setup on Raspbian with the following requirements. utilize the lightweight Matchbox window manager utilize the Chromium browser to render a webpage in fullscreen mode remove the X cursor turn off the display after 10 minutes of inactivity Install the latest Raspbian Lite image. Note, this is the barebone image for server setup. Install…
The following instructions are the minimum steps required to enable sending email on Raspbian using Postfix and Gmail as the SMTP relay. Enable "Less Secure Apps" in your Google account. Google Account -> Security -> Less secure app access -> Turn on access -> Off Setup Raspbian apt install mailutils postfix libsasl2-modules When the Postfix Configuration dialog box comes up, select Internet Site…
There are several ways to enable Pi-hole on your network. If you are running FreshTomato, the easiest way is to update the DNS server setting of FreshTomato. First, assign a static IP to your Pi-hole server. You will need the MAC address for the network interface you are using. Assign an IP to Pi-hole, eg. 192.168.1.250. Under Basic->Static DHCP/ARP/IPT, add the static IP assignment. Save the…
A couple of days ago, the blinker indicator inside the X1 started clicking at twice the speed. Furthermore, the broken light warning indicator came up on the driver dash. I thought that the bulb had gone out and would be an easy fix. Upon disassembling the broken bulb, I noticed that the bulb housing looked like it had partially melted. The filament on the bulb looked intact. At this point, I…
There are many prepackaged audio streaming servers available for the Raspberry Pi. Between Moode, Volumio, and piCorePlayer, piCorePlayer is very rich in its capabilities. It can access local media as well as a huge list of free online streaming content including TuneIn. piCorePlayer has also been the most stable where stable is defined to the quality of having a longer uptime. Although…
Emails from certain domains are aggressively identified by Gmail as spam, although being legitimate. I've been trying to train the spam filter by flagging the false positives using the "Not Spam" button. However, the efforts do not appear to be helping. It is possible to whitelist emails are not spam. To do this, create a filter for the email. One of the actions for the filter is "Never send it to…
Have you ever wondered what router models running Tomato software are popular? It turns out there is a way to extract this information. Tomato users have the option of registering their router with the TomatoAnon database . Here is the count of the number of routers registered. One model appears to be the winner: Netgear R7000.
How effective protective gear is ranges from non-effective to completely effective and all points in between. Let's assign this range to the numbers between 0 and 1. I agree that we are not 100% protected unless we wear an Infectious Disease Protection suit. Anything that we can do to curb the virus should be done in a pandemic. As a society, we should recognize that putting on a simple face mask…
There have been a number of reports of issues with USB on the Raspberry Pi 4. I am however encountering an USB audio-related issue that has not been described. I'm running Raspberry Pi OS (32-bit) Lite Version:May 2020. I've connected a USB speaker to the Pi. Sometimes when I play an audio file, aplay complains that it cannot open the audio device. In the terminal output below, you can see that…
The following command will list the packages with leftover configuration files. dpkg -l | grep ^rc Hence, send the output to apt purge to remove all such packages. apt purge `dpkg -l | grep ^rc |awk '{print $2}'|xargs` In the future, to avoid having the configuration files leftover after removing a package, use apt purge <PACKAGE>