From 5111b9fb4e80dd8ac502879ba3c4945c60361578 Mon Sep 17 00:00:00 2001 From: skarg Date: Fri, 18 May 2012 23:34:45 +0000 Subject: [PATCH] Modified code to clean up some compiler warnings. --- bacnet-stack/demo/handler/s_ptransfer.c | 2 +- bacnet-stack/include/bip.h | 4 +++- bacnet-stack/ports/win32/rs485.c | 7 +------ 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/bacnet-stack/demo/handler/s_ptransfer.c b/bacnet-stack/demo/handler/s_ptransfer.c index 577739b6..e608649b 100644 --- a/bacnet-stack/demo/handler/s_ptransfer.c +++ b/bacnet-stack/demo/handler/s_ptransfer.c @@ -97,7 +97,7 @@ uint8_t Send_Private_Transfer_Request( block->cMyByte2); len += encode_application_real(&pt_req_buffer[len], block->fMyReal); - characterstring_init_ansi(&bsTemp, block->sMyString); + characterstring_init_ansi(&bsTemp, (char *)block->sMyString); len += encode_application_character_string(&pt_req_buffer[len], &bsTemp); diff --git a/bacnet-stack/include/bip.h b/bacnet-stack/include/bip.h index beb85578..3990582e 100644 --- a/bacnet-stack/include/bip.h +++ b/bacnet-stack/include/bip.h @@ -43,11 +43,13 @@ extern bool BIP_Debug; extern "C" { #endif /* __cplusplus */ - /* note: define init and cleanup in your ports section */ + /* note: define init, set_interface, and cleanup in your port */ /* on Linux, ifname is eth0, ath0, arc0, and others. on Windows, ifname is the dotted ip address of the interface */ bool bip_init( char *ifname); + void bip_set_interface( + char *ifname); void bip_cleanup( void); diff --git a/bacnet-stack/ports/win32/rs485.c b/bacnet-stack/ports/win32/rs485.c index 4b4babcf..490ad68c 100644 --- a/bacnet-stack/ports/win32/rs485.c +++ b/bacnet-stack/ports/win32/rs485.c @@ -84,11 +84,6 @@ static DWORD RS485_DTRControl = DTR_CONTROL_DISABLE; RTS_CONTROL_ENABLE, RTS_CONTROL_DISABLE, RTS_CONTROL_HANDSHAKE, RTS_CONTROL_TOGGLE */ static DWORD RS485_RTSControl = RTS_CONTROL_DISABLE; -/* Ring buffer for incoming bytes, in order to speed up the receiving. */ -static FIFO_BUFFER Rx_FIFO; -/* buffer size needs to be a power of 2 */ -static uint8_t Rx_Buffer[1 << 12]; - /**************************************************************************** * DESCRIPTION: Change the characters in a string to uppercase @@ -382,7 +377,7 @@ bool RS485_Set_Baud_Rate( * are transmitting with 1 stop bit (some devices receive with * 1 stop bit but effectivly end up transmitting with 2 stop * bits, usually because of synchroisation issues in some UARTs - * which mean that if you wait until the serialiser has finished + * which mean that if you wait until the serialiser has finished * with the current character and then load the TX buffer it has * to wait until the next bit boundary to start transmitting. * PMcS