<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,7 +1,7 @@
 # http://module-build.sourceforge.net/META-spec.html
 #XXXXXXX This is a prototype!!!  It will change in the future!!! XXXXX#
 name:         ElkM1-Control
-version:      0.02
+version:      0.1.0
 version_from: lib/ElkM1/Control.pm
 installdirs:  site
 requires:</diff>
      <filename>META.yml</filename>
    </modified>
    <modified>
      <diff>@@ -107,7 +107,7 @@ my $UNIT_PARAM = {
     description =&gt; 'an unit code from 1..16'
 };
 
-our $VERSION = '0.02';
+our $VERSION = '0.1.0';
 
 =head1 METHODS
 </diff>
      <filename>lib/ElkM1/Control.pm</filename>
    </modified>
    <modified>
      <diff>@@ -1,12 +1,10 @@
 package ElkM1::Control::Message::EthernetModuleTest;
 
+# MessageType: 'XK'
+
 use base ElkM1::Control::Message;
-use Carp;
-use warnings;
 use strict;
 
-# MessageType: 'XK'
-
 =head1 NAME
 
 ElkM1::Control::Message::EthernetModuleTest;
@@ -15,21 +13,58 @@ ElkM1::Control::Message::EthernetModuleTest;
 
 =head1 SYNOPSIS
 
-    my $msg = $elk-&gt;readMessage;
-
-    print &quot;EthernetModuleTest is &quot;.$msg-&gt;getString&quot;
-        if (ref($msg) eq 'ElkM1::Control::Message::EthernetModuleTest') 
+    my $elk = ElkM1::Control-&gt;new(host =&gt; '192.168.1.115');
+    my $msg = $elk-&gt;readMessage(); 
 
+# TODO - finish this synopsis.
+#
 =cut
 
 =head1 DESCRIPTION 
 
-This is the subclass of the L&lt;ElkM1::Control::Message&gt; object which represents the 'Ethernet Module Test' message
-from the ElkM1 control. This message is sent in response to an ethernet module every 30 seconds. The reply
-contains the current date and time of the ElkM1 panel. DO NOT REPLY TO THIS MESSAGE. 
+This is the subclass of the L&lt;ElkM1::Control::Message&gt; object which represents
+the 'Ethernet Module Test' message from the ElkM1 control. This message is sent
+every 30 seconds to test any M1XEP Ethernet module installed in the system.
+
+This object is usually instantiated via the MessageFactory object when a message
+is read. One wouldn't normally instantiate this object directly.
+
+=cut
 
-This object is usually instantiated via the MessageFactory object when a message is read. One wouldn't normally
-instantiate this object directly.
+# Hash to turn a day of week into a name.
+my %DAY_OF_WEEK = ( 1 =&gt; 'Sunday', 
+				2 =&gt; 'Monday', 
+				3 =&gt; 'Tuesday', 
+				4 =&gt; 'Wednesday', 
+				5 =&gt; 'Thursday', 
+				6 =&gt; 'Friday', 
+				7 =&gt; 'Saturday' );
+
+# Hash to turn a month into a name. 
+my %MONTH = ( 1 =&gt; 'January', 
+			2 =&gt; 'February', 
+			3 =&gt; 'March', 
+			4 =&gt; 'April', 
+			5 =&gt; 'May', 
+			6 =&gt; 'June', 
+			7 =&gt; 'July', 
+			8 =&gt; 'August',
+			9 =&gt; 'September',
+			10 =&gt; 'October',
+			11 =&gt; 'November',
+			12 =&gt; 'December' );
+
+# Hash to turn clock mode into a name.
+my %CLOCK_MODE = ( 0 =&gt; '24', 
+				1 =&gt; '12' );
+
+# Hash to turn DST mode into a name.
+my %DST_MODE = ( 0 =&gt; 'Inactive', 
+				1 =&gt; 'Active' );
+
+# Hash to turn Date  mode into a name.
+my %DATE_MODE = ( 0 =&gt; 'MM/DD', 
+				1 =&gt; 'DD/MM' );
 
 =head1 METHODS
 
@@ -37,15 +72,171 @@ instantiate this object directly.
 
 =cut
 
-=item $msg-&gt;getString()
+=item $msg-&gt;getSeconds
+
+Obtain the seconds value for the test.
+
+=cut
+
+sub getSeconds  { 
+	my $self = shift;
+	return substr($self-&gt;command,2,2);
+}
+
+=item $msg-&gt;getMinutes
+
+Obtain the minutes value for the test.
+
+=cut
+
+sub getMinutes { 
+	my $self = shift;
+	return substr($self-&gt;command,4,2);
+}
+
+=item $msg-&gt;getHour
+
+Get the hour of the test.
+
+=cut
+
+sub getHour { 
+	my $self = shift;
+	return substr($self-&gt;command,6,2);	
+}
+
+=item $msg-&gt;getDayOfWeekValue
+
+Get the test's day of the week.
+
+=cut
+
+sub getDayOfWeekValue { 
+	my $self = shift;
+	return int(substr($self-&gt;command,8,1));
+}
+
+=item $msg-&gt;getDayOfWeek
 
-Just get the data portion of the message for display in the toString method.
+Get the name of the day of the week for the test. (ie: Monday, or Friday, etc)
 
 =cut
 
