Created
October 14, 2014 02:35
-
-
Save johnnyman727/d959f007c3c247d3232d to your computer and use it in GitHub Desktop.
Many Modules
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require('tesselate')(['ble-ble113a', 'climate-si7020', 'ambient-attx4', 'camera-vc0706'], function(tessel, modules) { | |
console.log('connected!'); | |
modules.climate.readTemperature(message, function (err, temp) { | |
modules.climate.readHumidity(function (err, humid) { | |
console.log(temp + ":" + humid); | |
modules.ambient.getLightLevel(function (err, ldata) { | |
if (err) | |
throw err; | |
modules.ambient.getSoundLevel(function (err, sdata) { | |
console.log(ldata + ":" + sdata); | |
}); | |
}); | |
}); | |
}); | |
}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment