ArduinoGeneral

APC220 wireless arduino to arduino serial? (Not PC)

userHead Account cancelled 2012-09-13 07:35:40 4795 Views1 Replies
I'm assuming it's possible but I have no idea how to get it to work, I'm making a remote controlled robot using a second arduino with buttons, analog sticks etc for control, works wired using EasyTransfer library and this works to turn the LED on and off from my PC via the USB adapter for the APC220:

[code]void setup() {
// initialize the digital pin as an output.
// Pin 13 has an LED connected on most Arduino boards:
pinMode(13, OUTPUT);
Serial.begin(9600);
Serial.println(" Lets test the APC module");
Serial.println("Press 1 to light the LED, and 2 to turn it off");
Serial.println("Input: ");
digitalWrite(13, HIGH);
}


void loop() {
if (Serial.available()){
char input = Serial.read();
switch (input){
case '1': //turn led on
digitalWrite(13, HIGH); // set the LED on
delay(100); // wait for a second
Serial.println("it works on!!");
break;
case '2':
digitalWrite(13, LOW); // set the LED off
delay(100); // wait for a second
Serial.println("it works off!!");
break;
}
}
}[/code]

But I'd like it to work without a PC in the picture, I want arduino to arduino APC220 communication, I've spotted only one guy that got it working online before and he's french and didn't document anything, didn't share his code or show the wiring. :\

Any ideas how to get this to work?

I did try connecting them as you'd expect them to work: 5v, ground, rx and tx (inverted as the docs say) to an arduino each and started serial on one and received on the other, nothing happens.
2012-09-13 15:48:03 It will work as you wanted without any problem.

Please post your second arduino code, the code you posted seems have no problem.

Try to put some delay on trasmit side.  Btw, have u successfully make your pc talk to apc? Just want to make sure that the apc is configured correctly.
userHeadPic R2D2C3PO