#include <stdio.h>
#include <io.h>
#include <arpa/inet.h>
#include <net/route.h>
#include <pro/dhcp.h>
#include <pro/sntp.h>
#include <sys/version.h>
#include <sys/confnet.h>
#include <sys/timer.h>
#include <sys/heap.h>
#include <sys/syslog.h>
#include <dev/board.h>
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 DEV_CONSOLE_NAME |
Device name used for UART output. | |
#define | MYBAUD 115200 |
UART baudrate. | |
#define | MYDEV DEV_CONSOLE |
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 MYMAC 0x00, 0x06, 0x98, 0x00, 0x00, 0x00 |
Default MAC. Used if EEPROM is empty.
Referenced by main().
#define MYIP "192.168.192.100" |
Default local IP address. Used if EEPROM configuration and DHCP is unavailable.
Referenced by main().
#define MYMASK "255.255.255.0" |
Default IP mask. Used if EEPROM configuration and DHCP is unavailable.
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.
Referenced by main().
#define MYLOGD "192.168.192.222" |
#define MYTIMED "130.149.17.21" |
IP address of the host running a time daemon.
Referenced by main().
#define MYUART DEV_CONSOLE_NAME |
Device name used for UART output.
Referenced by main().
#define MYBAUD 115200 |
#define MYDEV DEV_CONSOLE |
#define MYTZ -1 |
Local timezone, -1 for Central Europe.
Referenced by main().
#define COMPILERNAME "GCC" |
Referenced by main().
#define UART_OK 0x0001 |
Referenced by main().
#define STDOUT_OK 0x0002 |
Referenced by main().
#define STDERR_OK 0x0004 |
Referenced by main().
#define BAUDRATE_OK 0x0008 |
Referenced by main().
#define LANDEV_OK 0x0010 |
Referenced by main().
#define NETIF_OK 0x0020 |
Referenced by main().
#define NETROUTE_OK 0x0040 |
Referenced by main().
#define TIMED_OK 0x0080 |
Referenced by main().
int main | ( | void | ) |
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, rc, setlogserver(), stderr, STDERR_OK, stdout, STDOUT_OK, stime(), syslog(), TIMED_OK, UART_OK, and UART_SETSPEED.