mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2024-12-28 09:58:30 +01:00
Update BT code to advertise and search sdp records and use psm reported to work with new Palm
code. Get rid of pthreads dependency which was for logging only.
This commit is contained in:
parent
41936fe18a
commit
de640cda98
3 changed files with 6 additions and 6 deletions
|
@ -101,7 +101,7 @@ OBJ = $(PLATFORM)/linuxmain.o \
|
|||
|
||||
# $(PLATFORM)/linuxcommpipe.o \
|
||||
|
||||
LIBS = -pthread -lm -lmcheck -L $(HOME)/usr/local/pilot/lib $(GPROFFLAG)
|
||||
LIBS = -lm -lmcheck -L $(HOME)/usr/local/pilot/lib $(GPROFFLAG)
|
||||
ifdef BLUETOOTH
|
||||
LIBS += -lbluetooth
|
||||
endif
|
||||
|
|
|
@ -124,7 +124,7 @@ lbt_connectSocket( LinBtStuff* btStuff, const CommsAddrRec* addrP )
|
|||
|
||||
// set the connection parameters (who to connect to)
|
||||
saddr.l2_family = AF_BLUETOOTH;
|
||||
saddr.l2_psm = htobs( XW_PSM );
|
||||
saddr.l2_psm = htobs( XW_PSM ); /* need to get this psm via uuid lookup */
|
||||
XP_MEMCPY( &saddr.l2_bdaddr, &addrP->u.bt.btAddr,
|
||||
sizeof(saddr.l2_bdaddr) );
|
||||
// connect to server
|
||||
|
@ -181,7 +181,7 @@ lbt_listenerSetup( CommonGlobals* globals )
|
|||
XP_MEMSET( &saddr, 0, sizeof(saddr) );
|
||||
saddr.l2_family = AF_BLUETOOTH;
|
||||
saddr.l2_bdaddr = *BDADDR_ANY;
|
||||
saddr.l2_psm = htobs( XW_PSM );
|
||||
saddr.l2_psm = htobs( XW_PSM ); /* need to associate uuid with this before opening? */
|
||||
bind( listener, (struct sockaddr *)&saddr, sizeof(saddr) );
|
||||
|
||||
listen( listener, MAX_CLIENTS );
|
||||
|
|
|
@ -37,7 +37,7 @@
|
|||
# include <bluetooth/hci_lib.h>
|
||||
#endif
|
||||
|
||||
#include <pthread.h>
|
||||
/* #include <pthread.h> */
|
||||
|
||||
#include "linuxmain.h"
|
||||
#include "linuxbt.h"
|
||||
|
@ -69,12 +69,12 @@ linux_debugf( char* format, ... )
|
|||
struct tm* timp;
|
||||
struct timeval tv;
|
||||
struct timezone tz;
|
||||
pthread_t me = pthread_self();
|
||||
/* pthread_t me = pthread_self(); */
|
||||
|
||||
gettimeofday( &tv, &tz );
|
||||
timp = localtime( &tv.tv_sec );
|
||||
|
||||
sprintf( buf, "<%p>%d:%d:%d: ", (void*)me,
|
||||
sprintf( buf, /* "<%p>" */ "%d:%d:%d: ", /* (void*)me, */
|
||||
timp->tm_hour, timp->tm_min, timp->tm_sec );
|
||||
|
||||
va_start(ap, format);
|
||||
|
|
Loading…
Reference in a new issue