aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2004-03-20 17:27:10 +0000
committermarkster <markster@f38db490-d61c-443f-a65b-d21fe96a405b>2004-03-20 17:27:10 +0000
commit51335c6cf3ccb500880afaa13ef432514c0ac28f (patch)
treec3c6d6a7e00f27fa65a2b98067e83b63b28c7844
parent1f645b070dd2035d064c50301a2ab37e878ffbd1 (diff)
Merge ADSI fixes
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@2501 f38db490-d61c-443f-a65b-d21fe96a405b
-rwxr-xr-xapps/app_adsiprog.c13
-rwxr-xr-xinclude/asterisk/adsi.h4
2 files changed, 15 insertions, 2 deletions
diff --git a/apps/app_adsiprog.c b/apps/app_adsiprog.c
index 7b6e06d50..12742609d 100755
--- a/apps/app_adsiprog.c
+++ b/apps/app_adsiprog.c
@@ -695,6 +695,18 @@ static int digitdirect(char *buf, char *name, int id, char *args, struct adsi_sc
return 2;
}
+static int clearcbone(char *buf, char *name, int id, char *args, struct adsi_script *istate, char *script, int lineno)
+{
+ char *tok;
+ tok = get_token(&args, script, lineno);
+ if (tok)
+ ast_log(LOG_WARNING, "CLEARCB1 requires no arguments ('%s') at line %d of %s\n", tok, lineno, script);
+
+ buf[0] = id;
+ buf[1] = 0;
+ return 2;
+}
+
static int digitcollect(char *buf, char *name, int id, char *args, struct adsi_script *istate, char *script, int lineno)
{
char *tok;
@@ -831,6 +843,7 @@ static struct adsi_key_cmd kcmds[] = {
{ "VOICEMODE", 0x93 },
/* Display call buffer 'n' */
/* Clear call buffer 'n' */
+ { "CLEARCB1", 0x95, clearcbone },
{ "DIGITCOLLECT", 0x96, digitcollect },
{ "DIGITDIRECT", 0x96, digitdirect },
{ "CLEAR", 0x97 },
diff --git a/include/asterisk/adsi.h b/include/asterisk/adsi.h
index 87b18c31f..33d5a1ae9 100755
--- a/include/asterisk/adsi.h
+++ b/include/asterisk/adsi.h
@@ -96,8 +96,8 @@
#define ADSI_INFO_PAGE 0x0
#define ADSI_COMM_PAGE 0x1
-#define ADSI_KEY_APPS 16 /* 16 to 33 reserved for applications */
-
+#define ADSI_KEY_APPS 20 /* 16 to 33 reserved for applications */
+ /* Changed to 20 by MDH */
/* Justification */
#define ADSI_JUST_LEFT 0x2
#define ADSI_JUST_RIGHT 0x1