-sub getString { 
+sub getDayOfWeek { 
 	my $self = shift;
-	return substr($self-&gt;command,4,18);
+	return $DAY_OF_WEEK{$self-&gt;getDayOfWeekValue};
+}
+
+=item $msg-&gt;getDay
+
+Get the day of the month for the test.
+
+=cut
+
+sub getDay { 
+	my $self = shift;
+	return int(substr($self-&gt;command,9,2));
+}
+
+=item $msg-&gt;getMonthValue
+
+Get the test's value of the month.
+01 = Jan, 02 = Feb, etc. 
+
+=cut
+
+sub getMonthValue { 
+	my $self = shift;
+	return int(substr($self-&gt;command,11,2));
+}
+
+=item $msg-&gt;getMonth
+
+Get the name of the month for the test.
+
+=cut
+
+sub getMonth { 
+	my $self = shift;
+	return $MONTH{$self-&gt;getMonthValue};
+}
+
+=item $msg-&gt;getYear
+
+Get the year of the test as an integer. (ie. 05 = 2005).
+Add this number to 2000 to get the correct year. 
+
+=cut
+
+sub getYear { 
+	my $self = shift;
+	int(substr($self-&gt;command,13,2));
+}
+
+=item $msg-&gt;getDSTValue
+
+Get the Daylight Saving Time (DST) flag (0=Inactive, 1=Active).
+
+=cut
+
+sub getDSTValue { 
+	my $self = shift;
+	return substr($self-&gt;command,15,1);
+}
+
+=item $msg-&gt;getDST
+
+Get the Daylight Saving Time (DST) status.
+
+=cut
+
+sub getDST { 
+	my $self = shift;
+	return $DST_MODE{$self-&gt;getDSTValue};
+}
+
+=item $msg-&gt;getClockModeValue
+
+Get the clock's display mode value (0=24 hour, 1=12 hour).
+
+=cut
+
+sub getClockModeValue { 
+	my $self = shift;
+	return substr($self-&gt;command,16,1);
+}
+
+=item $msg-&gt;getClockMode
+
+Get the clock's display mode.
+
+=cut
+
+sub getClockMode { 
+	my $self = shift;
+	return $CLOCK_MODE{$self-&gt;getClockModeValue};
+}
+
+=item $msg-&gt;getDateModeValue
+
+Get the date's display mode value (0=MM/DD, 1=DD/MM).
+
+=cut
+
+sub getDateModeValue { 
+	my $self = shift;
+	return substr($self-&gt;command,17,1);
+}
+
+=item $msg-&gt;getDateMode
+
+Get the date's display mode.
+
+=cut
+
+sub getDateMode { 
+	my $self = shift;
+	return $DATE_MODE{$self-&gt;getDateModeValue};
 }
 
 =item toString
@@ -56,7 +247,15 @@ Return a string which represents the status of this message in a human readable
 
 sub toString {
 	my $self = shift;
-	return &quot;EthernetModuleTest: string=&quot;.$self-&gt;getString;
+
+	&quot;EthernetModuleTest: time=&quot;.$self-&gt;getHour.':'.$self-&gt;getMinutes.':'.$self-&gt;getSeconds.
+			&quot; dayofweek=&quot;.$self-&gt;getDayOfWeek.' ('.$self-&gt;getDayOfWeekValue.')'.
+			&quot; month=&quot;.$self-&gt;getMonth.
+			&quot; day=&quot;.$self-&gt;getDay.
+			&quot; year=&quot;.$self-&gt;getYear.
+			&quot; DST=&quot;.$self-&gt;getDST.
+			&quot; clock_mode=&quot;.$self-&gt;getClockMode.
+			&quot; date_mode=&quot;.$self-&gt;getDateMode;
 }
 
 =head1 VERSION 
@@ -73,7 +272,8 @@ L&lt;ElkM1::Control&gt;, L&lt;ElkM1::Control::Message&gt;, L&lt;ElkM1::Control::MessageFactory&gt;
 
 =head1 AUTHOR
 
-Karl Smith
+Taras Dejneka 2007-11-18
+based on work by James Russo
 
 =cut
 </diff>
      <filename>lib/ElkM1/Control/Message/EthernetModuleTest.pm</filename>
    </modified>
    <modified>
      <diff>@@ -34,6 +34,7 @@ our %DISPATCH_MAP = (
 		'PC' =&gt; 'ElkM1::Control::Message::PLCChangeUpdate',
 		'ZV' =&gt; 'ElkM1::Control::Message::ZoneAnalogVoltageReply',
 		'XK' =&gt; 'ElkM1::Control::Message::EthernetModuleTest',
+		'PS' =&gt; 'ElkM1::Control::Message::PLCStatusReply',
 );
 
 =head1 METHODS</diff>
      <filename>lib/ElkM1/Control/MessageFactory.pm</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>af4342265cc583b6330079dc2e5d25b0743c7aa4</id>
    </parent>
    <parent>
      <id>a518f66a875af068813000ff4135dc6d6c33e131</id>
    </parent>
  </parents>
  <author>
    <name>Karl Smith</name>
    <email>threadhead@gmail.com</email>
  </author>
  <url>http://github.com/threadhead/elkm1--control/commit/34fa83c4cf29621c0212489792211da30dfe4648</url>
  <id>34fa83c4cf29621c0212489792211da30dfe4648</id>
  <committed-date>2009-02-03T22:44:46-08:00</committed-date>
  <authored-date>2009-02-03T22:44:46-08:00</authored-date>
  <message>fixing merge conflict</message>
  <tree>84a14a9e3d855762f1db1cd886b8e5f69e3e513b</tree>
  <committer>
    <name>Karl Smith</name>
    <email>threadhead@gmail.com</email>
  </committer>
</commit>
