Used this library: http://www.phidgets.com/downloads/examp ... 120914.zip
1. com.phidget.PhidgetLED method getDiscreteLED() tries to access undeclared constant: com.phidgets.Constants.PUNK_DBL
2. com.phidget.Constants const Phid_ErrorDescriptions uses undeclared fields between commas [,,,] where it should be [null,null,null,null]. I know it will compile, but it's better to make compiler happy.
3. Lots of missing semicolons.
4. Many of the imports are unused.
5. com.phidget.Phidget method onPhidgetData invokes unescape method for declaring a `label` variable, which is never used.
Code: Select all
var label:String = _phidgetSocket.unescape(dataArray);
For those who are interested in cleaner code i've attached it to the thread. But keep in mind that in this cleaned code PhidgetLED::getDiscreteLED(index:int):int will always return 0. I made it on purpose to avoid an exception.