I am testing a routine with serial interrupt and I notice that the value is not transferred from SBUF. I notice this in uVison debug. What's happen? Please help me. follow my parcial intr routine
if(RI) { c = SBUF; //<-- here is my problems RI = 0; if (istart + ILEN != iend) { inbuf[iend++ & (ILEN-1)] = c; } }
I am 83.42% certain that the problem here is not understanding that SBUF is not one buffer. That is why I refer to "the bible" Erik
If you do this //code up to here //c=SBUF; c = iend; //rest of code what does your buffer look like after execution? does it make sense? If you run the simulator then execute this command SIN = 0xAA then stop what does your buffer look like?
here are the links to "the bible" Chapter 1 http://www.semiconductors.philips.com/acrobat/various/80C51_FAM_ARCH_1.pdf chapter 2 http://www.semiconductors.philips.com/acrobat/various/80C51_FAM_PROG_GUIDE_1.pdf chapter 3 http://www.semiconductors.philips.com/acrobat/various/80C51_FAM_HARDWARE_1.pdf
i am facing the same problem. is there any one to help us. How can you be helped with a problem that does not exist? q = SBUF; WILL move SBUF into q, there is no way around it. If there is nothing in SBUF, then, of course nothing get moved into q. Is it possible that you are confusing the output and input sections of SBUF, if so, you better read up on it in "the bible" Erik
Yes Mr. Schdmit i am facing the same problem. is there any one to help us.
Hi, Jon I notice within uVision2 debug. tks
I notice that the value is not transferred from SBUF How do you notice this? Jon
c = SBUF; //<-- here is my problems if this statement do not copy SBUF into c your hardware is faulty. I believe you do not have anything in SBUF Erik
View all questions in Keil forum