Per the BTL test cases for 14.1.7, 14.1.x1, and 14.1.8, the device should respond back with an original-broadcast-npdu for a Forward-NPDU and an Original-Broadcast-NPDU; this makes this so for BACnet/IP.
Minor fixes for build errors and warnings.
This commit is contained in:
@@ -328,7 +328,7 @@ int main(
|
||||
dlenv_maintenance_timer(elapsed_seconds);
|
||||
Load_Control_State_Machine_Handler();
|
||||
elapsed_milliseconds = elapsed_seconds * 1000;
|
||||
handler_cov_task(elapsed_seconds);
|
||||
handler_cov_task();
|
||||
tsm_timer_milliseconds(elapsed_milliseconds);
|
||||
}
|
||||
/* output */
|
||||
|
||||
@@ -43,6 +43,10 @@
|
||||
#if PRINT_ENABLED
|
||||
#include <stdio.h>
|
||||
#endif
|
||||
#if defined(BACDL_BIP)
|
||||
#include "bvlc.h"
|
||||
#endif
|
||||
|
||||
|
||||
/** @file h_routed_npdu.c Handles messages at the NPDU level of the BACnet stack,
|
||||
* including routing and network control messages. */
|
||||
|
||||
@@ -170,6 +170,7 @@ int bip_send_pdu(
|
||||
/* addr and port in host format */
|
||||
struct in_addr address;
|
||||
uint16_t port = 0;
|
||||
BACNET_BVLC_FUNCTION function;
|
||||
|
||||
|
||||
(void) npdu_data;
|
||||
@@ -179,7 +180,10 @@ int bip_send_pdu(
|
||||
|
||||
mtu[0] = BVLL_TYPE_BACNET_IP;
|
||||
bip_dest.sin_family = AF_INET;
|
||||
if (dest->net == BACNET_BROADCAST_NETWORK) {
|
||||
function = bvlc_get_function_code(); /* What type of BVLC was it? */
|
||||
if ( (dest->net == BACNET_BROADCAST_NETWORK) ||
|
||||
(function == BVLC_FORWARDED_NPDU) ||
|
||||
(function == BVLC_ORIGINAL_BROADCAST_NPDU) ) {
|
||||
/* broadcast */
|
||||
address.s_addr = BIP_Broadcast_Address.s_addr;
|
||||
port = BIP_Port;
|
||||
|
||||
Reference in New Issue
Block a user