mbed Weather Platform firmware http://mbed.org/users/okini3939/notebook/mbed-weather-platform-firmware/

Dependencies:   ChaNFSSD EthernetNetIf I2CLEDDisp Agentbed ChaNFSUSB ILinterpreter mbed BMP085 WeatherMeters ConfigFile ChaNFS I2CLCD

Revision:
2:a3e5edf84f74
Parent:
1:6c7141895545
--- a/snmp.cpp	Sun Jul 10 15:36:46 2011 +0000
+++ b/snmp.cpp	Wed Aug 24 13:22:32 2011 +0000
@@ -47,9 +47,7 @@
 // RFC1213 local values
 static char locDescr[]              = "mbed Weather Platform";  // read-only (static)
 static char locObjectID[]           = "1.3.6.1.4.1.36582";                       // read-only (static)
-#endif
-volatile uint32_t locUpTime           = 0;                                        // read-only (static)
-#ifdef USE_SNMP
+//static uint32_t locUpTime           = 0;                                        // read-only (static)
 static char locContact[]            = "<root@weather>";                            // should be stored/read from EEPROM - read/write (not done for simplicity)
 static char locName[]               = "weather.mbed";                              // should be stored/read from EEPROM - read/write (not done for simplicity)
 static char locLocation[]           = "weather";                        // should be stored/read from EEPROM - read/write (not done for simplicity)
@@ -181,6 +179,9 @@
 
 int snmp_init (char *commname) {
 #ifdef USE_SNMP
+    if (! ethernet_flg) return 0;
+    pc.printf("SNMP community name: %s\r\n", buf);
+
     Agentbed.begin(commname, "None", SNMP_DEFAULT_PORT, eth);
     Agentbed.onPduReceive(pduReceived);
 #endif