
------------------------------------------------------------------------------
12. Change name of a file on FCA device. <Main,Alarm,Comm>
------------------------------------------------------------------------------
[Name]
fca_rename
[Syntax]
#include <bios.h>
int fca_rename( char *oldname, char *newname ) ;
[Argument]
oldname Old file name. (max. 17 characters)
newname New file name. (max. 17 characters)
[Return]
Returns zero if successful. Returns -1 if any error occurrs.
[Description]
This function changes the name of the file in the FCA devices.
[Example]
Following sample program changes the name of the specified file in the
device connected to the first channel.
#include <stdio.h>
#include <crt.h>
#include <data.h>
#include <bios.h>
int example( void )
{
ser_t r_para ;
char oldname[18], newname[18], steetas[2] ;
int ret, c ;
r_para.baud = BAUD_4800 ;
r_para.stop_bit = STOP_2 ;
r_para.parity = PARITY_N ;
r_para.data_bit = DATA_8 ;
r_para.hardflow = 2 ;
r_para.dc_enable = 3 ;
r_para.dc_put = 0 ;
r_para.dc1_code = 0x11 ;
r_para.dc2_code = 0x12 ;
r_para.dc3_code = 0x93 ;
r_para.dc4_code = 0x14 ;