Thank you for visiting → Compete For Nothing.com ← If you find anything useful leave me a comment and share. Interested in Arduino, C#, Unity3D, Game Creation, VB.NET, learning and most important of all Sharing!.
Close Notification
Open Notification

Arduino Wireless Communication 431 MHz to 478 MHz – APC220

Arduino Wireless Communication 431 MHz to 478 MHz – APC220

Wireless communication is way too simple using the APC220.

apc220-usb

RF-MAGIC-USE

To Edit the settings on the APC220 e.g Baud rate, Node ID, Pairing code, Frequency and Transmit power you need

Download RF-Magic

Using the APC220 Wireless Transiever is extremely easy, once you install
USB-UART driver just choose the com port of the APC220 and open the Arduino
Serial Monitor and your ready to receive data.

A simple example data from Arduino using the serial out

/*
Pin Connections
GND to Ground
VCC to 5v
RX(on apcc220) to Arduino TX(pin 0)
TX(on apc220) to Arduino RX(pin 1)
*/

void setup(){
        Serial.begin(9600); //9600 is default baud rate for apc220
}

void loop(){
	Serial.println("Connected.");
        delay(1000);
}

Dogecoin
Donate Dogecoins: DGkJRWQCyBUeXbenYz18LRN9X67aora9nz Whats This?

