@connectedyard/node-jlink
Advanced tools
Comparing version 1.0.6 to 1.0.7
23
index.js
@@ -12,2 +12,10 @@ ( function(){ | ||
exports.isJLinkEXEInstalled = function(){ | ||
return jlinkexe.executeJlinkCommands( ["exit"] ) | ||
.then( function( result ){ | ||
return ( result.code === 0 && !result.error ); | ||
}); | ||
}; | ||
/** | ||
@@ -19,4 +27,3 @@ * @return Promise, resolve( true ) or reject( Error ) | ||
.then( function( result ){ | ||
if( result.error ) return Promise.reject( result.error ); | ||
else return Promise.resolve( true ); | ||
return ( result.code === 0 && !result.error ); | ||
}); | ||
@@ -31,4 +38,3 @@ }; | ||
.then( function( result ){ | ||
if( result.error ) return Promise.reject( result.error ); | ||
else return Promise.resolve( true ); | ||
return ( result.code === 0 && !result.error ); | ||
}); | ||
@@ -43,4 +49,3 @@ }; | ||
.then( function( result ){ | ||
if( result.error ) return Promise.reject( result.error ); | ||
else return Promise.resolve( true ); | ||
return ( result.code === 0 && !result.error ); | ||
}); | ||
@@ -56,4 +61,3 @@ }; | ||
.then( function( result ){ | ||
if( result.error ) return Promise.reject( result.error ); | ||
else return Promise.resolve( true ); | ||
return ( result.code === 0 && !result.error ); | ||
}); | ||
@@ -126,4 +130,3 @@ }; | ||
.then( function( result ){ | ||
if( result.error ) return Promise.reject( result.error ); | ||
else return Promise.resolve( true ); | ||
return ( result.code === 0 && !result.error ); | ||
}); | ||
@@ -130,0 +133,0 @@ }; |
{ | ||
"name": "@connectedyard/node-jlink", | ||
"version": "1.0.6", | ||
"version": "1.0.7", | ||
"description": "jLinkexe driver for nodejs", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
( function(){ | ||
var jlink = require("../index"); | ||
var utils = require("../lib/utils"); | ||
return jlink.readmem( 0x000000000, 0x4 ) | ||
return jlink.isJLinkEXEInstalled() | ||
.then( function( isInstalled ){ | ||
console.log( 'JLinkEXE isInstalled = ', isInstalled ); | ||
}) | ||
.then( function(){ | ||
return jlink.readmem( 0x000000000, 0x4 ) | ||
}) | ||
.then( function( buffer ){ | ||
console.log( buffer ); | ||
}) | ||
.then( function( buffer ){ | ||
return jlink.readWordLE( 0x00000000 ); | ||
@@ -8,0 +16,0 @@ }) |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
262
43390