Metadata-Version: 2.4
Name: erc-calculator
Version: 0.1.0
Summary: Toyota ERC (Emergency Reset Code) decoder — CLI and Python library
License: MIT
Keywords: toyota,erc,automotive,unlock
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Classifier: Topic :: Utilities
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE
Provides-Extra: dev
Requires-Dist: pytest>=7; extra == "dev"
Dynamic: license-file

# erc-calculator

A Python library and CLI tool for decoding Toyota ERC (Emergency Reset Code) strings into unlock codes.

Ported from [alexeyfadeev/erc-calculator](https://github.com/alexeyfadeev/erc-calculator).

## Installation

```bash
pip install erc-calculator
```

Or install from source:

```bash
git clone https://github.com/brysonics/erc_calculator.git
cd erc_calculator
pip install -e .
```

## Usage

### CLI

Decode a single ERC:

```bash
erc-decode 82988AE13BC3A4C0
# 73BC3F2C
```

Decode a batch of ERCs from a file (one per line):

```bash
erc-decode --batch ercs.txt
# 82988AE13BC3A4C0 -> 73BC3F2C
# 66EECE00F2724BA5 -> B53B763E
```

### Python library

```python
from erc_calculator import decode

code = decode("82988AE13BC3A4C0")
print(code)  # 73BC3F2C
```

## Development

```bash
pip install -e ".[dev]"
pytest
```

## License

MIT
