2 arduinos之间的红外通信

时间:2016-05-31 16:58:32

标签: arduino infrared

我有2个arduinos,我想从第一个arduino(串行监视器的输入)发送到第二个arduino,使用ir leds。

我使用类似的东西:

void setup() 
{
  Serial.begin(9600);
  Serial.println("Enter a word or a phrase:");
}

void loop() 
{
   if (Serial.available() > 0) 
   {
       serialinput = Serial.read();
   }
   /*then i want here to use an irsend to put the serialinput and send it, 
   via ir to the other arduino 
   and see it in the serial monitor of the receiver. */
   // something like this: irsend.sendSony(serialinput, 20)
}

那么,你能否告诉我这是否有用以及我应该使用哪个irsend,因为我不知道它们之间的区别? (例如,有sendSony,sendNEC,发送RC5和许多其他)。 或者,如果我能从某个地方了解他们之间的差异,因为我无法找到它们。

0 个答案:

没有答案
相关问题