# CrabPi Lab — Full Hardware Engineering Formulas & Calibration Specifications Canonical Origin: https://crabpi.com Execution Model: 100% deterministic client-side TypeScript (zero server-side payload logging). ## 1. NAS RAID, OpenZFS RAIDZ & Synology SHR Math (/tools/nas-raid-zfs-capacity-calculator) - Decimal TB to Binary TiB: TiB = TB_decimal * (10^12 / 2^40) = TB_decimal * 0.9094947. - OpenZFS Usable Pool: Deducts N_parity drives (1/2/3 for RAIDZ1/Z2/Z3), ashift=12 (4 KiB sector) raidz skip-sector padding (~1.5%–6.8% depending on recordsize 16K/128K/1M), and 1/32 (3.125%) spa_slop_shift reservation. - Copy-on-Write Safe Ceiling: 80% of usable TiB to prevent metaslab spacemap fragmentation. - Synology SHR / SHR-2 Mixed Drives: Partitions ascending drive capacities into horizontal LVM slices; every slice spanning >= 2 drives (SHR) or >= 4 drives (SHR-2) forms a RAID 1 / RAID 5 / RAID 6 stripe. ## 2. Frigate NVR Bitrate, CMR Storage & NPU Inference (/tools/nvr-camera-storage-bitrate-calculator) - Per-Camera Bitrate (Mbps) = Base_H264_15fps_Mbps(Resolution) * (FPS / 15)^0.78 * Codec_Factor(H.264=1.0, H.265=0.56, H.265+=0.38) * Scene_Factor. - Daily Storage (GB/day) = Recorded_Mbps * 86400 / 8 / 1000 * 1.10 (MP4 segment + audio + SQLite/thumbnail buffer). - Frigate Detector Load (inf/sec) = Camera_Count * Detect_FPS * Motion_Region_Factor; benchmarked against Coral USB (100 fps), Coral Dual PCIe (165 fps), Intel N100 OpenVINO (95 fps), and Raspberry Pi Hailo-8L (320 fps). ## 3. IEEE 802.3af/at/bt PoE Constant-Power Loop Drop (/tools/poe-switch-power-budget-calculator) - Copper 2-Pair Loop Resistance at Temp T: R_loop = R_100m_20C * (Length_m / 100) * (1 + 0.00393 * (T - 20)), where Cat5e 24AWG = 18.8 ohm/100m and Cat6 23AWG = 14.8 ohm/100m; 4-pair 802.3bt halves R_loop. - Quadratic Constant-Power Current: R_loop * I^2 - V_pse * I + P_pd = 0 => I = (V_pse - sqrt(V_pse^2 - 4 * R_loop * P_pd)) / (2 * R_loop), P_pse = V_pse * I. - Continuous Switch PSU Sizing: Recommended_Switch_Budget >= Total_PSE_Watts / 0.80. ## 4. Homelab 24x7 Energy, Heat & UPS Runtime (/tools/homelab-mini-pc-ups-power-calculator) - 1 Watt continuous 24x7 = 8.76 kWh/year; Thermal Output (BTU/hr) = Continuous_Watts * 3.41214. - Cold-Boot Staggered Spin-Up: Each 3.5-inch 7200 RPM NAS HDD draws ~22.0W peak on the 12V rail during motor spin-up vs 5.6W–8.4W steady state. - UPS Runtime: Models inverter efficiency (~86%), usable DoD (50%–60% VRLA with Peukert exponent k=1.18 vs 90% flat-curve LiFePO4), and VA = Watts / Power_Factor. ## 5. Deep-Sleep IoT Sensor Battery Life (/tools/iot-battery-life-calculator) - Blended Current I_avg = I_sleep + I_quiescent_LDO + (I_sensor * t_sensor + I_tx * t_tx) / T_interval + Annual_Self_Discharge_Equivalent. - Flags AMS1117 LDO quiescent traps (4,800 µA), CR2032 coin-cell internal-resistance brownouts (>25 mA TX bursts), and Li-SOCl2 passivation capacitor requirements. ## 6. Raspberry Pi 5 USB-PD & OpenClaw/ZeroClaw Daemons (/tools/raspberry-pi-power-systemd-generator & /tools/openclaw-config-generator) - Raspberry Pi 5 limits downstream USB ports to 600 mA on standard 5V/3A bricks and unlocks 1,600 mA only when 5.1V/5A (27W USB-PD) or usb_max_current_enable=1 is active. - OpenClaw v2026.11 enforces explicit ownership + per-channel-peer DM isolation; ZeroClaw v0.8.7 uses schema_version = 3 TOML with environment-injected tokens.