Re: [asterisk-users] call files .vbs

2011-05-23 Thread Tzafrir Cohen
On Sun, May 22, 2011 at 07:05:45PM -0400, Thomas Perron wrote:
 This may be an obvious reflection of my Asterisk/Linux/Windows weaknesses
 but I want to know in any case!
 
 Can a vb script run somehow on a Linux machine or does it only work on
 Windows?

Only on Windows (practically).

 
 If I were to build a call file script (described in this link
 http://www.voip-info.org/wiki/index.php?page=Asterisk+auto-dial+out ) then
 how does it work if my Asterisk machine is running on Centos 5.5?
 
 I simply want to execute a script that helps me automate the voice
 broadcasting/IVR of up to 1 phone numbers.

I assume you know what you're doing and this is for a good cause.

Use the Asterisk Manager Interface.
http://www.voip-info.org/wiki/view/Asterisk+manager+API

Specifically, the Originate command.

-- 
   Tzafrir Cohen
icq#16849755  jabber:tzafrir.co...@xorcom.com
+972-50-7952406   mailto:tzafrir.co...@xorcom.com
http://www.xorcom.com  iax:gu...@local.xorcom.com/tzafrir

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] call files .vbs

2011-05-23 Thread Tiago Geada
I would rather write a new bash script for text and file handing.

I think you can install MONO and run windows stuff... from .net to vbs

On 23 May 2011 08:09, Tzafrir Cohen tzafrir.co...@xorcom.com wrote:

 On Sun, May 22, 2011 at 07:05:45PM -0400, Thomas Perron wrote:
  This may be an obvious reflection of my Asterisk/Linux/Windows weaknesses
  but I want to know in any case!
 
  Can a vb script run somehow on a Linux machine or does it only work on
  Windows?

 Only on Windows (practically).

 
  If I were to build a call file script (described in this link
  http://www.voip-info.org/wiki/index.php?page=Asterisk+auto-dial+out )
 then
  how does it work if my Asterisk machine is running on Centos 5.5?
 
  I simply want to execute a script that helps me automate the voice
  broadcasting/IVR of up to 1 phone numbers.

 I assume you know what you're doing and this is for a good cause.

 Use the Asterisk Manager Interface.
 http://www.voip-info.org/wiki/view/Asterisk+manager+API

 Specifically, the Originate command.

 --
   Tzafrir Cohen
 icq#16849755  jabber:tzafrir.co...@xorcom.com
 +972-50-7952406   mailto:tzafrir.co...@xorcom.com
 http://www.xorcom.com  iax:gu...@local.xorcom.com/tzafrir

 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] call files .vbs

2011-05-23 Thread A J Stiles
On Monday 23 May 2011, Thomas Perron wrote:
 This may be an obvious reflection of my Asterisk/Linux/Windows weaknesses
 but I want to know in any case!

 Can a vb script run somehow on a Linux machine or does it only work on
 Windows?

AFAIK there is no Linux interpreter for VBS  :(  But the format of the 
callfile is independent of the language used to create it -- anything else 
would violate the Principle of Equivalence.

Just learn Perl or Python instead.  Both these interpreters are installed by 
default on every modern Linux system.  Python is for the young and trendy, 
and I can't get to grips with it myself.  Perl is the rusty old Ford Transit 
van of programming languages:  it may not be much to look at, but it gets the 
job done.  And its regular expression handling is second to none.

 If I were to build a call file script (described in this link
 http://www.voip-info.org/wiki/index.php?page=Asterisk+auto-dial+out ) then
 how does it work if my Asterisk machine is running on Centos 5.5?

 I simply want to execute a script that helps me automate the voice
 broadcasting/IVR of up to 1 phone numbers.

You have to write a program, in whatever language you like  (bash even, if 
you're feeling sufficiently masochistic),  which generates a callfile to 
establish the call you want to set up.  (It's also best if you generate the 
file in some temporary location, then move it to the intended destination 
directory.)

-- 
AJS

Answers come *after* questions.

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users


[asterisk-users] call files .vbs

2011-05-22 Thread Thomas Perron
This may be an obvious reflection of my Asterisk/Linux/Windows weaknesses
but I want to know in any case!

Can a vb script run somehow on a Linux machine or does it only work on
Windows?

If I were to build a call file script (described in this link
http://www.voip-info.org/wiki/index.php?page=Asterisk+auto-dial+out ) then
how does it work if my Asterisk machine is running on Centos 5.5?

I simply want to execute a script that helps me automate the voice
broadcasting/IVR of up to 1 phone numbers.

Thank you

Thomas
--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] call files .vbs

2011-05-22 Thread Doug Lytle

Thomas Perron wrote:
Can a vb script run somehow on a Linux machine or does it only work on 
Windows?



Visual Basic is Windows specific.

Doug


--
Ben Franklin quote:

Those who would give up Essential Liberty to purchase a little Temporary Safety, 
deserve neither Liberty nor Safety.


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] call files .vbs

2011-05-22 Thread Thomas Perron
Hi Doug,
Yes. I have sorted that part out.  Also, it seems like the pscp function is
the way that I can tie together the vb script with the logic of the Asterisk
call files learning curve!!

Thanks

On Sun, May 22, 2011 at 8:37 PM, Doug Lytle supp...@drdos.info wrote:

 Thomas Perron wrote:

 Can a vb script run somehow on a Linux machine or does it only work on
 Windows?



 Visual Basic is Windows specific.

 Doug


 --
 Ben Franklin quote:

 Those who would give up Essential Liberty to purchase a little Temporary
 Safety, deserve neither Liberty nor Safety.


 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] call files .vbs

2011-05-22 Thread Steve Edwards

On Sun, 22 May 2011, Thomas Perron wrote:


Can a vb script run somehow on a Linux machine or does it only work on Windows?


Virtual machines or Wine may have some possibilities.

I simply want to execute a script that helps me automate the voice 
broadcasting/IVR of up to 1 phone numbers.


Write a script that executes on the Asterisk box. Where do the 10,000 
numbers come from?


Executing a script on the Asterisk box will enable you to monitor the 
status of the process better. Like only dumping xxx scripts at a time into 
the spool directory and sending you an email if Asterisk stops processing 
them for some reason.


--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] call files .vbs