42 Comments

  1. Caio Luiz · November 27, 2012 Reply

    I have a Arduino Mega 2560 and bought the APC 220. But I am not achieving to connected it to my arduino. Can you help me? The RF-Magic isn’t recognizing the device in my pc, but in the device manager the driver device is installed.
    Thanks!

    • warren · November 27, 2012 Reply

      Sorry for the late reply I have been on holiday. Have you managed to get the communication working between the APC220 and the PC?

  2. Caio Luiz · November 28, 2012 Reply

    Yeah! I installed the driver. But I don’t know the right pinage of adaptor USB.
    In the mine, it has 7 space, I think that is equal yours.
    Do you have e-mail, skype?

    Thanks

  3. maaz · February 22, 2013 Reply

    thx alot warren! u rocks ! mine working ! taking hours to solve this.. hahaha
    there are so many step to do b4 this can work like a charm :D pheeww

  4. T.E.D. · February 25, 2013 Reply

    Hey I have a similar problem with my APC 220.I installed the drivers, the windows is able to see the port but the RF-ANET program doesn’t let me pick any COM port on the “PC series” line, it’s simply blank. Can you help me with this problem please?I am trying lots of things but it doesn’t work. Any idea?Thanks

  5. maaz · March 3, 2013 Reply

    You have to make sure the COM port for APC220 must be lower (like COM port: 2) not higher in number (like COM port: 79, 25 or 33) or else it won’t work in RFMagic. To know what COM port you using goto Control Panel – System – Hardware – Device Manager – Click Port (COM & LPT).

  6. mcleja · April 1, 2013 Reply

    I think that the title is wrong. Not 2.4Ghz. I like the simple tutorials for Arduino thanks.

    • warren · April 4, 2013 Reply

      LOL I had not even noticed that I put that in the title :/
      Thanks for letting me know, i’ve updated it now.

  7. Ady · June 12, 2013 Reply

    hi warren..

    i have another problem with my APC220. i’m unable to get the communication working between APC and the PC. i tested your code but it’s not working. i think the problem is the APC220 setup. what is the RF frequency you used?also with the series rate?

    thanks

    • Warren · June 14, 2013 Reply

      Ady have you downloaded the UART bridge drivers AND RF-Magic? also set the baud to 9600

  8. ady · June 14, 2013 Reply

    Yup..im already downloaded all those things and also set the baud rate to 9600.i set both series rate n air rate to 9600..also with the baud rate in arduino sketch but its still not working..fyi i used the romeo v2 board for this project.do you know what is the problem actually?

  9. Yahya · July 24, 2013 Reply

    Hi
    i have been trying to communicate with my pc to Apc 220 but i donot know why its not working i have installed everything like yuh have said before but its not working properly can you help me please.

  10. Yahya · July 24, 2013 Reply

    My board is Arduino 2560 can i send you the code so you can tell me what is the problem ?
    because i have set 9600 Baud rate in both modules and it’s still not working every thing is set driver are installed everything is perfect but its not communicating.
    Do i have to connect Rx (APC) to Arduino (Rx)?
    OR
    i have to connect Rx (APC) to Arduino (Tx)?
    Please reply i am stuck do not have time for submission i will be really very great ful to you if you help me
    Regards
    Yahya

    • warren · July 24, 2013 Reply

      Hi Yahya, TX goes to RX with any communication using the arduio, it is very confusing.

      1. Make sure you have installed the URT dirvers, Also what OS you using? Windows =7?
      2. Make your test code as simple as the example.
      3. Post your code in the comments.

  11. Yahya · July 24, 2013 Reply

    Thankyou for the reply
    Is your code is working that you have given in the example?
    Do we have to connect the two arduino boards togather with Apc 220 connected to it ?
    Or just connect one with your PC via USB Port and other with the Arduino board by making the same connection you made above ?
    Do we need two arduino boards for the wirless communication ?
    do we need to make changes in the code w.r.t to Apc 220 or not ? If we do what would be changes ?
    kindly tell me these things thank you so much.

  12. Yahya · July 25, 2013 Reply

    can you gave me your email so i can send you my code because if i send you on this blog it will come on plagerism so kindly help me in that i am really stressed please ?

  13. robbage · August 11, 2013 Reply

    The RF-Magic setup tool has to be run as administrator otherwise no serial ports are listed.
    In Windows Seven you might have to run RF-Magic in compatibility mode depending which version it is. Try “XP SP3″ compatibility.
    (It’s a terrible program but you can get it to work)

  14. stthree · March 24, 2014 Reply

    Hi,

    I aiming to use the APC220 with an Ardiuno Micro or Nano. Is there any reason these models of Arduino should not work. I ask because I am trying to get communication going and something is going wrong. Thanks.

  15. stthree · March 25, 2014 Reply

    Thanks Warren. For some reason I still cannot get this code to work.

    I have a PC where I have installed the drivers from Silicon Labs, set the parameters for the port (basically set everything to 9600 bps where I can and name it COM4), and written to the 2 APC220′s (I made sure they had identical settings except the ID’s that I changed manually).

    Using my Mac on the ardiuno side, I loaded the code on this site to the Nano then connected the other APC220 that I had written to using RF Magic.

    Back on the PC I have opened the Arduino IDE and then opened the serial monitor for COM4. I expected to see the word “connected” appear on the serial monitor, but there has been nothing.

    I have tried all combinations of reading and writing to these APC220s and cannot get them to talk to each other.

    Any help is appreciated.

  16. Martin · March 25, 2014 Reply

    Hi,
    I was able to read succesfully from RF-Magic application, but Im not able to send commands from Arduino “Serial Monitor”.
    When I click over Arduino Serial Monitor y recive “Serial Port (COM 4) is already in use”, the only thing that I have connected to my PC is the RF Wirless board.

    Any idea?
    Thanks

  17. stthree · March 26, 2014 Reply

    Hi Martin,

    I was able to get the Serial Monitor going after I closed RF Magic, but was not able to make much progress after that. I could be doing a number of things wrong.

  18. stthree · March 26, 2014 Reply

    For some reason my setup is still not working. I have 2 APC220s and 2 Ardiuno Micros. On one Nano I have the transmitter code written and on the second I have the receiver code written. With the “receiver” arduino plugged into my USB I am expecting to see a “78″ print out on the serial monitor, but instead there is nothing. When I take out the serial.available code it will print out a -1. When I put the Serial.available code back in, the serial monitor does nothing, so no bytes are making it from one APC220 to the other. I wonder if I am using RF magic wrong, setup my Com port wrong, or these boards are toast. Is there a way to check if your APC220s are dead? Any help is available.

    Transmitter Code:

    void setup()
    {
    Serial.begin(9600); //Set serial baud rate to 9600
    }

    void loop()
    {
    Serial.println(78); //print out hello string

    }

    Receiver Code:
    int incomingByte = 0; // for incoming serial data

    void setup() {
    Serial.begin(9600); // opens serial port, sets data rate to 9600 bps
    }

    void loop() {

    // send data only when you receive data:
    if (Serial.available() > 0) {
    // read the incoming byte:

    incomingByte = Serial.read();

    // say what you got:
    Serial.println(incomingByte, DEC);

    }

    }

  19. stthree · March 27, 2014 Reply

    Thanks Warren, I will give that a try tonight. I also wanted to ask if there is any special order you have to hook up the APC220 to the Arduino after the code has been uploaded. I might be doing something wrong there as well. Also, is there anything special you have to do when setting up the Silicon Labs port. I make it COM4 and made the baud rate 9600. Anyways, thanks again.

    Steve

    • warren · March 27, 2014 Reply

      Hey Steve I have posted a new image on how to setup RF-Magic for the APC’s hopefully it helps, its up the top of the post. let me know how you go.

  20. stthree · March 27, 2014 Reply

    Hmm. Still not working with the code alteration. I just used a voltmeter and probed ground and the transmitter pin on the Micro I am using to transmit. It displayed about 3V with no fluctuation. Not sure if that means no data is being sent. Are there any special headers for this Arduino code? As far as I can tell the APC220s might be the problem, but I am able to both read and write to them successfully with RF Magic so really not sure. Could you post a picture of your wiring? And is there any special order of doing anything else (do the APC’s have to be powered but disconnected from the Arduino while code is being uploaded).

  21. stthree · March 27, 2014 Reply

    My only other idea is that I should be doing something with one or more of the other 3 pins on the APC200

    • warren · March 27, 2014 Reply

      This is the wiring I use..

      Pin Connections
      GND to Ground
      VCC to 5v
      RX(on apcc220) to Arduino TX(pin 0)
      TX(on apc220) to Arduino RX(pin 1)

  22. stthree · March 28, 2014 Reply

    Yeah, I have definitely been doing that (I think). On the Micro they are in slightly different pin positions I think pins 3 and 4 according to this diagram.

    http://arduino.cc/en/uploads/Main/ArduinoMicroFront.jpg

    • warren · March 28, 2014 Reply

      Hmm that is strange, I have just read a little bit of the micro documentation and I am thinking maybe try software serial

      #include
      SoftwareSerial mySerial(0, 1);

      the position of pin 3 and 4 on the board is confusing, I still believe that they are pins 0 and 1 but I cant be certain.

  23. stthree · March 28, 2014 Reply

    Yeah, its very strange. I have also noticed that the TX and RX leds never blink when my program is running. Does that means it is not actually printing/writing to those pins. When I open the serial monitor on the transmitting micro I do see the “78″ being printed, but no TX led flashing.

    I did notice something else that is a good sign though. I plug one APC220 into the USP connector on my PC and open a serial monitor in the arduino IDE. Then I load transmitting code onto an ardiuno Micro using another coputer. I then connect external power and unplug the USB on the Micro. When I plug or unplug the APC220 from the ardiuno that is transmitting I see an hour glass startup then end on my PC. This happens every time I plug it in. So something is happening, just not sure what.

    Also, You are right Pin 1 and 0 are TX and RX on the Micro. Not sure if SS will work but I am going to play around with it. Thanks for the continued answering of my questions. Much appreciated.
    http://arduino.cc/en/uploads/Main/ArduinoMicro_Pinout2.png

    • warren · March 29, 2014 Reply

      have you tried this code on the transmitter arduino?
      void setup(){
      Serial.begin(9600); //9600 is default baud rate for apc220
      }

      void loop(){
      Serial.println(“Connected.”);
      delay(1000);
      }

  24. stthree · March 30, 2014 Reply

    Yeah I loaded that code, unplugged the USB micro (I was already powering my micro with another power source so nothing restarted). I then put my APC20 back on the bread board in the proper spot to get it power and connect it to the RX and TX connections.

    On my PC I had my other APC220 and COM4 being monitored with the Ardiuno Serial Motor. Still nothing happened. Tried many variations of this as well.

  25. stthree · March 31, 2014 Reply

    I can successfully read and write to both APC220′s and I am making sure the IDs are different and everything else the same. Incredibly puzzling. I thought maybe the Arduino Micros where the problem, but they seem to do everything else in the sketch just fine. I might be doing something very simple and fundamental wrong, but cannot pin point it.

  26. stthree · March 31, 2014 Reply

    Maybe the frequency I am trying is already used in my area and there is a much stronger signal overpowering them. I have tried several frequencies thought.

  27. stthree · March 31, 2014 Reply

    Yeah, I might have to do that. I also noticed that the Ardiuno Micro page says you need to use the Serial1 class to send TTL data out of the RX port. I tried this and it still didn’t work, but do you know anything about that?

  28. stthree · April 3, 2014 Reply

    Hi, I obtained an UNO and tried to run your code with my other setup. I made sure to break the RX and TX connections to the APC220 while loading my code. I plugged in my USB connection and also added some external power. After my code is loaded I can see the TX led on the UNO flash. When I then unplug the USB connector so I can put the APC back in place, but the second I take out the connector that loaded the code the TX stops blinking. Even after I connect the APC220, it does not come back on. Any idea what could be going on? Also, is there anything special you have to do in the port properties for Silicon Labs? Thanks.

  29. Affiq · May 2, 2014 Reply

    Hello there, im having trouble in uploading the code into the arduino board. i’ve already unplug the APC220. as the code is loading, it stuck at the end. and show some error below. it is stated that time out. do you have any idea to solve it?

Leave a reply