Chore/bacnet-sc-unrelated-cleanup (#620)
* Added required linux Ethernet library for ethernet build * Added .obj to gitignore * Fixed BACnet port for APPLE to use BSD in CMake * Changed format in CMake to enable cleaner SC merge * Added create-object and delete-object recipes in GCC Makefile * Added datalink timer to all example OS apps * Changed most microcontroller ports to use BACAPP_MINIMAL to specify which datatypes can be written. * Fixed zephyr OS for BACnet/IP warning * Fixed zephyr OS log to not require log_strdup * Added writefile API to file object example * Added API to device-client to make it more robust. * Added API in network-port object for getting the ASCII object-name * Added debug print with a timestamp option * Added debug print with hex dump print * Added API to network port object for activate and discard * Added default define for debug with timestamp * Added prototype in header for disabled debug printf. * Added fifo peek ahead function to peek at more than one byte. * Added get-mac value for network port that uses buffer rather than octetstring
This commit is contained in:
@@ -34,6 +34,10 @@
|
||||
#define DEBUG_ENABLED 0
|
||||
#endif
|
||||
|
||||
#ifndef DEBUG_PRINTF_WITH_TIMESTAMP
|
||||
#define DEBUG_PRINTF_WITH_TIMESTAMP 0
|
||||
#endif
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif /* __cplusplus */
|
||||
@@ -55,17 +59,18 @@ extern "C" {
|
||||
void debug_perror(
|
||||
const char *format,
|
||||
...);
|
||||
#if DEBUG_ENABLED
|
||||
/* Nothing more here */
|
||||
#else
|
||||
/* If your compiler supports it, this is more compact:
|
||||
inline void debug_printf(
|
||||
const char *format,
|
||||
...) {
|
||||
format = format;
|
||||
}
|
||||
*/
|
||||
#endif
|
||||
BACNET_STACK_EXPORT
|
||||
void debug_printf_hex(
|
||||
uint32_t offset,
|
||||
const uint8_t *buffer,
|
||||
size_t buffer_length,
|
||||
const char *format, ...);
|
||||
|
||||
BACNET_STACK_EXPORT
|
||||
void debug_printf_disabled(
|
||||
const char *format,
|
||||
...);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif /* __cplusplus */
|
||||
|
||||
Reference in New Issue
Block a user