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 when Using File Function

I use uVision3 V3.30a Philips LPC2294.
When I run program with File Handle I can't link it.
Such as I use fopen , fclose , fpprintf , f... ,when I build program it has errors.

This is my program.

#include <ARTX.h>
#include <LPC22xx.H>
#include <stdio.h>
#include <ARTX_Config.h>

void init_serial(void){
/* initialize the serial interface */
PINSEL0 = 0x00050005; /* Enable RxD1 and TxD1 */
U0LCR = 0x83; /* 8 bits, no Parity, 1 Stop bit */
U0DLL = 97; /* 9600 Baud Rate @ 15MHz VPB Clock */
U0LCR = 0x03; /* DLAB = 0 */
}

unsigned char mempool[0x100000];

int main(void)
{
FILE *out;
init_mempool(mempool,sizeof(mempool));
init_serial();

if(!(out=fopen("testfile.txt","r")))
{
printf("Error: Cannot open output file!\n");
return 1;
}
fclose(out);
return 0;
}


In the Linking time ,it show me the errors...

*** WARNING L23: UNRESOLVED EXTERNAL SYMBOLS
*** ERROR L128: REFERENCE MADE TO UNRESOLVED EXTERNAL
SYMBOL: fopen?T
ADDRESS: 00000222H
*** ERROR L128: REFERENCE MADE TO UNRESOLVED EXTERNAL
SYMBOL: fclose?T
ADDRESS: 0000023EH

I can't run it although i include ARTX.h

0