New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

bluetooth-programmer

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

bluetooth-programmer - npm Package Compare versions

Comparing version 1.0.0 to 1.0.1

examples/lastID

30

examples/reprogram-bluetooth.js

@@ -0,7 +1,19 @@

var fs=require('fs');
var BTP=require('../bluetooth-programmer.js');
var BTDevices=[];
var currentID=false;
//search all connected ports for Bluetooth devices and discover their baud rate.
BTP.find(foundDevices);
console.log('Searching for any BlueTooth devices connected via USB or serial')
fs.readFile(
'lastID',
function (err,data) {
currentID=Number(data);
if(!currentID)
currentID=0;
currentID++;
BTP.find(foundDevices);
//search all connected ports for Bluetooth devices and discover their baud rate.
console.log('Searching for any BlueTooth devices connected via USB or serial');
}
);

@@ -12,2 +24,3 @@

BTDevices=devices;
console.log(devices);
console.log('Found BT Devices :\n####>',devices);

@@ -42,3 +55,10 @@

console.log('setting Name');
this.BTName('DNZ38400');
this.BTName('DNZ38400-'+currentID);
fs.writeFile(
'lastID',
currentID,
function (err) {
currentID++;
}
);
console.log('setting Pin');

@@ -86,2 +106,2 @@ this.BTPin('1314');

console.log('finished board 0');
}
}

5

package.json
{
"name": "bluetooth-programmer",
"version": "1.0.0",
"version": "1.0.1",
"description": "Api to make programming bluetooth modules via USB or Serial simple and easy.",

@@ -10,5 +10,4 @@ "main": "bluetooth-programmer.js",

"dependencies": {
"serialport": "~1.4.6"
"serialport": "*"
},
"devDependencies": {},
"scripts": {

@@ -15,0 +14,0 @@ "test": "echo \"Error: no test specified\" && exit 1"

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc