lib/rc-switch.c

changeset 22
a3b058c67289
parent 20
f7f9463cdefd
child 24
873786a20a61
--- a/lib/rc-switch.c	Sun May 04 17:30:18 2014 +0200
+++ b/lib/rc-switch.c	Sun May 04 22:29:18 2014 +0200
@@ -145,30 +145,36 @@
  * @param sGroup        Code of the switch group (A,B,C,D)
  * @param nDevice       Number of the switch itself (1..3)
  */
-/*void RCSwitch::switchOn(char sGroup, int nDevice) {
-  this->sendTriState( this->getCodeWordD(sGroup, nDevice, true) );
-}*/
+void switchOn_D(char sGroup, int nDevice) {
+    sendTriState( getCodeWordD(sGroup, nDevice, true) );
+}
 
-/**
+
+
+/*
  * Switch a remote switch off (Type D REV)
  *
  * @param sGroup        Code of the switch group (A,B,C,D)
  * @param nDevice       Number of the switch itself (1..3)
  */
-/*void RCSwitch::switchOff(char sGroup, int nDevice) {
-  this->sendTriState( this->getCodeWordD(sGroup, nDevice, false) );
-}*/
+void switchOff_D(char sGroup, int nDevice) {
+    sendTriState( getCodeWordD(sGroup, nDevice, false) );
+}
 
-/**
+
+
+/*
  * Switch a remote switch on (Type C Intertechno)
  *
  * @param sFamily  Familycode (a..f)
  * @param nGroup   Number of group (1..4)
  * @param nDevice  Number of device (1..4)
  */
-/*void RCSwitch::switchOn(char sFamily, int nGroup, int nDevice) {
-  this->sendTriState( this->getCodeWordC(sFamily, nGroup, nDevice, true) );
-}*/
+void switchOn_C(char sFamily, int nGroup, int nDevice) {
+    sendTriState( getCodeWordC(sFamily, nGroup, nDevice, true) );
+}
+
+
 
 /**
  * Switch a remote switch off (Type C Intertechno)
@@ -177,9 +183,9 @@
  * @param nGroup   Number of group (1..4)
  * @param nDevice  Number of device (1..4)
  */
-/*void RCSwitch::switchOff(char sFamily, int nGroup, int nDevice) {
-  this->sendTriState( this->getCodeWordC(sFamily, nGroup, nDevice, false) );
-}*/
+void switchOff_C(char sFamily, int nGroup, int nDevice) {
+    sendTriState( getCodeWordC(sFamily, nGroup, nDevice, false) );
+}
 
 
 
@@ -189,7 +195,7 @@
  * @param nAddressCode  Number of the switch group (1..4)
  * @param nChannelCode  Number of the switch itself (1..4)
  */
-void switchOn(int nAddressCode, int nChannelCode) {
+void switchOn_B(int nAddressCode, int nChannelCode) {
     sendTriState( getCodeWordB(nAddressCode, nChannelCode, true) );
 }
 
@@ -201,7 +207,7 @@
  * @param nAddressCode  Number of the switch group (1..4)
  * @param nChannelCode  Number of the switch itself (1..4)
  */
-void switchOff(int nAddressCode, int nChannelCode) {
+void switchOff_B(int nAddressCode, int nChannelCode) {
     sendTriState( getCodeWordB(nAddressCode, nChannelCode, false) );
 }
 
@@ -237,9 +243,11 @@
  * @param sGroup        Code of the switch group (refers to DIP switches 1..5 where "1" = on and "0" = off, if all DIP switches are on it's "11111")
  * @param sDevice       Code of the switch device (refers to DIP switches 6..10 (A..E) where "1" = on and "0" = off, if all DIP switches are on it's "11111")
  */
-/*void RCSwitch::switchOn(char* sGroup, char* sDevice) {
-    this->sendTriState( this->getCodeWordA(sGroup, sDevice, true) );
-}*/
+void switchOn_A(char* sGroup, char* sDevice) {
+    sendTriState( getCodeWordA(sGroup, sDevice, true) );
+}
+
+
 
 /**
  * Switch a remote switch off (Type A with 10 pole DIP switches)
@@ -247,9 +255,9 @@
  * @param sGroup        Code of the switch group (refers to DIP switches 1..5 where "1" = on and "0" = off, if all DIP switches are on it's "11111")
  * @param sDevice       Code of the switch device (refers to DIP switches 6..10 (A..E) where "1" = on and "0" = off, if all DIP switches are on it's "11111")
  */
-/*void RCSwitch::switchOff(char* sGroup, char* sDevice) {
-    this->sendTriState( this->getCodeWordA(sGroup, sDevice, false) );
-}*/
+void switchOff_A(char* sGroup, char* sDevice) {
+    sendTriState( getCodeWordA(sGroup, sDevice, false) );
+}
 
 
 

mercurial