今天把这个宝贝拿出来了,可是发现还是有问题
/* THIS SAMPLE CODE IS PROVIDED AS IS AND IS SUBJECT TO ALTERATIONS. FUJITSU */
/* MICROELECTRONICS ACCEPTS NO RESPONSIBILITY OR LIABILITY FOR ANY ERRORS OR */
/* ELIGIBILITY FOR ANY PURPOSES. */
/* (C) Fujitsu Microelectronics (Shanghai) Co., LTD. */
/* Date:20080320 Version:1V0 Author:Levi */
/* ------------------------------------------------------------------------- */
/******************************************************************************
NAME: main.c
FUNCTION: Give a example for IO as a digital input or output
******************************************************************************/
#include "mb95200.h"
/******************************************************************************
NAME: Init();
FUNCTION: initial I/O Port as digital input or output
******************************************************************************/
void Init (void)
{
PDR0_P00 = 1;
DDR0_P00 = 1; // set P0_P00 output
PDR0_P01 = 0;
AIDRL_P01 = 1; // disable AN1 input
DDR0_P01 = 0; // set P0_P01 input
PDR6_P62 = 1;
DDR6_P62 = 1; // set P6_P62 output
PDR6_P63 = 0;
DDR6_P63 = 0; // set P6_P63 input
}
/******************************************************************************
NAME: delay();
FUNCTION: delay time;
*******************************************************************************/
/*void Delay(unsigned int i)
{
unsigned int m,n;
for(m=0;m<i;m++)
{
for(n=0;n<6000;n++)
{
asm("\tNOP");
}
}
}
*/
/******************************************************************************
NAME: main ();
FUNCTION: main loop
******************************************************************************/
void main (void)
{
Init ();
while(1);
{
PDR6_P62=1;(这句话不添加进去就编译没错,可只要一加进去就显示警告!是什么问题谁能帮我解决一下啊!)
}
}
错误信息是
Now Compile/Assemble...
--------------------Configuration: Digital_IO.prj - Debug--------------------
main.c
*** n:\¸»Ê¿mcu\program\test\digital_io\src\main.c(58) W1025C: statement not reached
------------------------------
Warning detected.
------------------------------