Index: trunk/MagicSoft/Cosy/.rootrc
===================================================================
--- trunk/MagicSoft/Cosy/.rootrc	(revision 1139)
+++ trunk/MagicSoft/Cosy/.rootrc	(revision 1139)
@@ -0,0 +1,45 @@
+#############################################################################
+#                                                                           #
+# This is the path where root seraches for macros                           #
+# to execute (eg. .x merpp.C)                                               #
+#                                                                           #
+#############################################################################
+
+Unix.*.Root.MacroPath:       .:./macros
+
+#############################################################################
+#                                                                           #
+# This is the path where the dynamic loader (eg. gSystem->Load("mars.so")   #
+# is searching for the shared objects                                       #
+#                                                                           #
+#############################################################################
+
+Unix.*.Root.DynamicPath:     .:./lib
+
+#############################################################################
+#                                                                           #
+# This is the name of the logon macro (executed at root startup) and the    #
+# logoff macro (executed when quiting root)                                 #
+#                                                                           #
+#############################################################################
+
+Rint.Logon:                  rootlogon.C
+Rint.Logoff:                 rootlogoff.C
+
+#############################################################################
+#                                                                           #
+# This is used if you want to use the root documentation facility to        #
+# create the documentation of the code out of the code                      #
+#                                                                           #
+#############################################################################
+
+Root.Html.DescriptionStyle:  Doc++
+
+Root.Html.Author:            !   Author(s):
+Root.Html.Copyright:         !   Copyright
+Root.Html.Modified:          !   Modified:
+Root.Html.Description        // ----
+
+Root.Html.Root:              http://root.cern.ch/root/htmldoc/
+Root.Html.HomePage:          http://magic.uni-sw.gwdg.de/stesy/
+Root.Html.SearchEngine:      http://magic.uni-sw.gwdg.de/mars/search.html
Index: trunk/MagicSoft/Cosy/Changelog
===================================================================
--- trunk/MagicSoft/Cosy/Changelog	(revision 1138)
+++ trunk/MagicSoft/Cosy/Changelog	(revision 1139)
@@ -1,4 +1,24 @@
                                                                   -*-*- END -*-*-
 
