Make it possible to select multiple datalinks (#717)

* datalink/dlenv: Rename addr -> addr6 when ipv6

If we are building this file with BACDL_BIP6 and BACDL_BIP enabled we
get two definitions for addr. For this reason rename other addr6 so
there will be no conflict.

* config: Reorder MAX_APDU selection so biggest is first

When multiple datalinks are selected we should guess biggest MAX_APDU.
To do that we need to order selection based on biggest to lowest. With
this change MAX_APDU should be more correct most of the times and user
does not need to specifie that by hand.

* Make it possible to select multiple datalinks

Before we had option to select all datalinks. Many times you however do
not need all datalinks but just some. Change logic so that it does not
matter if user selects multiple datalinks. Now user just select what
they want and everything should just work.

* dlenv: Move variables start of function

Because we use C89 we need to move variables start of block.

* datalink: Hide strings.h because Windows

Windows does not support strings.h. Hide it from it.

---------

Co-authored-by: Kari Argillander <kari.argillander@fidelix.com>
This commit is contained in:
Kari Argillander
2024-09-04 21:32:31 +03:00
committed by GitHub
parent b7d03fd415
commit 98e8cf2147
8 changed files with 279 additions and 115 deletions
+1 -1
View File
@@ -209,7 +209,7 @@ BACNET_STACK_EXPORT
bool Network_Port_Remote_BBMD_BIP_Lifetime_Set(
uint32_t object_instance, uint16_t value);
#if (defined(BACDL_ALL) || defined(BACDL_BIP6))
#if defined(BACDL_BIP6)
BACNET_STACK_EXPORT
bool Network_Port_BBMD_IP6_Accept_FD_Registrations(uint32_t object_instance);
BACNET_STACK_EXPORT