# esptool-wrapper

> Super minimal wrapper around esptool.py write_flash

Latest version **1.0.4** (published 2018-08-10) · ISC license · 0 weekly downloads

## Install

```sh
npm install esptool-wrapper
pnpm add esptool-wrapper
yarn add esptool-wrapper
bun add esptool-wrapper
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 1.0.4 |
| Published | 2018-08-10 |
| First published | 2018-08-10 |
| Weekly downloads | 0 |
| License | ISC |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 3 |
| Unpacked size | 4.7 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Morgan Allen |
| Maintainers | morganrallen |
| Keywords | esp32, esp8266, esptool, serial, mcu, micro, hardware |

## Links

- npm: https://www.npmjs.com/package/esptool-wrapper
- npm.io page: https://npm.io/package/esptool-wrapper

## Dependencies (3)

- [async](https://npm.io/package/async.md) ^2.6.1
- [debug](https://npm.io/package/debug.md) ^3.1.0
- [minimist](https://npm.io/package/minimist.md) ^1.2.0

## Recent versions

- 1.0.4 (latest) — 2018-08-10
- 1.0.2 — 2018-08-10
- 1.0.0 — 2018-08-10

## README

# esptool-wrapper
Super (duper) minimal wrapper around `esptool.py` from [Espressif](https://github.com/espressif/esptool)


## usage

```
const esptool = require("esptool-wrapper");

esptool({
  chip: "esp32",
  port: "/dev/ttyS0m3th1",
  baud: 460800,
  files: {
    0x1000: "build/boot.bin",
    0x80000: "build/app.bin"
  }
}, function(err) {
  if(err) throw err; // hopefully I tell you *WHAT* went wrong

  console.log("Nothing went wrong!");
});
```

## config

### `chip`
Chip to flash. `auto`, `esp32` or `esp8266`. Will `auto` select if not provided (slightly slower)

### `port`
Serial port for device to be flashed

### `baud`
Speed to flash device at.

### `files`
Object of files to flash, with keys representing destination address
```
...
files: {
  0x10000: "build/app.bin"
}
```

Doesn't require hex notaion (but that looks cooler)

### `args`
Additional command line args. This is mostly for controlling reset behavior.

### `cmdArgs`
Additional `write_flash` arguments. Used to pass arguments *AFTER* the `write_flash` command.

---
_Source: https://npm.io/package/esptool-wrapper · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
