Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

battery-selector

БесплатноЗапускает вложенные скриптыНе проверен

Helps choose the right battery type and charging solution for Arduino/ESP32/RP2040 projects. Use when user asks about battery options, charging circuits…

wedsamuel1230от wedsamuel1230★ 36 звёзд на GitHub

Об этом скилле

Battery Selector

Guides battery chemistry and charging circuit selection for embedded projects.

Resources

This skill includes bundled tools and references:

  • scripts/compare_batteries.py - Battery comparison calculator with 15+ battery types
  • references/safety-guidelines.md - Comprehensive safety guide for all chemistries

Quick Start

Interactive selection:

uv run --no-project scripts/compare_batteries.py --interactive

Command line:

# Find battery for 50mA project, 24h runtime
uv run --no-project scripts/compare_batteries.py --current 50 --hours 24

# Require rechargeable
uv run --no-project scripts/compare_batteries.py --current 100 --hours 12 --rechargeable

# List all batteries in database
uv run --no-project scripts/compare_batteries.py --list

When to Use

  • "What battery should I use?"
  • "How do I charge this project?"
  • "Lithium vs alkaline?"
  • "Is this battery safe?"
  • Planning portable/battery-powered projects

Decision Flowchart

START
  │
  ▼
Is project rechargeable? ──No──► Alkaline/Lithium Primary
  │                              (Disposable batteries)
  Yes
  │
  ▼
What voltage does MCU need?
  │
  ├── 5V ──► LiPo + Boost converter
  │          OR 3x/4x NiMH
  │
  ├── 3.3V ──► Single LiPo (3.0-4.2V)
  │            Directly compatible!
  │
  └── 12V+ ──► Multi-cell LiPo pack
               OR Lead-acid
  │
  ▼
How much current?
  │
  ├── <50mA ──► Small LiPo (500-1000mAh)
  │             OR Coin cell (CR2032)
  │
  ├── 50-500mA ──► Standard LiPo (1000-3000mAh)
  │                OR 18650 cells
  │
  └── >500mA ──► Large LiPo (3000mAh+)
               OR Multiple 18650s
               External power recommended

Battery Chemistry Comparison

Quick Reference

Chemistry Voltage Rechargeable Energy Density Cost Safety
Alkaline 1.5V/cell No Medium Low Very safe
Lithium Primary 3V No High Medium Safe
NiMH 1.2V/cell Yes Medium Medium Safe
LiPo/Li-ion 3.7V Yes Very High Medium ⚠️ Needs care
LiFePO4 3.2V Yes High High Safer than LiPo
Lead-acid 2V/cell Yes Low Low ⚠️ Acid hazard

Alkaline (AA/AAA/9V)

Pros:

  • Cheap, available everywhere
  • No charging circuit needed
  • Very safe
  • Long shelf life (5-10 years)

Cons:

  • Not rechargeable (e-waste!)
  • Voltage drops as discharged
  • Poor at high current
  • Heavy for capacity

Best For:

  • Low-power projects (<20mA average)
  • Beginner projects
  • Remote/deployment where charging impractical
  • Backup power

Voltage Configurations:

Cells   Voltage    Use With
────────────────────────────
2x AA   3.0V       3.3V MCUs (with LDO)
3x AA   4.5V       5V MCUs (direct or LDO)
4x AA   6.0V       5V MCUs (with regulator)
9V      9.0V       With 5V/3.3V regulator

NiMH (AA/AAA Rechargeable)

Pros:

  • Rechargeable (500-1000 cycles)
  • Same size as alkaline
  • Safer than lithium
  • No memory effect

Cons:

  • Lower voltage (1.2V vs 1.5V)
  • Self-discharge (~20%/month)
  • Need proper charger
  • Heavier than LiPo

Best For:

  • Projects replacing disposable batteries
  • Educational settings
  • Where LiPo is too risky
  • Budget rechargeable solution

Charging:

  • Use dedicated NiMH charger
  • Don't mix brands/capacities
  • Eneloop/Eneloop Pro recommended

LiPo / Li-ion (3.7V)

Pros:

  • High energy density (light + powerful)
  • Rechargeable (300-500 cycles)
  • Flat discharge curve
  • Many form factors

Cons:

  • ⚠️ Fire risk if abused
  • Needs protection circuit
  • Temperature sensitive
  • Ages even unused

Best For:

  • Most portable projects
  • Weight-sensitive applications
  • When you need runtime
  • Professional builds

Critical Safety Rules:

✅ DO:
- Use protected cells with BMS
- Store at 40-60% charge
- Use proper TP4056/similar charger
- Monitor temperature during charge
- Use battery with JST-PH connector (prevents polarity swap)

❌ DON'T:
- Puncture, crush, or bend
- Charge below 0°C
- Discharge below 3.0V
- Leave charging unattended (first few times)
- Use damaged/puffy batteries

LiFePO4 (3.2V)

Pros:

  • Much safer than LiPo (no thermal runaway)
  • Longer cycle life (2000+ cycles)
  • Flat discharge curve
  • Tolerates abuse better

Cons:

  • Lower energy density
  • Lower voltage (may need boost)
  • More expensive
  • Less common in small sizes

Best For:

  • Safety-critical applications
  • Outdoor/rugged deployments
  • Long-term installations
  • When LiPo risk unacceptable

CR2032 / Coin Cells

Pros:

  • Tiny and light
  • Long shelf life
  • 3V output (direct to 3.3V MCU)

Cons:

  • Very low capacity (220mAh)
  • Poor high-current performance
  • Not rechargeable
  • ⚠️ Danger if swallowed

Best For:

  • Ultra-low power only (<10µA average)
  • RTC backup
  • Tiny sensors
  • Keyfobs, beacons

Current Limits:

Continuous: <2mA
Pulse: <15mA (brief)

DON'T use for: WiF
Полный SKILL.md на GitHub

Установить battery-selector в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

references/safety-guidelines.mdscripts/compare_batteries.py

FAQ

Что делает скилл battery-selector?

Helps choose the right battery type and charging solution for Arduino/ESP32/RP2040 projects. Use when user asks about battery options, charging circuits, power source selection, or says "what battery should I use". Covers chemistry selection, safety, voltage regulation, and charging circuits.

Как установить скилл battery-selector?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл battery-selector запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить battery-selector с