Remote Mobile Robot with XBee-WiFi (Android)

By combining these two tutorial (1) Remote Mobile Robot with XBee-WiFi and (2) Xbee WiFi in Soft AP Mode, we can have a Remote Mobile Robot with XBee-WiFi (Android).

MC40A Xbee WiFi

HARDWARE
1. MC40A (link).
2. UIC00B – Programmer (link).
3. SPG10-150K (link).
4. Motor Bracket (link).
5. Castor (link).
6. Battery (link).
7. Xbee WiFi (link).
8. Xbee Starter Kit Without Module (link).
9. USB Mini Cable (link).

ANDROID APPS
WiFly Remote is a very suitable apps for this application, plus they have share the Android code too! However We are not explaining the Android code here. We just show how to use it with our stuff. First we need to know what is data sent by this apps, and we already share this, refer to Xbee WiFi in Soft AP Mode.

WiFly Remote 2

Data from the WiFly Remote apps.

xctu13

Description (update 7 May 2015):
F80; => Forward arrow button is touched
B80; => Backward arrow button is touched
R80; => Right arrow button is touched
L80; => Left arrow button is touched
S0; => No button is touched

PIC PROGRAMMING HIGHLIGHT
From the data above, we can decide to move the robot to which direction.

[code lang=”c” highlight=””]inByte = uartReceive();
if(inByte == ‘F’) // Forward
{ // Read dummy byte
uartReceive(); // 8
uartReceive(); // 0
uartReceive(); // ;
motor(80, 80); // Robot move forward
}

else if(inByte == ‘B’) // Backward
{ // Read dummy byte
uartReceive(); // 8
uartReceive(); // 0
uartReceive(); //
motor(-80, -80); // Robot move backward
}

else if(inByte == ‘R’) // Right
{// Read dummy byte
uartReceive(); // 8
uartReceive(); // 0
uartReceive(); //
motor(80, -80); // Robot turn right
}

else if(inByte == ‘L’) // Left
{// Read dummy byte
uartReceive(); // 8
uartReceive(); // 0
uartReceive(); //
motor(-80, 80); // Robot turn left
}

else if(inByte == ‘S’) // Stop
{// Read dummy byte
uartReceive(); // 0
uartReceive(); //
motor(0, 0); // Robot stop
}
[/code]


Remote Mobile Robot with XBee-WiFi (Android) source code (download).

VIDEO
[youtube]http://www.youtube.com/watch?v=AEEKJEQD-mw[/youtube]

Buy

8 thoughts on “Remote Mobile Robot with XBee-WiFi (Android)

  1. Hello,

    Congratulations!

    Please how many simultaneous connections are supported for xbee wifi?

    I would like a lamp control circuit of my house, but I have a brother and he also wants to control.

    Thanks!

  2. How to transfer program to PIC16F887?

    Am I just download the MPLAB X IDE V2.00 + XC8 V1.30 ?

    I already purchased all HARDWARE ( Educational Mobile Robot 2.0 (EDUBOT2))
    1. MC40A (link).
    2. UIC00B – Programmer (link).
    3. SPG10-150K (link).
    4. Motor Bracket (link).
    5. Castor (link).
    6. Battery (link).
    7. Xbee WiFi (link).
    8. Xbee Starter Kit Without Module (link).
    9. USB Mini Cable (link).

    My Xbee wifi working as well like your picture.
    F80; => Forward arrow button is touched
    B80; => Backward arrow button is touched
    R80; => Right arrow button is touched
    L80; => Left arrow button is touched
    S0; => No button is touched

    The things is my car doesn’t move.

    Am I just download your source code and upload?

  3. Check the User’s Manual of MC40A, it is the controller board of the robot. UIC00B User’s Manual also worth checking. All the User’s Manual can be found under the “Attachment” tab of particular product page.

  4. Hello all…how to make connection for smartliving such as I want to On the lamp in my house using my android phone..I need to setting like this or not ..are we need 2 xbee module for the wireless smartliving…please help me ..now im taking final year project.

Leave a Reply

Your email address will not be published. Required fields are marked *