Sunday, 10 June 2012

Computer Controlled Wireless Robot

The main objective of this project is to design a robot that can be controlled wirelessly from a computer serial port.



It consists of 2 modules

1. Transmitter


The transmitter consists of 8051 module with a serial port and interfaced to a RF Transmitter module. The microcontroller reads the commands sent by the computer from the serial port, interprets for the direction of the robot and sends the command to RF Transmitter and an acknowledgement back to Computer. We have commands such as "Left" - L, "Right" - R, "Forward" - F, "Reverse" - B, "Stop" - S.

For example, if a code "R" is sent from the Computer serial port the microntroller sends "0x01" to RF Transmitter and a string "Right" back to the computer indicating the direction the robot is going to move.

To Interface 8051 with RF Transmitter, we use a Encoder IC HT12E. A0 to A9 on HT12E represents the address and we have it set to 0x00. Data pins D3 to D0 on the encoder is interfaced with P1.0 to P1.3 of 8051. TE pin of encoder is "Transmission Enable" which enables  transmission of data only when it is "Active Low". In our case, the transmission enable is controlled programatically with P1.4 of 8051. The complete circuit is below.


8051 Microcontroller interface with RF Transmitter HT12E
8051 Interfacing with RF Transmitter and Encoder HT12E

2. Receiver


The 8051 interprets the commands received by RF receiver and sends appropriate signals to H- Bridge for the control of the robot.

The receiver consists of

a. RF Receiver
b. Decoder Chip HT12D
c. 8051
d. H-Bridge L293D
e. DC motors.

To Interface 8051 with RF Receiver, we use a DecoderIC HT12D. A0 to A9 is complementary to Address set on Encoder and hence it is 0x00. Data pins D3 t0 D0 are interfaced to pins P1.0 to P1.3 of 8051. Whenever data is received, Pin 17 of the decoder goes high. We use a switching transistor to invert it to "Active Low" to enable us to interface it with "Active Low" INTO Interrupt of 8051. So whenever data is received, INT0 is triggered. The microntroller reads the data from the P1.0 to P1.3 and sends appropriate signals to H-Bridge via P0.0 to P0.3 to control the motors.


8051 Microcontroller Interface with RF Receiver HT12D
8051 Interface with RF Receiver and RF Decoder HT12D

