We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
hi,
i developed code for my project in AT89s52. complete code is working properly. now i need EEPROM,so i modified my code to AT89S8252. my external data getting modified. RAM test is ok. hard ware is ok. iam receiving data from PC through serial communication. storing same data into external memory. sending same data to PC. some of the data getting modified. plz help in this issue.
iam setting EEMEN to select EEPROM memory and deselect external memory. to strem line the problem eeprom access code removed still iam facing same problem.
Oh well, it's been working here for over a decade, but without seeing what you're doing, it's awfully hard to say what you might be doing wrong.
for (Loop=0;Loop<703;Loop++) { Data_Buffer[Loop] = 0x00; rxbuf[Loop]= 0x00; } Data_Buffer[Loop+1] = '\n'; rxbuf[Loop+1] = '\n'; for (Loop=0;Loop<703;Loop++) { if (Data_Buffer[Loop] != rxbuf[Loop]) { sprintf(dispstr,"rx:%02x Daddr:%x Ddata:%02x loop:% 02d\r\n",(int)rxbuf[Loop],(int)&Data_Buffer[Loop],(int)Data_Buffer[Loop],Loop); sendserial(); } } }
iam writing 0x00 in two buffers XDATA. but comparision is not same.
Your problem description is still quite vague. For starters, it lacks the definition of all those variables you're using.
but comparision is not same.
So how do they differ?
But here's a hint: it's rather unlikely that Loop+1 is the index you should be using after the first loop. Re-check the semantics of the for loop with your textbook to see why.
same code is working well with AT89S52.
"same code is working well with AT89S52."
With that descriptive answer we can finally determine all possible root causes. You will figure it out from here and further reply is unnecessary. The causes are some or all of the following: