EOL, unsupported.
[b]http://bugs.micasaverde.com/view.php?id=1451[/b]
WARNING:
There is a bug in the firmware for Vera V2 (including 1.1.1338) which leads to wrong calculations due to rounding errors (the Lua implementation uses ‘float’ instead of ‘double’). You are definitely affected by the bug, if the seconds for moonrise and/or moonset are different from ‘00’. Vera V1 users should be fine.
DAD displays the times for sunrise/sunset and moonrise/moonset, the current zodiac sign and the current moon phase on the GUI.
DAD provides the following times as UPnP variables (format: Unix timestamp and Human Understandable Format (HUF)) via UPnP service [tt]urn:upnp-ap15e-com:serviceId:DAD1[/tt]:
[ul][li]astronomical/nautical/civil twilight begin/end[/li]
[li]sunrise/sunset[/li]
[li]moonrise/moonset[/li]
[li]fraction of the moon illuminated at midnight/noon[/li][/ul]
DAD provides the following radiation data as UPnP variables (Germany only):
[ul][li]postcode and name of station[/li]
[li]height of station AMSL[/li]
[li]status of station[/li]
[li]total equivalent dose rate[/li]
[li]user defined threshold for total equivalent dose rate[/li]
[li]flag for total equivalent dose rate above threshold[/li][/ul]
DAD provides the following earthquake data as UPnP variables:
[ul][li]region[/li]
[li]date (UTC, local time, Unix timestamp)[/li]
[li]link to map[/li]
[li]magnitude[/li]
[li]location (latitude, longitude, depth)[/li]
[li]distance[/li]
[li]table of raw earthquake data[/li][/ul]
DAD provides the following Luup events:
[ul][li]astronomical/nautical/civil twilight begin/end[/li]
[li]sunrise/sunset[/li]
[li]moonrise/moonset[/li]
[li]possible impact of asteroid[/li][/ul]
[ul][li]total equivalent dose rate above/below user defined value[/li]
[li]total equivalent dose rate above user defined threshold[/li][/ul]
[ul][li]distance from earthquake less than user-defined value[/li]
[li]magnitude of earthquake greater than user-defined value[/li][/ul]
Dashboard layout for UI5:
[sunrise] [sunset]
[moonrise] [moonset]
[earthquake region] [magnitude] [distance]
[total dose rate] [station status] [zodiac sign]
Installation:
[ul][li]Upload the six files from the ZIP file to your box: ‘MiOS Developers’ → ‘Luup files’ → ‘Upload files’,[/li]
[li]check ‘Restart Luup after upload’, click ‘Go’, wait for Lua to restart,[/li]
[li]‘Create device’ tab-> ‘UpnpDevFilename’: [tt]D_DAD_UI5.xml[/tt] for UI5, [tt]D_DAD_UI4.xml[/tt] for earlier UI versions → click ‘Create device’,[/li]
[li]restart the Lua engine several times to initialise the UPnP variables,[/li]
[li]German users: go to [tt]http://odlinfo.bfs.de/laenderliste.php[/tt], select your state, set the UPnP variable [tt]DoseRateStationURL[/tt] to the URL for your state, and set the UPnP variable [tt]DoseRateStationID[/tt] to the ‘Kennung’ of the station nearest to your location,[/li]
[li]restart the Lua engine several times to initialise the UPnP variables,[/li]
[li]European users: set the UPnP variable [tt]EarthquakeProviderEU[/tt] to [tt]1[/tt] and restart the Lua engine.[/li]
[li]Displaying icons for the moon phases: install/configure [tt]http://www.quivira-font.com/files/Quivira.ttf[/tt] for your web client, set the UPnP variable [tt]DisplayMoonPhase[/tt] to [tt]1[/tt] and restart the the Lua engine. If the moon icon shows up as a rectangle, set [tt]DisplayMoonPhaseFont[/tt] to [tt]Quivira[/tt] (or to whatever font you are using for displaying moon phases) and restart the Lua engine. Please note that setting [tt]DisplayMoonPhaseFont[/tt] to a non-empty string triggers bug [tt]http://bugs.micasaverde.com/view.php?id=1447[/tt].
[/li][/ul]
Limitations:
[ul][li]DAD makes extensive use of Luup timers: all limitations of Luup timers apply to DAD.[/li]
[li]DAD won’t work for dates after 2038-01-19 (see http://forum.micasaverde.com/index.php?topic=5776.0).[/li]
[li]Currently, events do not work for UPnP variables with floating point values (see http://bugs.micasaverde.com/view.php?id=1444).[/li]
[li]The zodiac sign may be off by two days.[/li]
[li]When the [tt]EarthquakeDistance[/tt] event fires, the earthquake data set is consistent, when the [tt]EarthquakeMagnitude[/tt] event fires, the earthquake data set is guaranteed to be inconsistent
(see http://forum.micasaverde.com/index.php?topic=6213.0).[/li]
[li]The update interval for radiation data is 24 hours.[/li]
[li]The update interval for earthquake data is 5 minutes (DAD will miss earthquakes, which are less than 5 minutes apart).[/li]
[li]Do not base your decisions on the radiation/earthquake data from DAD.[/li][/ul]
Download:
[tt]https://docs.google.com/open?id=0Bz4omZm4gYcsMGE3NzAyYzMtOWYxZC00NDQxLThjOWUtNTc3MzBiNzM5NDdj[/tt]
Edit:
V0.02 adds support for civil, nautical, and astronomical twilight (see DAD_Advanced.jpg)
V0.03 adds support for moonrise and moonset (via U.S. Naval Observatory - Astronomical Applications Department)
V0.04 cosmetic changes
V0.05 bugfix for more than one moonrise/moonset per day (thanks to JOD), new variable DAD_USNO_URL
V0.06 bugfix for moorise/moonset for locations west of Greenwich (thanks to JOD)
V0.07 last
bugfix for moonrise/moonset, adds fraction of the moon illuminated for midnight and noon
V0.08 adds load-balancing for all users within a specific timezone
V0.1 adds Luup events for astronomical/nautical/civil twilight, sunrise/sunset, moonrise/moonset, and possible impacts of asteroids
V0.11 adds equivalent dose rate for about 1800 locations in Germany (see http://odlinfo.bfs.de/)
V0.11a fix for new ODL number format …
V0.12 adds data for earthquakes (see http://earthquake.usgs.gov/earthquakes/catalogs/eqs1hour-M0.txt)
V0.13 BETA adds Luup events for radiation and earthquakes
V0.14 bugfix for DST issue (thanks to futzle for finding and fixing the bug)
V1.0 bugfix for DST issue for days on which the clocks shift (thanks to futzle for the suggestion), local time for latest earthquake
V1.0a bugfix for local time for latest earthquake …
V1.0b bugfix for moon illumination for the West, ‘workaround’ for Y2K38 bug (thanks to oTi@ for finding and fixing the bugs)
V1.0c bugfix for pattern matcher for timestamp of last earthquake
V1.0d adds support for earthquake data from http://www.seismicportal.eu/
V1.0e adds more robustness against error conditions and makes sure that the earthquake data set for the distance event is consistent (the earthquake data set for the magnitude event is inconsistent, this is a limitation of MiOS, see http://forum.micasaverde.com/index.php?topic=6213.0)
V1.0f adds support for zodiac signs
V1.0g adds support for moon icons that correspond to the moon phase
V1.0h bugfix for moon phases for the South (thanks to futzle)
V1.0i Unicode workaround for browser quirks (Chrome, IE, Safari) (thanks to oTi@ for the suggestion and for beta-testing)
V1.0j fix for new ODL site structure; change microSv/h to nSv/h (workaround for MiOS bug #1444);
remove variables Message and EarthquakeRawData from lu_sdata (as requested by TimAlls);
change the thresholds for moon illumination from 1/49/51/99 to 3/47/53/97 (as suggested by futzle)
V1.1 adds support for UI5: new variables Sunrise_HHMMSS, Sunset_HHMMSS, Moonrise_HHMMSS, Moonset_HHMMSS, MoonIcon, ZodiacSign
V1.2 bugfix for sunset events earlier than sunrise events (thanks to dchoe and CMRancho for finding the bug)