91 comments:

  1. Please give/send source code and GUI/PC interface application through which commands to be sent.

    dixitad88@gmail.com

    Thank You.

    ReplyDelete
    Replies
    1. Well, the source code is not difficult and it solely depends on the design. On the Tx side, just capture what the computer sends from a serial port using serial interrupt, interpret and pass it on to RF Tx. On the Rx side in an infinite loop, just take what is sent and control the motors. Since there are 4 bits available we have used 0x0001, 0x0010, 0x0100, 0x1000 for Left, Right, Forward, Reverse and others as stop.

      And to send the signals from the computer, we just use "Tera Term" in Windows 7.

      Delete
    2. Hii i am using bray's terminal , i do not have tera term will this cause any problem ???

      Delete
    3. Sorry no idea about Bray's terminal.

      Delete
    4. sir can u send me the all program and source code on my e-mail id....it will be great help for me .....
      id-amitbhardwaj21@gmail.com

      Delete
    5. is it compulsory to use encoder decoder pair?i think if you connect the transmitter at TxD and receiver at RxD then data can be transmitted serially.am i correct?

      Delete
  2. Can i get the source code of receiver? i am not getting how to write the code. please send me the code.

    harari.arihant@gmail.com

    Thank you

    ReplyDelete
    Replies
    1. Well, it is pretty straightforward. When data is recieved, pin 17 of HT12D goes high. It is inverted using transistor and connected to INT0 of microcontroller. In the ISR, you can jsut read the 4bits of P1 and control the DC motors accordingly. Anyways, sent the code to your email.

      Delete
    2. it would be great if you can send the source code to my mail id: nirdosh409@gmail.com
      thanks in advance

      Delete
    3. plz i also want the code to control dc motors using rf module (rf receiver/rf transmitter) for 8051 microcontroller at baljitajji@gmail.com

      Delete
    4. Could you send the code and any BASCOM51 example you may have in my email vedati44@hotmail.com. Thanks

      Delete
  3. plz all code and all information to my mail xx11oo@windowslive.com

    ReplyDelete
  4. can i have the code please......
    bhardwajdin@gmail.com

    ReplyDelete
    Replies
    1. Plz send the Transmitter and Reciever Code to me, my Mail ID is youther.biswas8@gmail.com. Also, say, we have connected the output to drive relays at the Reciever side for controlling appliances, and say if there are multiple boards..then it requires some address to be set for each of the board pairs of Tx and Rx, so tht they do not interfere with each other...Wht do u think..?

      Delete
    2. A0 to A8 are the address bits in both Tx and Rx. In this case all are grounded so the Address is set to 0x00. You can program to Tx and Rx to set to different Addresses and control different devices accordingly.

      Code sent to you email.

      Delete
    3. plz give me the code sarvesh.ssv@gmail.com plzzzzz

      Delete
  5. dude....what is the use of encoder and decoder here ? i can send serial data from computer to microcontroller serial input directly (UART)....there i can make it parallel using simple coding techniques at transmitter side 8051 ......in the same way at receiver side....

    ReplyDelete
    Replies
    1. I tried that initially, it just didn't work. Should work in theory though

      Delete
  6. Good job Sir ,plz all code and all information to my e-mail post4jml@gmail.com

    ReplyDelete
  7. plase can you send the code at my id ayush3447@yahoo.in?

    ReplyDelete
  8. good job man,can you send me source codes and schematics? nr.selcuk@gmail.com

    ReplyDelete
  9. sir pls send me coding at sandeshjain.seetu@gmail.com
    and tnx sir for explaning the working in pretty lucid way

    ReplyDelete
  10. can i have all the codes please sir

    ReplyDelete
  11. Replies
    1. As I know we do not get ardunio board with inbuilt interface to Computer Serial port via Max232. You have to interface it externally. Instead 8051 is simpler.

      And writing code for ardunio is straight forward, just send commands to Ardunio ports interfaced to data bits of RF Transmitter and decode them at the receiver.

      Delete
  12. sunnytronics.raj0@gmail.com plzzzz send me the code

    ReplyDelete
  13. plz send me the source code.my id is vinaykumarsannala@gmail.com,tejazenic@gmail.com

    ReplyDelete
  14. Kindly send me the source code for both sender and receicer side ..my mail id id sta3008@gmail.com..Thanks

    ReplyDelete
  15. Sir,
    i have designed the whole project but i have no source code,,
    plz, send me the source code for both sender and receiver
    my id is --
    Sharma.gaurav899@gmail.com

    ReplyDelete
  16. Hi please send me source code prakanaveen@gmail.com

    ReplyDelete
  17. Kindly send me the source code for both sender and receicer side. my mail id :prakanaveen@gmail.com

    ReplyDelete
  18. good one sir .pls all source code and program send my mail.manojsinh1992@gmail.com

    ReplyDelete
  19. sir can u send me the all program and source code on my e-mail id....it will be great help for me .....
    id- birendra.etce2011@gmail.com

    ReplyDelete
  20. pls seend me the source code for both tx and rx side ....my id is parthibanmv93@gmail.com

    ReplyDelete
  21. Iam helping my friend please send me the tx and rx side code my email id is venki.patil0@gmail.com

    ReplyDelete
  22. can I please get the code at alias047020@gmail.com. Thanks

    ReplyDelete
  23. Hi can i get the code of above project , my email id is deep0177@gmail.com

    ReplyDelete
  24. plz can i get the code in embedded c to control dc motore using rf module 434mhz in 8051 microcontroller ,mu id is baljitajji@gmail.com

    ReplyDelete
    Replies
    1. sir can u send the circuit diagram also

      Delete
    2. is rf module connected with pc or any seriall communication is done..... actually i want wireless communication via rf module......so send me the code for dat

      Delete
    3. Circuit diagram is in the blog post. Check it out. Data is sent from PC -> 8051 -> RF Tx in the Tx side and at the Rx it is RF Rx -> 8051 -> DC motors. You can remove the PC and program the 8051 itself on the Tx side to send the data.

      Delete
    4. yes is dere any way to check the communication between rf modules.... dat whether data is transferring btween dem or not

      Delete
    5. As you see in the blog post, Pin 17 of HT12D receiver decoder switches state when data is received. You can use it as an indicator by connecting an LED to the same...

      Delete
  25. sir could u send me the c code for interfacing rf module at the receiver side ?? and how is the transmitter section interfaced with computer ???my id id rockcontinues@gmail.com

    ReplyDelete
    Replies
    1. Code sent to your email. Interfacing between 8051 and computer serial port is via Max232 IC. We can get circuit boards that have connections ready..

      Delete
  26. it would be great if you can send the source code to my mail id: ashwinkulkarni2511@gmail.com
    thanks in advance

    ReplyDelete
  27. sir could you please send me the schematic circuit diagram for wireless robot using rf module

    ReplyDelete
  28. my id is ashuthakur116@gmail.com

    ReplyDelete
  29. Sir please send schematic circuit diagram and source code email id:nishanthbhat.91194@gmail.com Thanks in advance

    ReplyDelete
    Replies
    1. Code sent. circuit diagram is in the blog itself.

      Delete
  30. Hi, can send source code at theranger@crapmail.org . Thank you very much.

    ReplyDelete
  31. Please send me the code coolsa5m@gmail.com

    ReplyDelete
  32. Please send me the codes
    joshiamogh7@yahoo.in

    ReplyDelete
  33. is it compulsory to use encoder decoder pair?i think if you connect the transmitter at TxD and receiver at RxD then data can be transmitted serially.am i correct?

    ReplyDelete
    Replies
    1. Theoretically no..but without encoder / decoder the circuit did not work for me..

      Delete
  34. plz send me the source code.my id is satish.sadashiv@yahoo.in

    ReplyDelete
  35. Bravos ! Verry good job ! Pls. send me the code at : viorel_172000@yahoo.com. Thank you .

    ReplyDelete
  36. please send the source code at saikanamy2j@gmail.com thanks in advance!

    ReplyDelete
  37. Hi, can i have the source code? pls send to garykhl92@gmail.com thanks

    ReplyDelete
  38. hai admin, at present iam working on this project so it will help me a lot so
    plzzz send the source for both trx and rx section
    and send all the reuired information to my email: kesavakrishna416@gmail.com

    ReplyDelete
  39. plz send me source code and layout on amrutapawar1197@gmail.com

    ReplyDelete
  40. Respect and I have a swell offer: Full House Reno old home renovation

    ReplyDelete