Skip to content

Instantly share code, notes, and snippets.

@Tech500
Tech500 / sump-monitor.ino
Last active April 9, 2026 13:24
Sump pit monitor --sends text and email alerts.
////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
//
// Version 1.0 Adding HTTP over TLS (HTTPS) 09/05/2020 @ 13:48 EDT
//
// ESP32S3 --Internet Sump Pit Monitor, Datalogger and Dynamic Web Server 04/09/2026 @ 0923 EDT
//
// NTP time routines optimized for speed by schufti --of ESP8266.com
//
// Project uses ESP32S3 Developement board
//
@Tech500
Tech500 / connect.conf
Created March 28, 2026 19:39
Mosquitto configuration files -- /etc/mosquitto/mosquitto.conf and /etc/mosquitto/conf.d/connect.conf
# Custom Mosquitto Configuration
# /etc/mosquitto/conf.d/connect.conf
#
# Stored in conf.d to survive package updates
# DO NOT duplicate pid_file or include_dir here
# -----------------------------------------------
# Per listener security settings
# -----------------------------------------------
per_listener_settings true
@Tech500
Tech500 / subnetting.md
Created March 16, 2026 10:46
Tailscale subnetting for newbies

Note: The TP3000WC weather station cannot run Tailscale directly. Subnet routing must be enabled on the host device to make it accessible over your tailnet.

To find your network range, run:

ip route

Look for a line like 192.168.1.0/24 dev eth0 — that is your subnet. Replace the example address in the advertise-routes command with your own:

@Tech500
Tech500 / Foshkplugin-Tailscale Funnel-Caddy.md
Last active March 16, 2026 08:42
Foshkplugin, Tailscal Funnel, Cady

Weather Station Architecture Diagrams

Data Collection and Distribution

[TP3000WC Weather Station]
(192.168.12.199:45000 - Ecowitt protocol)
        │
        ▼
[Raspberry Pi - 192.168.12.15]
  FOSHKplugin (/opt/FOSHKplugin/)
@Tech500
Tech500 / foshkplugin.md
Created March 16, 2026 00:19
Middle ware to send weather station data to multiple destinations

[Config]
LOX_IP = none
LOX_PORT = none
LB_IP = 192.168.12.15
LBU_PORT = 12340
LBH_PORT = 8082
LOX_TIME = False
USE_METRIC = True
@Tech500
Tech500 / caddyfile.md
Last active March 16, 2026 00:11
Caddy server config file to restrict certain paths

Caddyfile — Weather Station Secure Reverse Proxy

oscar-ii Windows 11

Tailscale Funnel forwards public HTTPS traffic to Caddy on port 8080

Caddy acts as security gatekeeper — exposing only weather dashboards

:8080 { # Block sensitive CumulusMX admin and API paths @blocked { path /api/settings* path /api/station*

@Tech500
Tech500 / weather-station-architecture.md
Created March 15, 2026 23:56
Weather-station-architecture for Hackster.io story

Weather Station Architecture Diagrams

Data Collection and Distribution

[TP3000WC Weather Station]
(192.168.12.199:45000 - Ecowitt protocol)
        │
        ▼
[Raspberry Pi - 192.168.12.15]
  FOSHKplugin (/opt/FOSHKplugin/)
@Tech500
Tech500 / weewx.conf
Last active March 15, 2026 17:16
Configuration file for weewx
william@weewx:/etc/weewx $ cat weewx.conf
# WEEWX CONFIGURATION FILE
#
# Copyright (c) 2009-2021 Tom Keffer <tkeffer@gmail.com>
# See the file LICENSE.txt for your rights.
##############################################################################
# This section is for general configuration information.
@Tech500
Tech500 / Power Analysis.md
Last active March 8, 2026 13:10
Power Analysis.md

Power Analysis

Ebyte's datasheet quotes a deep sleep floor of ~25 µA — measured with USB disconnected, OLED off, LoRa radio in full sleep, no peripherals active, running on battery alone. That's the theoretical minimum: just the ESP32 RTC domain alive, waiting for an external wakeup event.

Real-world with Wake-on-Radio running, deep sleep is ~174 µA. That is not a separate mode — it is deep sleep for this project. The SX1262 autoDutyCycle wakes for 9.2 ms every duty cycle interval to sniff for a preamble, then the

@Tech500
Tech500 / Why use FreeRTOS.md
Created March 6, 2026 04:21
Why use FreeRTOS?

Hi Claude! For those new to FreeRTOS; why use FreeRTOS?

Why Use FreeRTOS?

FreeRTOS is a popular real-time operating system kernel for embedded systems. Here's why developers choose it:

  1. Real-Time Task Management Without an RTOS, embedded code typically runs as one big loop, making it hard to guarantee when critical tasks execute. FreeRTOS lets you define tasks with priorities, ensuring time-critical work (e.g., reading a sensor, responding to an interrupt) always runs on time.