Skip to content

Instantly share code, notes, and snippets.

@JeremiahChurch
JeremiahChurch / README.md
Created March 7, 2026 22:09
Maxum JDHC Garage Door — ESPHome control with D1 Mini + relay board (replaces ratgdo)

Maxum JDHC Garage Door — ESPHome Control (no ratgdo needed)

A standalone ESPHome solution for Maxum JDHC commercial garage door openers using a D1 Mini (ESP8266) and a cheap 3- or 4-channel relay board. This replaces ratgdo, which has known issues with Maxum openers (door opening on power cycle, unreliable close commands).

Tested and running on two Maxum doors for several months.

What You Get

  • Full open / close / stop control from Home Assistant
  • Real-time door state via physical limit switches (AUXREL boards)
@JeremiahChurch
JeremiahChurch / auto_decorate_associations.rb
Last active May 4, 2020 17:11
Draper Automatic association decoration
# Keeping track of associations in activerecord and then going over to draper decorators and adding new associations is
# something that I never much liked - multiple places meant a potential error.
# so here's an easy draper concern that keeps your draper decorators in sync with your underlying models.
# just `include AutoDecorateAssociations` on your decorators and you're done worrying about changing associations on your models.
# If you're working with a model that doesn't have a decorator - like papertrail then it can be easily excluded like :versions below.
module AutoDecorateAssociations
extend ActiveSupport::Concern
included do
@JeremiahChurch
JeremiahChurch / app-lib-subdomain_constraint.rb
Last active November 11, 2022 00:15
Custom Subdomains from Models in Rails & Rspec testing too
class SubdomainConstraint
# used in routes to generate subdomains
# note there is a cache buster in company.rb in case the subdomain is updated - `reload_routes`
# update it if we write any additional cache entries here
RESERVED_SUB_DOMAINS = %w[
www app admin test staging help support wwww cdn owner media intercom mail r _domainkey blog webhooks webhook
hooks api api-test api-staging referral outbound mail webmail w3 mailboxes io heroku inbound google search
].freeze