Created
March 5, 2014 23:50
-
-
Save bcomnes/612e2981d1f93fb7abbd to your computer and use it in GitHub Desktop.
node sudo hardware code
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
devices = { | |
devArduino: { | |
port: '/dev/tty.usbserial-A800ewsy' | |
function: 'stage' | |
}, | |
stageArduino: { | |
port: '/dev/tty.usbmodem3d11', | |
function: 'stage' | |
}, | |
scopeSerial: { | |
port: '/dev/tty.PL2303-0000101D', | |
function: 'scope' | |
} | |
} | |
serialport.list(function (err, ports) { | |
ports.forEach(function(port) { | |
// port.comName: '/dev/tty.PL2303-0000101D' | |
// If port.comName exists in the port key of one of the devices | |
// Set up that particular device | |
}); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment