Skip to content

Instantly share code, notes, and snippets.

View lbussy's full-sized avatar
🍾
Just released Keg Cop 1.2!

Lee Bussy lbussy

🍾
Just released Keg Cop 1.2!
View GitHub Profile
Thank you for your interest in the BrewPi Remix Project (the "Project"). In order to clarify the intellectual property license granted with Contributions from any person or entity, the Project must have a Contributor License Agreement ("CLA") on file that has been signed by each Contributor, indicating agreement to the license terms below. This license is for your protection as a Contributor as well as the protection of the Project and its users; it does not change your rights to use your own Contributions for any other purpose. Please read this document carefully before signing and keep a copy for your records.
You accept and agree to the following terms and conditions for Your present and future Contributions submitted to the Project. In return, the Project shall not use Your Contributions in a way that is contrary to the public benefit or licenses in effect at the time of the Contribution. Except for the license granted herein to the Project and recipients of software distributed by the Project, You reser
@lbussy
lbussy / README.md
Last active November 8, 2020 16:04
A safe "blocking" delay for use with watchdog timers

Safe Delay for μControllers

Most microcontroller platforms implement a watchdog timer that resets the controller if it detects a freeze. It does that by checking to see if the code has yielded. On some, a delay() that exceeds the watchdog timer's limits will initiate a reset.

This "safe" delay yields to the stack every tick to create a "blocking" delay in user code; however, internal functions like the watchdog timer are not blocked. It optionally prints a dot every second.

@lbussy
lbussy / README.md
Last active October 12, 2023 23:54
How to create a Wireless Access Point with a, OTG connected Raspberry Pi to share your Internet Connection

Creating a Raspberry Pi Wireless Access Point Bridge (WAP) via On The Go (OTG) Connection

Issue: You are travelling and all oyu have access to is that crappy sort of Internet which requires you to hit a network login page via your laptop's web browser. You want to connect some other devices, maybe some IoT devices so you can keep up with your projects. No way to do that since they don't have a web browser. Or maybe you have access to some pay-as-you-go Internet but it only allows one device?

Solution: A Raspberry Pi Zero W (or any Pi with a WiFi).

Overview:

  1. The Raspberry Pi is connected to your computer's USB port and use what's called a Remote Network Driver Interface Specification (RNDIS) adapter to create a network between your Pi and your computer over the USB.
  2. Your main computer's network connections is then shared, allowing another network connection to use its Internet connection.
@lbussy
lbussy / README.md
Last active December 13, 2020 20:27
Backup and Shrink Raspberry Pi Images

Backup and Shrink Raspberry Pi Images

This set of scripts will back up the Raspberry Pi SD card to local (not the same SD card) storage. It will optionally shrink the image to the minimum size possible.

@lbussy
lbussy / README.md
Last active November 8, 2020 16:06
Enable Raspberry Pi 480x320 Touch Screen

Originally posted here.

I have the screen purchased here. I am using Raspbian Buster dated 09-26 and have had no issues. I followed these instructions which were on the Amazon item page:

sudo rm -rf LCD-show
git clone https://github.com/goodtft/LCD-show.git
chmod -R 755 LCD-show
cd LCD-show/
sudo ./MHS35-show
@lbussy
lbussy / raspberry_pi_watchdog.md
Last active August 6, 2021 11:22
How to set up the Raspberry Pi Watchdog Daemon

Raspberry Pi Watchdog System

There are two parts of the Raspberry Pi's Watchdog system; the daemon and the hardware module.

First, load the watchdog module:

$ sudo modprobe bcm2708_wdog
@lbussy
lbussy / README.md
Last active March 17, 2024 21:00
External Button Shutdown for Raspberry Pi

Shutdown Raspberry Pi with a Single Button

There are two methods:

  1. Scripted Method
  2. Boot Overlay Method (also below as "tl;dr")

tl;dr Version

Add the following to your /boot/config.txt and reboot:

@lbussy
lbussy / README.md
Last active November 8, 2020 16:06
Disable IPv6 on Raspberry Pi
@lbussy
lbussy / README.md
Last active November 7, 2020 19:45
Check Temp Throttling on RPi

Check Temperature Throttling on the Raspberry Pi

This small Python script will display any temperature throttling messages on the Raspberry Pi.

@lbussy
lbussy / README.md
Last active November 8, 2020 15:29
PWM Generator for Raspberry Pi

Raspberry Pi PWM

This Python3 script was created to generate a square wave pattern from the GPIO of the Raspberry Pi. This signal was used to inject a signal into an electronics project, but could be used as the basis for any PWM needs.

pic_6_1

The script is configured to output the signal