brandon-barker
3/5/2014 - 8:53 PM

Connect to sgminer API and return a summary using node-xgminer - https://www.npmjs.org/package/xgminer

Connect to sgminer API and return a summary using node-xgminer - https://www.npmjs.org/package/xgminer

var xgminer = require('../lib/xgminer');

var MinerAPI = new xgminer('Miner 1', '192.168.0.111', 4028);

MinerAPI.send('summary', '').then(function (res) {
  console.log(res);
}, function (err) {
  console.log(err);
});