/*****************************************************************************/
/* term.h								     */
/*	global variable, function and define for term subdirectory	     */
/*									     */
/* This is the linux Communication Test Program for Advantech PCL card
 *
 * This file is part of pclterm
 * copyright (c)2000 ,ADVANTECH Co,Ltd
 *
 * pclterm is free software;you can redistribute it and/or modify it
 * under the terms of version 2 of GNU General Public License as
 * published by the Free Software Foundation.
*/
/*****************************************************************************/

/*****************************************************************************/
/* global define value							     */
/*****************************************************************************/
#ifndef _TERM_H
#define _TERM_H

#include        "../pclwinlib/win.h"
#include        "../pcllib/declare.h"

#ifndef B921600
#define B921600 (B460800+1)
#endif

#define HIGH_SPEED_ITEM 20
#define NORM_SPEED_ITEM 17

struct dterm_info {
	char	dname[20];
	uchar	rate;
	uchar	parity;
	uchar	databit;
	uchar	stopbit;
	uchar	xflow;
	uchar	lecho;
	uchar	senter;
	uchar	dmode;
};

/*****************************************************************************/
/* extern global variable 						     */
/*****************************************************************************/
extern	struct	WItem		AbleMenuItem[];
extern	struct	WSelect 	AbleMenu;
extern	struct	WItem		BaudRateMenuItem[];
extern	struct	WSelect		BaudRateMenu;
extern	struct	WItem		ParityMenuItem[];
extern	struct	WSelect		ParityMenu;
extern	struct	WItem		DataBitMenuItem[];
extern	struct	WSelect		DataBitMenu;
extern	struct	WItem		StopBitMenuItem[];
extern	struct	WSelect		StopBitMenu;
extern	struct	WItem		YesNoMenuItem[]; 
extern	struct	WSelect		YesNoMenu;
extern	struct	WItem		FlowMenuItem[];
extern	struct	WSelect		FlowMenu;
extern	struct	WItem		EnterMenuItem[];
extern	struct	WSelect		EnterMenu;
extern	struct	dterm_info	DTerm;
extern	int			SioFd;
extern long BaudMapTab[];

/*****************************************************************************/
/* external public function						     */
/*****************************************************************************/
extern	void	term_menu();

#endif
