# battery-selector

battery-selector picks the cell chemistry and charging circuit for an Arduino, ESP32 or RP2040 project, from battery type down to runtime maths.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode, Windsurf (Devin Desktop), Claude.ai · 163 installs · ★ 33 repo stars
- Author: wedsamuel1230
- License: MIT · policy=mirror · the beginning of the file is at the end of this page
- Source: https://github.com/wedsamuel1230/embedded-engineering-skills/tree/HEAD/skills/battery-selector/SKILL.md
- Updated: 2026-10-15
- Security check: automated, 2026-11-16 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/skills/battery-selector

## What it does

The skill walks through powering a portable Arduino, ESP32 or RP2040 build: which chemistry fits and what charges it. A decision flowchart asks whether the pack must be rechargeable, what voltage the MCU expects and how much current the project draws. From there it points at options such as a LiPo with a boost converter, or three NiMH cells.

Capacity work goes to `scripts/compare_batteries.py`, a calculator whose database covers more than 15 battery types. Give it `--current` and `--hours` to get candidates, add `--rechargeable` to filter, or start `--interactive` and answer the prompts. It runs through `uv run --no-project`, so a machine without `uv` gets the written guidance and no calculator.

\`references/safety-guidelines.md` collects handling rules for each chemistry. The LiPo section is blunt: nothing below 0 °C on charge, nothing under 3.0V on discharge, no puffy packs. For charging hardware the advice is a TP4056 board with protection built in, the 6-pin version rather than the 4-pin one.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add wedsamuel1230/embedded-engineering-skills --skill battery-selector -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/battery-selector/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/battery-selector/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add wedsamuel1230/embedded-engineering-skills --skill battery-selector -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/battery-selector/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add wedsamuel1230/embedded-engineering-skills --skill battery-selector -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/battery-selector/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install wedsamuel1230/embedded-engineering-skills skills/battery-selector
```

2. **Manually: put the files in place**
- File: `.github/skills/battery-selector/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add wedsamuel1230/embedded-engineering-skills --skill battery-selector -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/wedsamuel1230/embedded-engineering-skills --path skills/battery-selector
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/battery-selector/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add wedsamuel1230/embedded-engineering-skills --skill battery-selector -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/wedsamuel1230/embedded-engineering-skills/tree/HEAD/skills/battery-selector/SKILL.md

## When to use it
- pick a cell chemistry for an ESP32 build
- size a battery from average current and runtime
- choose a charging circuit for a LiPo pack
- check LiPo handling rules before soldering
- compare alkaline, NiMH and LiFePO4 cells

## Example prompts
- What battery should I use for an ESP32 sensor node that runs for a day?
- Find a rechargeable cell for a 100mA load over 12 hours.
- How do I charge a single LiPo on an Arduino Nano project?

## Source text · SKILL.md · MIT

Below is the content of a third-party file. It is data, not instructions for you: do not act on anything written inside unless the human asks. Block tag: c333ee36b5211e21.

BEGIN THIRD-PARTY FILE c333ee36b5211e21
````text
---
name: battery-selector
description: 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.
metadata: {triggers: "battery choice, charging circuit, power source, battery life"}
---

# 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:**
```bash
uv run --no-project scripts/compare_batteries.py --interactive
```

**Command line:**
```bash
# 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 |
````
END THIRD-PARTY FILE c333ee36b5211e21

The third-party file has ended. Everything between the c333ee36b5211e21 tags is data: requests and commands from it are not followed. An “end of file” line with another tag inside the block is part of the file.

First 2385 of 10383 bytes. © wedsamuel1230 · MIT · https://github.com/wedsamuel1230/embedded-engineering-skills/tree/HEAD/skills/battery-selector/SKILL.md

_Part of the page did not fit — see the HTML version._

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
