Help needed, Getting analog inputs to flash

Legacy support with Phidget21
Hannamja
Phidgetsian
Posts: 11
Joined: Tue Oct 02, 2012 2:13 am
Contact:

Help needed, Getting analog inputs to flash

Postby Hannamja » Wed Oct 03, 2012 3:03 am

I have just started using Phidgets/Actionscript 3 and I have met into some problems when trying to get Flash to obtain values from Phidgets.

I am using 1018_2 and 1122/1135 as the sensors. I have read multiple documents on the website and they state that I will need to use the getSensorValue(index: int) function to obtain the value for the sensors. Can someone please help me write the code to capture the values for sensors 1 and 0?

var current:int;
function getSensorValue( 1 : int ):int
{ current = getsensorvalue[1]}

Here is how I tried to put the value at sensor 1 to var. What am I doing wrong?

Further more, when I use public var phid:com.phidgets.PhidgetInterfaceKit;, I will get the error "The public attribute can only be used inside a package."

I have linked the file that I refered to when doing the code(Forums does not allow attaching PDF files). http://www.phidgets.com/documentation/T ... _Flash.pdf

Thanks in advance!

Hannamja
Phidgetsian
Posts: 11
Joined: Tue Oct 02, 2012 2:13 am
Contact:

Re: Help needed, Getting analog inputs to flash

Postby Hannamja » Thu Oct 04, 2012 10:38 am

Hmmm No one able to help me with this simple request? :?


Return to “ActionScript 3.0 - Flash CS3 / Flex / AIR”

Who is online

Users browsing this forum: No registered users and 1 guest