# webduino-js

> The Webduino Javascript Core, for Browser and Node.js

Latest version **0.7.0** (published 2022-08-19) · MIT license · 0 weekly downloads

## Install

```sh
npm install webduino-js
pnpm add webduino-js
yarn add webduino-js
bun add webduino-js
```

## Health

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

Positive: no vulnerabilities.

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

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.7.0 |
| Published | 2022-08-19 |
| First published | 2015-06-12 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Node | ^16.17.0 |
| Dependencies | 4 |
| Unpacked size | 2.1 MB |
| Known vulnerabilities | 0 (+1 in 1 direct dependencies) |
| Install scripts | no |
| Maintainers | shengyuan, webduino-io, oxxo.studio, mingzeke |
| Keywords | arduino, webduino |

## Links

- npm: https://www.npmjs.com/package/webduino-js
- Repository: https://github.com/webduinoio/webduino-js
- Homepage: https://webduino.io
- Issues: https://github.com/webduinoio/webduino-js/issues
- npm.io page: https://npm.io/package/webduino-js

## Dependencies (4)

- [ws](https://npm.io/package/ws.md) 1.x
- [mqtt](https://npm.io/package/mqtt.md) ^4.3.7
- [minimatch](https://npm.io/package/minimatch.md) 3.x
- [setimmediate](https://npm.io/package/setimmediate.md) 1.x

## Recent versions

- 0.7.0 (latest) — 2022-08-19
- 0.6.0 — 2019-07-26
- 0.5.4 — 2019-04-09
- 0.5.3 — 2019-03-26
- 0.5.2 — 2019-02-11
- 0.5.1 — 2019-01-11
- 0.5.0 — 2019-01-07
- 0.4.27 — 2018-11-12
- 0.4.26 — 2018-08-16
- 0.4.25 — 2018-07-10
- 0.4.24 — 2018-06-06
- 0.4.23 — 2018-05-16
- 0.4.22 — 2018-04-13
- 0.4.19 — 2018-01-12
- 0.4.18 — 2018-01-05
- … 46 more at https://npm.io/package/webduino-js/versions

## README

# webduino-js
The Webduino Javascript Core, for Browser and Node.js

## Installation
#### Browser
Using [bower](http://bower.io):
```sh
$ bower install webduino-js#dist
```

Insert scripts:
```html
<script src="bower_components/webduino-js/dist/webduino-base.js"></script>
<script src="bower_components/webduino-js/src/module/Led.js"></script>
... (modules used)
```

Or all-in-one:
```html
<script src="bower_components/webduino-js/dist/webduino-all.js"></script>
```

#### Node.js
```sh
$ npm install webduino-js
```

## Usage
**webduino-js** provides isomorphic APIs:

```javascript
var webduino = require('webduino-js');

var board, led;

board = new webduino.WebArduino('device_id');

board.on('ready', function() {
  led = new webduino.module.Led(board, board.getDigitalPin(10));
  led.on();
});
```

## Transports
**webduino-js** talks to Webduino Dev Board via MQTT by default. However, since **webduino-js** speaks [Firmata](https://www.arduino.cc/en/Reference/Firmata), we can also _directly_ talk to standard Arduino or any dev board that understands firmata.

Currently we have transports supporting USB serial port and Bluetooth (HC-06 tested) communications: _(Note: you have to install Firmata library first)_

* [webduino-serial-transport](https://github.com/webduinoio/webduino-serial-transport)
* [webduino-bluetooth-transport](https://github.com/webduinoio/webduino-bluetooth-transport)

## See Also
* [Webduino Dev Board and Webduino Dev Kit](https://webduino.io)
* [The Firmata Protocol](https://github.com/firmata/protocol)
* [Arduino Firmata Installation](http://www.instructables.com/id/Arduino-Installing-Standard-Firmata)

## License
This project is licensed under MIT license, see [LICENSE](LICENSE) for more information.

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