This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Error during simulation

hi,

i have just started learning Keil simulation . I tried with simple programs and I tried the below one:

#include<reg51.h>
void main(void)
{ unsigned char z; for(z=0;z<100;z++) P1 = z;
}

while executing the simulation i am getting the following error:
*** error 65: access violation at C:0x6400 : no 'execute/read' permission

Kindly help me in getting rid of this error and that why is it coming in the first place. The code is very simple.

Thanks,
Vikas

Parents
  • Two things.

    1) Have you made sure your project specifies the correct memory regions.

    2) Where do you think your processor will go when it runs out of main()? There are no command line or GUI to return to if you try to "end" an embedded application. Always have an infinite loop at end of main().

    Another thing - the processor runs quickly. How will you be able to see the value of z on the port before the program have already ended?

Reply
  • Two things.

    1) Have you made sure your project specifies the correct memory regions.

    2) Where do you think your processor will go when it runs out of main()? There are no command line or GUI to return to if you try to "end" an embedded application. Always have an infinite loop at end of main().

    Another thing - the processor runs quickly. How will you be able to see the value of z on the port before the program have already ended?

Children