GPS4Palm

Source Code Documentation


Serial.h

Go to the documentation of this file.
00001 /*****************************************************************************
00002  *
00003  * $RCSfile: Serial_8h-source.html,v $
00004  *
00005  * GPS4Palm Serial Manager API Wrapper Functions -
00006  *   either the new or the old API is used
00007  *
00008  * Based on the example "GPS" from the book
00009  * "Palm Programming, the Developer's Guide, 2nd edition"
00010  * by O'Reilly.
00011  * (Copyright (c) 1998-2001, Neil Rhodes and Julie McKeehan  neil@pobox.com)
00012  *
00013  * This program is Copyright (C) 03/2003 Matthias Prinke
00014  * <matthias.prinke@surfeu.de> and covered by GNU's GPL.
00015  * In particular, this program is free software and comes WITHOUT
00016  * ANY WARRANTY.
00017  *
00018  * $Author: mp $
00019  *
00020  * $Date: 2007-10-08 20:40:34 $
00021  *
00022  * $Revision: 1.7.2.1 $
00023  *
00024  * $Log: Serial_8h-source.html,v $
00024  * Revision 1.7.2.1  2007-10-08 20:40:34  mp
00024  * updated for gps4palm V0.9.5 beta
00024  *
00025  * Revision 1.4  2005-05-06 13:33:23  mp
00026  * added BluetoothOpen()
00027  *
00028  * Revision 1.3  2005/01/30 21:23:42  mp
00029  * added FreeCncProfileList() and gCncManagerFtr
00030  *
00031  * Revision 1.2  2004/04/17 12:44:30  mp
00032  * added kBaudRate
00033  *
00034  * Revision 1.1.1.1  2003/07/14 18:59:29  mp
00035  * Imported GPS4Palm to CVS revision control.
00036  *
00037  *
00038  ****************************************************************************/
00039 #ifndef SERIAL_H
00040 #define SERIAL_H
00041 
00042 #define kBaudRate       4800
00043 
00044 extern Boolean  gNewSerialManager;
00045 extern Boolean  gCncManagerFtr;
00046 extern UInt16   gPortID;
00047 extern char     gSerialBuffer[900];
00048 
00049 UInt32 DoReceive(UInt16 portId, void *rcvBufP, UInt32 count, Int32 timeout, 
00050                   Err *errP);
00051 
00052 Err DoSetReceiveBuffer(UInt16 portId, void *bufP, UInt16 bufSize);
00053 
00054 Err DoReceiveWait(UInt16 portId, UInt32 bytes, Int32 timeout);
00055 
00056 Err DoReceiveFlush(UInt16 portId, Int32 timeout);
00057 
00058 Err DoReceiveCheck(UInt16 portId,  UInt32 *numBytesP);
00059 
00060 Err DoClose(UInt16 portId);
00061 
00062 void FreeCncProfileList(void);
00063 
00064 Err BluetoothOpen(UInt32 port, UInt32 baud, UInt8 *bt_addr, UInt16 *PortID);
00065 
00066 #endif

Created: Mon, 08 Oct 2007 22:33:16 +0200
Copyright ©2004 M. Prinke