Created
June 19, 2011 16:19
-
-
Save anonymous/1034442 to your computer and use it in GitHub Desktop.
This file contains hidden or 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
//Setup join arrays for used joins monitoring and clearing | |
for (var join in gui.allJoins) { | |
joinType = gui.allJoins[join].charCodeAt(0); | |
joinNumber = parseInt(gui.allJoins[join].substr(1)); | |
if ((joinType == 0x64) && (joinNumber >= self.DJoin_Low) && (joinNumber <= self.DJoin_High) && (joinNumber != self.DJoin_connectedFB) && (!self.PageJoins[gui.allJoins[join]])) { //digital | |
self.DJoins.push(gui.allJoins[join]); | |
self.ClearJoins.push({join:gui.allJoins[join], value:0}); | |
} else if ((joinType == 0x61) && (joinNumber >= self.AJoin_Low) && (joinNumber <= self.AJoin_High)) { //analog | |
self.AJoins.push(gui.allJoins[join]); | |
self.ClearJoins.push({join:gui.allJoins[join], value:0}); | |
} else if ((joinType == 0x73) && (joinNumber >= self.SJoin_Low) && (joinNumber <= self.SJoin_High)) { //serial | |
self.SJoins.push(gui.allJoins[join]); | |
self.ClearJoins.push({join:gui.allJoins[join], value:""}); | |
} | |
} | |
//Clear our join ranges on the UI | |
self.clearJoins = function () { | |
self.log("Clearing Joins...",1,0); | |
CF.setJoins(self.ClearJoins, false); | |
self.log("Done Clearing Joins",0,0); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment