Módulo de Node.js para conectar via bluetooth com o Kit de Desenvolvimento IoT Wearable.
- Módulo Bluetooth - (HM-13)
- Luminosidade
- Temperatura
- Acelerômetro
- eixo x
- eixo y
- eixo z
- LED RGB
- Buzzer
Link - faça o download do sketch e suba no seu Kit Wearable utilizadno a IDE do Arduino.
Para utilizar o módulo primeiro instale ussndo o npm
$ npm install kit-iot-wearable
- Instalar Xcode
- Versão do Kernel > 3.6
sudo apt-get install bluetooth bluez-utils libbluetooth-dev
- Rodar como
sudo
var Wearable = require('kit-iot-wearable-bluetooth2'),
kit = new Wearable({
name: 'name-of-your-wearable'
});
kit.findWearable();
//after connect the 'connected' event will be emitted
kit.on('connected', function () {
kit.ledON('RED');
kit.playMusic();
});
Para mais exemplos veja a documentação
Veja a documentação do módulo node - link
###Documentação do Módulo bluetooth HM-13 Veja a documentação do módulo bluetooth HM-13 - link
Veja a lista de comandos aqui
Vitor Leal |