2011-05-22 Thread Steve Edwards

On Sun, 22 May 2011, Thomas Perron wrote:

Also, it seems like the pscp function is the way that I can tie together 
the vb script with the logic of the Asterisk call files learning 
curve!!


pscp is a program, not a function. Part of or related to putty as I 
remember.


Not a good idea. One of the 'bugaboos' of call files is that you are 
supposed to create the files in a temporary directory and move them into 
the spool directory.


Also, you will have limited error detection ability if you are only 
dumping files 'willy-nilly.'


Much better to do it all on the Asterisk host.

--
Thanks in advance,
-
Steve Edwards   sedwa...@sedwards.com  Voice: +1-760-468-3867 PST
Newline  Fax: +1-760-731-3000

--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
  http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


Re: [asterisk-users] call files .vbs

2011-05-22 Thread C F
I'm the original author of said VB Script.
Steve is right, I had lots of errors - related to the fact that
asterisk watches it too closely and reads the files even before they
are complete - and have since updated it that it first dumps it to a
temp directory, then use a bash script on the linux machine that moves
all files from the temp directory to the call directory using plink.
Both pscp and plink are windoz programs that utilize ssh for their
functions. Pscp xfers files, and plink executes any remote commands.
In the newer version pscp in the VB Script dumps it to
/root/calltemps/ and /root/mvcallfiles.sh moves the files from
/root/calltemps/* to /var/spool/asterisk/outgoing/
change this line:
strcmd=C:\pscp -pw password c:\direcotry\strcnt\*
root@asterisk:/var/spool/asterisk/outgoing
to:
strcmd=C:\pscp -pw password c:\directory\strcnt\*
root@asterisk:/root/calltemps
make sure the dir exists
then add:
Set objShell2 = CreateObject(WScript.Shell)
strcmd2=C:\plink -pw password root@asterisk /root/mvcallfiles.sh
objShell2.Run strcmd2
/root/movcallfiles.sh:
#/bin/bash

mv /root/calltemps/* /var/spool/asterisk/outgoing/

Hope this helps.






On Sun, May 22, 2011 at 8:55 PM, Steve Edwards
asterisk@sedwards.com wrote:
 On Sun, 22 May 2011, Thomas Perron wrote:

 Also, it seems like the pscp function is the way that I can tie together
 the vb script with the logic of the Asterisk call files learning
 curve!!

 pscp is a program, not a function. Part of or related to putty as I
 remember.

 Not a good idea. One of the 'bugaboos' of call files is that you are
 supposed to create the files in a temporary directory and move them into the
 spool directory.

 Also, you will have limited error detection ability if you are only dumping
 files 'willy-nilly.'

 Much better to do it all on the Asterisk host.

 --
 Thanks in advance,
 -
 Steve Edwards       sedwa...@sedwards.com      Voice: +1-760-468-3867 PST
 Newline                                              Fax: +1-760-731-3000

 --
 _
 -- Bandwidth and Colocation Provided by http://www.api-digital.com --
 New to Asterisk? Join us for a live introductory webinar every Thurs:
              http://www.asterisk.org/hello

 asterisk-users mailing list
 To UNSUBSCRIBE or update options visit:
  http://lists.digium.com/mailman/listinfo/asterisk-users


--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users