OSDN Git Service

Update c++/ to nxtOSEK_v212.zip (I did not check their licenses.)
[nxt-jsp/etrobo-atk.git] / nxtOSEK / c++ / PrototypeSensor.h
index 5cd2f11..6ee79cb 100644 (file)
@@ -1,56 +1,56 @@
-//
-// PrototypeSensor.h
-//
-// Header for HiTechnic prototype sensor class
-//
-// Written 23-feb-2008 by rwk
-//
-// Copyright 2007, 2008 by Robert W. Kramer and Takashi Chikamasa
-//
-
-#ifndef _PROTOTYPE_SENSOR_H
-#define _PROTOTYPE_SENSOR_H
-
-//
-// these are necessary for data types associated with events and tasks, and the
-// i2c function prototypes
-//
-
-extern "C" {
-#include "kernel.h"
-#include "nxt_avr.h"
-#include "i2c.h"
-};
-
-//
-// this has definitions for the C++ classes
-//
-
-#include "LejosOSEKCC.h"
-
-
-
-//=============================================================================
-// class PrototypeSensor
-//   prototype sensor class definition
-//
-
-class PrototypeSensor {
- public:
-  PrototypeSensor(unsigned char _port,unsigned int _sample=10);
-  ~PrototypeSensor(void);
-
-  void setSampleRate(unsigned int rate);
-  void setDigitalPorts(unsigned char dir);
-  void writeDigitalData(unsigned char data);
-  unsigned char readDigitalData(void);
-  void readAnalogData(unsigned int analogPorts[5]);
-  unsigned int readAnalogData(int analogPort);
-
- private:
-  unsigned char port;
-  unsigned char digitalDir;
-  unsigned int sampleRate;
-};
-
-#endif
+//\r
+// PrototypeSensor.h\r
+//\r
+// Header for HiTechnic prototype sensor class\r
+//\r
+// Written 23-feb-2008 by rwk\r
+//\r
+// Copyright 2007, 2008 by Robert W. Kramer and Takashi Chikamasa\r
+//\r
+\r
+#ifndef _PROTOTYPE_SENSOR_H\r
+#define _PROTOTYPE_SENSOR_H\r
+\r
+//\r
+// these are necessary for data types associated with events and tasks, and the\r
+// i2c function prototypes\r
+//\r
+\r
+extern "C" {\r
+#include "kernel.h"\r
+#include "nxt_avr.h"\r
+#include "i2c.h"\r
+};\r
+\r
+//\r
+// this has definitions for the C++ classes\r
+//\r
+\r
+#include "LejosOSEKCC.h"\r
+\r
+\r
+\r
+//=============================================================================\r
+// class PrototypeSensor\r
+//   prototype sensor class definition\r
+//\r
+\r
+class PrototypeSensor {\r
+ public:\r
+  PrototypeSensor(unsigned char _port,unsigned int _sample=10);\r
+  ~PrototypeSensor(void);\r
+\r
+  void setSampleRate(unsigned int rate);\r
+  void setDigitalPorts(unsigned char dir);\r
+  void writeDigitalData(unsigned char data);\r
+  unsigned char readDigitalData(void);\r
+  void readAnalogData(unsigned int analogPorts[5]);\r
+  unsigned int readAnalogData(int analogPort);\r
+\r
+ private:\r
+  unsigned char port;\r
+  unsigned char digitalDir;\r
+  unsigned int sampleRate;\r
+};\r
+\r
+#endif\r