Go Down

Topic: one Arduino with 2 IRS + Flash, help! (Read 646 times) previous topic - next topic


Nov 24, 2009, 09:13 am Last Edit: Nov 24, 2009, 09:18 am by jykim2 Reason: 1
hi guys, i confronted a bit complex problem when i was working on
a small project. it's using 2 irs connected with one arduino board,
and i'm trying to send 2 values that i got from 2 irs via board to Flash.

a part of code for arduino below


firstSensor = analogRead(0);
   Serial.print(firstSensor, DEC);
   Serial.print(0, BYTE);          
 delay (50);


as you see, one irs input connected with num. 0 socket,

and a part of flash script below


serialServer = new XMLSocket ();  
serialServer.connect ("", 9001);

serialServer.onData = function (data) {

     //   'data' contains the value received from arduino,


with this code,
i have no problem with just one IRS ,  sent value to Flash and receive it and use it.

but what i wonder is ,
how can i send 2 IRS values from one Arduino board and receive it with FLASH?

i can't figure out the conception of receiving 2 seperated values in Flash from one Arduino board via Serial ..

plz give me a lesson  :'(

Go Up

Please enter a valid email to subscribe

Confirm your email address

We need to confirm your email address.
To complete the subscription, please click the link in the email we just sent you.

Thank you for subscribing!

via Egeo 16
Torino, 10131