求各位大神帮忙,小弟万谢不辞啊!
时间:10-02
整理:3721RD
点击:
用的是从网上下载的一个国嵌视频里用的2440TIMER程序,可是运行的时候总是有错误!谢谢大神帮忙看看!
设置时钟
switch (m)
{
case 0:
HCLK = FCLK ; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 133
break;
case 1:
HCLK = FCLK>>1; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 136
break;
case 2:
if(s&2)
HCLK = FCLK>>3; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 140
else
HCLK = FCLK>>2 ;Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 142
break;
case 3:
if(s&1)
HCLK = FCLK/6; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 146
else
HCLK = FCLK/3; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 148
break;
}
if(p)
PCLK = HCLK>>1;
else
PCLK = HCLK;
if(s&0x10)
cpu_freq = HCLK;
else
cpu_freq = FCLK;
val = rUPLLCON;
m = (val>>12)&0xff;
p = (val>>4)&0x3f;
s = val&3;
UPLL = ((m+8)*FIN)/((p+2)*(1<<s));
UCLK = (rCLKdivN&8)?(UPLL>>1):UPLL;Error : (Serious) C2953E: Illegal in the context of an l-value: <integer constant>wenkle_CLK.c line 167
跪求大神解答啊,小弟刚入学2440,有点菜鸟!
设置时钟
switch (m)
{
case 0:
HCLK = FCLK ; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 133
break;
case 1:
HCLK = FCLK>>1; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 136
break;
case 2:
if(s&2)
HCLK = FCLK>>3; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 140
else
HCLK = FCLK>>2 ;Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 142
break;
case 3:
if(s&1)
HCLK = FCLK/6; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 146
else
HCLK = FCLK/3; Error : (Serious) C2953E: Illegal in the context of an l-value: '/'wenkle_CLK.c line 148
break;
}
if(p)
PCLK = HCLK>>1;
else
PCLK = HCLK;
if(s&0x10)
cpu_freq = HCLK;
else
cpu_freq = FCLK;
val = rUPLLCON;
m = (val>>12)&0xff;
p = (val>>4)&0x3f;
s = val&3;
UPLL = ((m+8)*FIN)/((p+2)*(1<<s));
UCLK = (rCLKdivN&8)?(UPLL>>1):UPLL;Error : (Serious) C2953E: Illegal in the context of an l-value: <integer constant>wenkle_CLK.c line 167
跪求大神解答啊,小弟刚入学2440,有点菜鸟!
Error 相关文章: