logtime.c File Reference

Go to the source code of this file.

Defines

#define MYMAC   0x00, 0x06, 0x98, 0x00, 0x00, 0x00
 Default MAC. Used if EEPROM is empty.
#define MYIP   "192.168.192.100"
 Default local IP address. Used if EEPROM configuration and DHCP is unavailable.
#define MYMASK   "255.255.255.0"
 Default IP mask. Used if EEPROM configuration and DHCP is unavailable.
#define MYGATE   "192.168.192.1"
 Default gateway address. Used if EEPROM configuration and DHCP is unavailable. Only required if syslog or time server are located in a different network.
#define MYLOGD   "192.168.192.222"
 IP address of the host running a syslog daemon.
#define MYTIMED   "130.149.17.21"
 IP address of the host running a time daemon.
#define MYUART   "uart0"
 Device name used for UART output.
#define MYBAUD   115200
 UART baudrate.
#define MYDEV   DEV_UART
 Output device.
#define MYTZ   -1
 Local timezone, -1 for Central Europe.
#define COMPILERNAME   "GCC"
#define UART_OK   0x0001
#define STDOUT_OK   0x0002
#define STDERR_OK   0x0004
#define BAUDRATE_OK   0x0008
#define LANDEV_OK   0x0010
#define NETIF_OK   0x0020
#define NETROUTE_OK   0x0040
#define TIMED_OK   0x0080

Functions

int main (void)


Define Documentation

#define MYMAC   0x00, 0x06, 0x98, 0x00, 0x00, 0x00

Default MAC. Used if EEPROM is empty.

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 75 of file logtime.c.

Referenced by main().

#define MYIP   "192.168.192.100"

Default local IP address. Used if EEPROM configuration and DHCP is unavailable.

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 79 of file logtime.c.

Referenced by main().

#define MYMASK   "255.255.255.0"

Default IP mask. Used if EEPROM configuration and DHCP is unavailable.

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 83 of file logtime.c.

Referenced by main().

#define MYGATE   "192.168.192.1"

Default gateway address. Used if EEPROM configuration and DHCP is unavailable. Only required if syslog or time server are located in a different network.

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 89 of file logtime.c.

Referenced by main().

#define MYLOGD   "192.168.192.222"

IP address of the host running a syslog daemon.

Examples:
logtime/logtime.c.

Definition at line 92 of file logtime.c.

Referenced by main().

#define MYTIMED   "130.149.17.21"

IP address of the host running a time daemon.

Definition at line 95 of file logtime.c.

#define MYUART   "uart0"

Device name used for UART output.

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 98 of file logtime.c.

Referenced by main().

#define MYBAUD   115200

UART baudrate.

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 101 of file logtime.c.

Referenced by main().

#define MYDEV   DEV_UART

Output device.

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 104 of file logtime.c.

Referenced by main().

#define MYTZ   -1

Local timezone, -1 for Central Europe.

Definition at line 107 of file logtime.c.

#define COMPILERNAME   "GCC"

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 113 of file logtime.c.

Referenced by main().

#define UART_OK   0x0001

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 117 of file logtime.c.

Referenced by main().

#define STDOUT_OK   0x0002

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 118 of file logtime.c.

Referenced by main().

#define STDERR_OK   0x0004

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 119 of file logtime.c.

Referenced by main().

#define BAUDRATE_OK   0x0008

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 120 of file logtime.c.

Referenced by main().

#define LANDEV_OK   0x0010

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 121 of file logtime.c.

Referenced by main().

#define NETIF_OK   0x0020

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 122 of file logtime.c.

Referenced by main().

#define NETROUTE_OK   0x0040

Examples:
logtime/logtime.c, and snmpd/snmpd.c.

Definition at line 123 of file logtime.c.

Referenced by main().

#define TIMED_OK   0x0080

Examples:
logtime/logtime.c.

Definition at line 124 of file logtime.c.

Referenced by main().


Function Documentation

int main ( void   ) 

Definition at line 129 of file logtime.c.

References _fileno(), _ioctl(), _timezone, BAUDRATE_OK, _CONFNET::cdn_gateway, _CONFNET::cdn_ip_addr, COMPILERNAME, confnet, DEV_ETHER, freopen(), inet_addr(), inet_ntoa(), LANDEV_OK, LOG_DEBUG, LOG_ERR, LOG_INFO, LOG_PERROR, LOG_USER, MYBAUD, MYDEV, MYGATE, MYIP, MYLOGD, MYMAC, MYMASK, MYTIMED, MYTZ, MYUART, NETIF_OK, NETROUTE_OK, NutDhcpIfConfig(), NutHeapAvailable, NutIpRouteAdd(), NutNetIfConfig(), NutRegisterDevice(), NutSleep(), NutSNTPGetTime(), NutVersionString(), openlog(), printf, puts, setlogserver(), stderr, STDERR_OK, stdout, STDOUT_OK, stime(), syslog(), TIMED_OK, UART_OK, and UART_SETSPEED.


© 2000-2007 by egnite Software GmbH - visit http://www.ethernut.de/