PIC16单片机的数组定义问题

2019-03-25 19:29发布

在PIC16F877中定义数组是不是有什么限制,比如说:定义一些数组没办法定义。例如:unsigned char temptex0[]={0x00,0x00,0x00,0x00,0x01,0x01,0x01,0x01,0x02,0x02,
0x02,0x02,0x03,0x03,0x03,0x03,0x04,0x04,0x04,0x04,0x05,0x05,0x05,0x06,0x06,0x06,0x07,0x07,0x07,0x08,0x08,0x08,0x09,
0x09,0x0a,0x0a,0x0b,0x0b,0x0c,0x0c};
unsigned char temptex1[]={0x0d,0x0d,0x0e,0x0e,0x0f,0x0f,0x0f,0x10,0x10,0x10,
0x11,0x11,0x12,0x12,0x12,0x13,0x13,0x14,0x14,0x14,0x15,0x15,0x15,0x16,0x16,0x16,0x17,0x17,0x18,0x18};
unsigned char temptex2[]={0x19,0x19,0x1a,0x1a,0x1b,0x1b,0x1c,0x1c,0x1c,
0x1d,0x1d,0x1d,0x1e,0x1e,0x1f,0x1f,0x20,0x20,0x21,0x21,0x22,0x22,0x23,0x23};
unsigned char temptex3[]={0x24,0x24,0x25,0x25,0x26,0x26,0x27,0x28,0x29,0x29,
0x2a,0x2a,0x2b,0x2b,0x2c,0x2d,0x2e,0x2f,0x30,0x32};
这种定义就不行。有时在定义的数组后面补上一个数,也不行,这是为什么?请大神解释一下。 此帖出自小平头技术问答
友情提示: 此问题已得到解决,问题已经关闭,关闭后问题禁止继续编辑,回答。
该问题目前已经被作者或者管理员关闭, 无法添加新回复
1条回答
yzjyh
1楼-- · 2019-03-25 22:43
注意下  bamk  的问题


我数了下你数组定义的字节,超出了一个体的RAM空间

一周热门 更多>