summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--switchctl.c20
1 files changed, 20 insertions, 0 deletions
diff --git a/switchctl.c b/switchctl.c
index 6e2ef08..dcf417c 100644
--- a/switchctl.c
+++ b/switchctl.c
@@ -124,6 +124,16 @@ int process_cmd_request(const char* cmd, cmd_id_t cmd_id, const char* param, int
ch_name = &(param[4]);
ch_nr = &(cmd_param[2]);
}
+ else if(!strncmp(param, "add ", 4)) {
+ cmd_param = strdup("*0ii3");
+ ch_name = &(param[4]);
+ ch_nr = &(cmd_param[2]);
+ }
+ else if(!strncmp(param, "rm ", 3)) {
+ cmd_param = strdup("*0ii5");
+ ch_name = &(param[3]);
+ ch_nr = &(cmd_param[2]);
+ }
else if(!strncmp(param, "on2 ", 4)) {
cmd_param = strdup("*0ii2");
ch_name = &(param[4]);
@@ -131,6 +141,16 @@ int process_cmd_request(const char* cmd, cmd_id_t cmd_id, const char* param, int
}
else if(!strncmp(param, "off2 ", 5)) {
cmd_param = strdup("*0iiM2");
+ ch_name = &(param[5]);
+ ch_nr = &(cmd_param[2]);
+ }
+ else if(!strncmp(param, "add2 ", 5)) {
+ cmd_param = strdup("*0ii4");
+ ch_name = &(param[5]);
+ ch_nr = &(cmd_param[2]);
+ }
+ else if(!strncmp(param, "rm2 ", 4)) {
+ cmd_param = strdup("*0ii6");
ch_name = &(param[4]);
ch_nr = &(cmd_param[2]);
}