+ 2001/12/21 - Thomas Bretz:
+ 
+   * candrv/*.cc:
+     - added comments
+
+   * .rootrc:
+     - added
+     
+   * Makefile:
+     - changed to create a shared object (for html docu)
+   
+   * macros/dohtml.C:
+     - added
+     
+   * macros/rootlogon.C:
+     - added
+   
+   * subdir lib:
+     - added
+  
  2001/12/12 - Thomas Bretz:
  
Index: trunk/MagicSoft/Cosy/candrv/network.h
===================================================================
--- trunk/MagicSoft/Cosy/candrv/network.h	(revision 1138)
+++ trunk/MagicSoft/Cosy/candrv/network.h	(revision 1139)
@@ -33,5 +33,5 @@
     bool HasError() const;
 
-    ClassDef(Network, 0)
+    ClassDef(Network, 0) // collection of nodes (nodedrv)
 };
 
Index: trunk/MagicSoft/Cosy/candrv/nodedrv.cc
===================================================================
--- trunk/MagicSoft/Cosy/candrv/nodedrv.cc	(revision 1138)
+++ trunk/MagicSoft/Cosy/candrv/nodedrv.cc	(revision 1139)
@@ -29,4 +29,15 @@
 // Base class for a class describing the interface for the CAN nodes.
 //
+// to be overloaded:
+//  virtual void InitDevice(Network *net)
+//  virtual void StopDevice()
+//  virtual void HandleSDO(WORD_t idx, BYTE_t subidx, LWORD_t val, struct timeval *tv)
+//  virtual void HandleSDOOK(WORD_t idx, BYTE_t subidx)
+//  virtual void HandleSDOError(LWORD_t data)
+//  virtual void HandlePDO1(BYTE_t *data, struct timeval *tv)
+//  virtual void HandlePDO2(BYTE_t *data, struct timeval *tv)
+//  virtual void HandlePDO3(BYTE_t *data, struct timeval *tv)
+//  virtual void HandlePDO4(BYTE_t *data, struct timeval *tv)
+//
 ///////////////////////////////////////////////////////////////////////
 #include "nodedrv.h"
@@ -47,5 +58,5 @@
 NodeDrv::NodeDrv(BYTE_t nodeid, const char *name, MLog &out) : Log(out), fNetwork(NULL), fId(32), fError(0)
 {
-    if (nodeid>31)
+    if (nodeid>0x1f)
     {
         cout << "SetNode - Error: Only node Numbers < 32 are allowed"<< endl;
@@ -60,5 +71,5 @@
     {
         fName = "Node#";
-        fName += nodeid;
+        fName += (int)nodeid;
     }
 }
Index: trunk/MagicSoft/Cosy/candrv/nodedrv.h
===================================================================
--- trunk/MagicSoft/Cosy/candrv/nodedrv.h	(revision 1138)
+++ trunk/MagicSoft/Cosy/candrv/nodedrv.h	(revision 1139)
@@ -1,4 +1,6 @@
 #ifndef NODEDRV_H
 #define NODEDRV_H
+
+#include <TString.h>
 
 #include "log.h"
@@ -36,7 +38,7 @@
     virtual ~NodeDrv();
 
-    BYTE_t   GetId() const       { return fId;   }
-    char    *GetNodeName() const { return fName; }
-    Network *GetNetwork()        { return fNetwork; }
+    BYTE_t      GetId() const       { return fId;   }
+    const char *GetNodeName() const { return fName; }
+    Network    *GetNetwork()        { return fNetwork; }
 
     virtual void InitDevice(Network *net);
@@ -83,5 +85,5 @@
     void EnableCanMsg(BYTE_t fcode);
 
-    ClassDef(NodeDrv, 0)
+    ClassDef(NodeDrv, 0) // base class for an object describing hardware
 };
 
Index: trunk/MagicSoft/Cosy/candrv/vmodican.h
===================================================================
--- trunk/MagicSoft/Cosy/candrv/vmodican.h	(revision 1138)
+++ trunk/MagicSoft/Cosy/candrv/vmodican.h	(revision 1139)
@@ -76,5 +76,5 @@
                       BYTE_t m4=0, BYTE_t m5=0, BYTE_t m6=0, BYTE_t m7=0);
 
-    ClassDef(VmodIcan, 0)
+    ClassDef(VmodIcan, 0) // hardware interface to the vmodican can module (Janz)
 };
 
Index: trunk/MagicSoft/Cosy/macros/dohtml.C
===================================================================
--- trunk/MagicSoft/Cosy/macros/dohtml.C	(revision 1139)
+++ trunk/MagicSoft/Cosy/macros/dohtml.C	(revision 1139)
@@ -0,0 +1,54 @@
+/* ======================================================================== *\
+!
+! *
+! * This file is part of MARS, the MAGIC Analysis and Reconstruction
+! * Software. It is distributed to you in the hope that it can be a useful
+! * and timesaving tool in analysing Data of imaging Cerenkov telescopes.
+! * It is distributed WITHOUT ANY WARRANTY.
+! *
+! * Permission to use, copy, modify and distribute this software and its
+! * documentation for any purpose is hereby granted without fee,
+! * provided that the above copyright notice appear in all copies and
+! * that both that copyright notice and this permission notice appear
+! * in supporting documentation. It is provided "as is" without express
+! * or implied warranty.
+! *
+!
+!
+!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!
+!   Copyright: MAGIC Software Development, 2000-2001
+!
+!
+\* ======================================================================== */
+
+
+void dohtml()
+{
+    //
+    //  don't forget that the shared object must have been loaded
+    //
+
+    //
+    //   create the html document class
+    //
+    THtml html;
+
+    html.SetOutputDir("htmldoc");
+    html.SetSourceDir("candrv");
+
+    html.MakeAll(kTRUE);
+/*
+    html.SetSourceDir("macros");
+    html.Convert("merpp.C",       "MARS - Merging and Preprocessing");
+    html.Convert("readraw.C",     "MARS - How To Read A Raw");
+    html.Convert("rootlogon.C",   "MARS - rootlogon.C");
+    html.Convert("readCT1.C",     "MARS - Read and display CT1 Events");
+    html.Convert("readMagic.C",   "MARS - Read and display Magic Events");
+    html.Convert("CT1Hillas.C",   "MARS - Calculate CT1 Hillas");
+    html.Convert("MagicHillas.C", "MARS - Calculate Magic Hillas");
+    html.Convert("collarea.C",    "MARS - Calculate Collection Area from a MC root file");
+    html.Convert("threshold.C",   "MARS - Calculate Energy Threshold from a MC root file");
+    html.Convert("trigrate.C",    "MARS - Calculate Trigger Rate from a MC root file");
+    */
+}
Index: trunk/MagicSoft/Cosy/macros/rootlogon.C
===================================================================
--- trunk/MagicSoft/Cosy/macros/rootlogon.C	(revision 1139)
+++ trunk/MagicSoft/Cosy/macros/rootlogon.C	(revision 1139)
@@ -0,0 +1,48 @@
+/* ======================================================================== *\
+!
+! *
+! * This file is part of MARS, the MAGIC Analysis and Reconstruction
+! * Software. It is distributed to you in the hope that it can be a useful
+! * and timesaving tool in analysing Data of imaging Cerenkov telescopes.
+! * It is distributed WITHOUT ANY WARRANTY.
+! *
+! * Permission to use, copy, modify and distribute this software and its
+! * documentation for any purpose is hereby granted without fee,
+! * provided that the above copyright notice appear in all copies and
+! * that both that copyright notice and this permission notice appear
+! * in supporting documentation. It is provided "as is" without express
+! * or implied warranty.
+! *
+!
+!
+!   Author(s): Thomas Bretz  12/2000 (tbretz@uni-sw.gwdg.de)
+!
+!   Copyright: MAGIC Software Development, 2000-2001
+!
+!
+\* ======================================================================== */
+
+
+void rootlogon()
+{
+
+    cout << endl;
+
+    cout << "Loading 'cosy.so'... " << flush;
+
+    if (gSystem->Load("cosy.so")!=0)
+        cout << "error." << endl;
+    else
+    {
+        //MParContainer::Class()->IgnoreTObjectStreamer();
+        //MArray::Class()->IgnoreTObjectStreamer();
+        cout << "done." << endl;
+    }
+
+    cout << endl;
+
+    cout << "Welcome to the Cosy Root environment." << endl;
+
+    cout << endl;
+}
+
