/*ProfiPacket - packet radio terminal program
  Copyright (C) 1999  Alexander Feigl

  This program is free software; you can redistribute it and/or modify
  it under the terms of the GNU General Public License as published by
  the Free Software Foundation; either version 2 of the License, or
  (at your option) any later version.

  This program is distributed in the hope that it will be useful,
  but WITHOUT ANY WARRANTY; without even the implied warranty of
  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  GNU General Public License for more details.

  You should have received a copy of the GNU General Public License
  along with this program; if not, write to the Free Software
  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA

  Author:

  Alexander Feigl
  Burachstraße 51

  D-88250 Weingarten

  Mail : Alexander.Feigl@gmx.de
*/

#define FILEFORMAT_AUTOBINARY      0
#define FILEFORMAT_BINARY          1
#define FILEFORMAT_7PLUS           2
#define FILEFORMAT_TEXT            3
#define FILEFORMAT_TEXTAMIGA       4

#define LFTYPE_LF                  0
#define LFTYPE_CRLF                1
#define LFTYPE_CR                  2
 

#define TRANSERROR_NOTCONNECTED    1
#define TRANSERROR_ALREADYTRANSFER 2
#define TRANSERROR_NOTFOUND        3
#define TRANSERROR_NOSERVER        4
#define TRANSERROR_CANNOTWRITE     5

struct FileInfo
 {
  unsigned char callsign[16];          /* callsign of owner of this file*/
  unsigned long filesize;              /* size of this file */
  int           fileformat;            /* file format see above */
  int           badcrc;                /* file has bad CRC */
  int           incomplete;            /* file is incomplete */
  int           guessedformat;         /* file format is guessed */
  int           lftype;                /* line feed type */
 };
 
 
int StartFiletransfer(int channel,int filetype,const unsigned char *filename);
int StartFilereceive(int channel,int filetype,const unsigned char *filename);

void PresetFileInfo(struct FileInfo *finfo);

int GetFileInfo(const unsigned char *filename,struct FileInfo *finfo);

int SetFileInfo(const unsigned char *filename,struct FileInfo *finfo);
