[ZLG-MCU] TKSmonitor51的问题

[复制链接]
 楼主| linhai1986 发表于 2009-9-24 11:39 | 显示全部楼层 |阅读模式
单片机实验箱用的是ZLG的.用TKSmonitor51仿真器.在进行如下程序实验时:
#include <reg52.h>
#include <intrins.h>
#include <absacc.h>
typedef unsigned char uchar;
typedef unsigned int uint;
uchar key;
bit keyflag;
bit testioflag;
sbit P10=P1^0;
sbit P32=P3^2;
void init();
void main(void)
{
init();
P10=0;
while(1)
{
if (keyflag)
{
P10=~P10;
testioflag=1;
}
if (testioflag)
{
if (P32)
{
P10=~P10;
testioflag=0;
}
}
}
}
///////////
void init()
{
EA=1;
IE1=0;
EX1=1;
EX0=1;
IT0=1;
IT1=1;
}
///////////
void Int0() interrupt 0 //using 0
{
keyflag=1;
}

在调试时出现MONITOR ERROR 22: NO CODE MEMORY AT ADDRESS 0001H 错误,
然后就不能调试了.
不知道是什么原因.
我仿真地址应该设对的.
code momery:0x8000 0x4000
xdata memoery: 0xc000 0x4000
中断地址设为:0x8000
不知道哪里错了.请教
xiaoxin1986 发表于 2009-9-24 11:42 | 显示全部楼层
调试前先下载MON51监控程序。
xiaoxin1986 发表于 2009-9-24 11:43 | 显示全部楼层
还有:解决这种问题可以新建一个工程再试一下,因为有的时候,不小心改了工程某些设置,但是自己并不知晓。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

172

主题

1451

帖子

0

粉丝
快速回复 在线客服 返回列表 返回顶部