Skip to content

Instantly share code, notes, and snippets.

@pmarks-net
pmarks-net / xb3_disable_wifi.md
Last active April 25, 2025 00:09
Xfinity XB3 hardware mod: Disable WiFi and save 2 watts

Xfinity XB3 hardware mod: Disable WiFi and save 2 watts

Background

Comcast has a prepaid "Xfinity NOW" service that's cheaper than normal Xfinity, with unlimited data instead of a 1.2TB/month cap. If you currently have Xfinity, the NOW online signup is hidden, but when I called to cancel my Xfinity service on a date a couple weeks in the future, the NOW signup started working immediately. (I initially queried a neighbor's address to confirm that NOW was available in my area.)

The catch is that you can't use your own modem. They provide a free Arris TG1682P (also known as the XB3), but it's huge and uses more power (14.9 watts) than my Arris SB8200 (9.8 watts). I suspect they retired millions of these things and treat NOW as a recycling service.

The XB3 lets you enable bridge mode via the admin page at http://10.0.0.1/, and IPv4/IPv6 works just like a plain modem, but even in bridge mode, the gateway broadcasts several hidden SSIDs with no option to disable the radios. Curiously I did not see an `xf

@cemlyn007
cemlyn007 / switch-shortcuts.sh
Last active March 20, 2025 03:00
MacOS apply keyboard settings and change scroll without restart
#!/bin/sh
set -e
# Function to check if key 118 is enabled (used as a state indicator)
is_windows_mode() {
current_state=$(defaults read com.apple.symbolichotkeys AppleSymbolicHotKeys | grep -A5 '"118" =' | grep "enabled" | grep -c "0")
[ "$current_state" -eq 1 ]
}
# Function to toggle between Mac and Windows keyboard settings
@JohnDDuncanIII
JohnDDuncanIII / lgc1macos.txt
Created March 12, 2025 00:18
lg c1 macOS 120hz
The new "macOS" product variation of https://www.amazon.com/dp/B0DCN798Y1 allows plug-and-play 4k 120hz 12-bit RGB Full Range HDR10 on my M1 MacBook Pro using an LG C1 through the "Amazon Basics High-Speed HDMI Cable (48Gbps, 8K/60Hz ) - 3 Feet, White" hdmi cable (https://www.amazon.com/gp/product/B08BS181P2).
For optimal performance and lowest possible latency, I would also recommend:
1) Installing BetterDisplay (https://github.com/waydabber/BetterDisplay) — I did this through homebrew ($ brew install --cask BetterDisplay; open -a BetterDisplay)
2) Enabling BetterDisplay's Settings => Displays => LG TV SSCR2 => Edit display role setting, which forces macOS to treat the C1 as a monitor rather than a TV, meaning that Night Shift and True Tone will work.
3) Disabling BetterDisplay's Color Mode => GPU Dithering in the BetterDisplay menu bar dropdown.
4) Downloading Quartz Debug from "Additional Tools for Xcode 16.2" (https://download.developer.apple.com/Developer_Tools/Additional_Tools_for_Xcode_16.2/Additional
@systemswizard
systemswizard / macos-util-find-DS_Store.sh
Last active April 6, 2025 05:13
searches a mac for .DS_Store directories and fails if any are found and returns a multi-line output if there are more than one found
#!/bin/bash
# macos-util-find-DS_Store.sh inspired by https://github.com/krypted/DS_Store_Folders
# searches a mac for .DS_Store directories and fails if any are found and returns a multi-line output if there are more than one found
# https://gist.github.com/systemswizard
if [[ $(mdfind kind:folders AND kMDItemDisplayName:.DS_Store) ]]; then
echo ".DS_Store folder(s) found"
exit 1
else
echo "Could not find any .DS_Store folders"
@rbrayb
rbrayb / ExternalIDSigninSAML.xml
Created March 9, 2025 01:29
Connecting Entra External ID as an SP to Azure AD B2C via SAML
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<TrustFrameworkPolicy xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns="http://schemas.microsoft.com/online/cpim/schemas/2013/06" PolicySchemaVersion="0.3.0.0" TenantId="tenant.onmicrosoft.com" PolicyId="B2C_1A_ExternalIDSigninSAML" PublicPolicyUri="http://tenant.onmicrosoft.com/B2C_1A_ExternalIDSigninSAML" DeploymentMode="Development" UserJourneyRecorderEndpoint="urn:journeyrecorder:applicationinsights">
<BasePolicy>
<TenantId>tenant.onmicrosoft.com</TenantId>
<PolicyId>B2C_1A_TrustFrameworkExtensionsSAMLMeta</PolicyId>
</BasePolicy>
@antony-scott
antony-scott / karabiner.json
Created February 26, 2025 08:42
Common Windows to MacOS keyboard shortcuts
{
"profiles": [
{
"complex_modifications": {
"rules": [
{
"description": "Ctrl-A -> Select All",
"manipulators": [
{
"from": {
@maximmum521
maximmum521 / Install Windows Subsystem for Android on any Edition of Windows 11 non Insider.md This Guide will show you how to Install Windows Subsystem for Android or WSA on any Edition of Windows 11 non Insider release.

Install Windows Subsystem for Android on Windows 11 non Insider

WSA or Windows Subsystem for Android is a Tool that allows Windows to run Android Apps directly without using any emulator. The problem is Windows Subsystem for Android is currently only available through preview via the Beta Channel of the Windows Insider Program. But if you follow this guide, you don't have to be in Windows Insider Program to try it out. The only thing you need is Windows 11 installed and some patience.

Prerequisites:

  • A Device with any version and Edition of Windows 11 installed.
  • Internet Connection.
  • Hyper-V enabled.

Enable Hyper-V:

@coltenkrauter
coltenkrauter / auto-brightness-plugged-in-macos.md
Created February 19, 2025 03:44
Automatically sets macOS screen brightness to 100% when plugged into power. Uses a LaunchDaemon and pmset to listen for power state changes in real-time. Event-driven, no polling.

Real-Time Brightness Adjustment When Charging (macOS)

This solution automatically sets your macOS display brightness to 100% when the power adapter is connected. It leverages a LaunchDaemon that runs a persistent script listening for power state changes via pmset. This event-driven approach ensures immediate response without unnecessary polling.

Requirements

  • macOS (tested on recent versions)
  • brightness CLI (install directly from GitHub, see below)
  • Administrative privileges
@dcvz
dcvz / run-macos.sh
Last active March 10, 2025 21:22
ZeldaRecomp macOS build & run script
#!/bin/bash
# ==============================================
# Zelda64Recompiled macOS Build & Run Script
# ==============================================
#
# Prerequisites:
# 1. Install pkgx: curl -fsS https://pkgx.sh | sh
# 2. Install Xcode from the Mac App Store
#

Buying a Dumb Smart TV in 2025

When shopping for a new TV recently, I wanted something inexpensive but not full of ads. Enter one of the greatest features of the modern era, "basic tv mode" on Google TV platform:

I purchased a TCL QM7, but presumably all Google TVs are similar: it prompts to configure "Google TV" or "Basic TV" mode on startup. After confirming that Google TV mode resembles the interface from Idiocracy, I factory reset and chose basic mode. The result is a streamlined Android interface with a few preinstalled apps (YouTube, Netflix, etc.) that aren't much of a bother if you just want to select HDMI inputs and call it a day.

Note that basic mode still forces you to agree to some terms before using the TV, just not as many as Google TV mode. The TV also has a microphone, but it can be disabled via a toggle switch on the bottom.