Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Help! Data received by PIC through ZigBee contains Error

Status
Not open for further replies.

stalk3r21

New Member
Hey, I am using interrupt which will take the incoming data and store it into the buffer and after the end of incoming data character is received (which is a '[' for now), then it will burn the data from the buffer to the EEPROM.
However, I am receiving the wrong set of data, for example, the Data that i send from the PC is, ABCDEFGHIJ in ASCII, I'm supposed to receive 41h,42h,43h,44h,45h,46h,47h,48h,49h,50h but instead of that I'm receiving A1h,A2h,A3h,A4h,A5h,A6h,A7h,A0h,A1h,A2h.

What you think is the problem? I've check the baud rates and the configurations 8N1. Could it be that my PC is sending bits faster than my PIC is taking in? I'm using ZigBee wireless module for the data transmission from PC to PIC.

Please Help! I've attached the codings for the Program
 

Attachments

  • MustWork.asm
    5.3 KB · Views: 125
Divide your problem down into easily verified chunks...
For example, slow your data rate right down and watch it on a scope or a pair of LED's etc, make sure that you are actually receiving what you think you are supposed to be receiving...Manually set a value to place in the e2prom and read it back, is it what you expected etc...

You should quickly identify which area is causing you trouble, which will allow you to focus in on it.

rgds
 
Hey,
In my program I've written to check whether data is received or not and increment PORTA by one for each receive. Plus the EEPROM part is all okay, tested it out on my main program. Now is just left with the receiving part from ZigBee to PIC. That part is having error. Will try changing the baud rate and checking it as you've adviced. Thanks
 
Status
Not open for further replies.

Latest threads

Back
Top