node-nrf24
v1.0.5
Published
This README would normally document whatever steps are necessary to get your application up and running.
Downloads
3
Readme
README
nRF24L01 无线传输模块Node控制 sdk, 使用前请确保已经安装 RF24
安装
- npm install node-nrf24 --save
发送信息
var nrf24 = require('node-nrf24');
nrf24.send('00001','hello word',(res)=>{
console.log(`send message result:${res}`);
})
监听信息接收
var nrf24 = require('node-nrf24');
//监听
nrf24.addListener('00001',(data)=>{
console.log(`recieve message data:${data}`);
})
//移除监听
nrf24.removeListener('00001');