NetBurner 3.5.6
PDF Version
syslog.h File Reference

Syslog network logging utility for NetBurner systems. More...

#include <nettypes.h>

Go to the source code of this file.

Functions

int SysLog (const char *format,...)
 Send a formatted log message to the syslog server.
 
int SysLogVia (int interfaceNum, const char *format,...)
 Send a formatted log message via a specific network interface.
 

Variables

IPADDR SysLogAddress
 Destination IP address for syslog messages.
 

Detailed Description

Syslog network logging utility for NetBurner systems.

This header provides a lightweight syslog implementation that enables applications to send logging information to remote syslog servers or hosts using UDP. The implementation follows the syslog protocol for network-based logging and debugging.

Key features:

  • UDP-based logging to remote hosts
  • Printf-style formatted logging
  • Configurable destination address (unicast or broadcast)
  • Multi-interface support for network driver logging
  • No buffering - immediate transmission

Common use cases:

  • Remote debugging without serial console
  • Centralized logging from multiple NetBurner devices
  • Network event logging and monitoring
  • Application diagnostics and troubleshooting
Note
The syslog functions use floating-point formatting support, which will increase application size by approximately 30-40KB. If code size is critical and floating-point logging is not needed, consider using iprintf() to the serial console instead.
Warning
Syslog uses UDP which is unreliable - messages may be lost under high network load or congestion. Not suitable for critical logging where message delivery must be guaranteed.
Syslog Server Setup:
On Linux/Unix, syslog messages can be received using:
# Using netcat
nc -u -l 514
# Using rsyslog (edit /etc/rsyslog.conf)
# Add: $ModLoad imudp
# $UDPServerRun 514

On Windows, use a syslog server application like:

  • Kiwi Syslog Server
  • Visual Syslog Server
  • SolarWinds Syslog Server