micolous.id.au

the result of a blogging accident

Thursday, February 16, 2006

Asterisk Time System

Filed under: Asterisk, VoIP — micolous @ 22:17

This is a simple dialplan menu that allows the user to enter an Australian postal code and display the current time for the location. It supports the major time zones.

[custom-time-menu]
; nsw
exten => _2[0-5]XX,1,SayUnixTime(,Australia/NSW)
exten => _2[0-5]XX,2,Goto(custom-new-main-menu,s,1)
; act
exten => _2[6-9]XX,1,SayUnixTime(,Australia/ACT)
exten => _2[6-9]XX,2,Goto(custom-new-main-menu,s,1)
; vic
exten => _3XXX,1,SayUnixTime(,Australia/Victoria)
exten => _3XXX,2,Goto(custom-new-main-menu,s,1)
; qld
exten => _4XXX,1,SayUnixTime(,Australia/Queensland)
exten => _4XXX,2,Goto(custom-new-main-menu,s,1)
; sa
exten => _5XXX,1,SayUnixTime(,Australia/South)
exten => _5XXX,2,Goto(custom-new-main-menu,s,1)
; wa
exten => _6XXX,1,SayUnixTime(,Australia/West)
exten => _6XXX,2,Goto(custom-new-main-menu,s,1)
; tas
exten => _7XXX,1,SayUnixTime(,Australia/Tasmania)
exten => _7XXX,2,Goto(custom-new-main-menu,s,1)
; nt
exten => _08XX,1,SayUnixTime(,Australia/North)
exten => _08XX,2,Goto(custom-new-main-menu,s,1)
; exit
exten => 9,1,Goto(custom-new-main-menu,s,1)

exten => s,1,ResponseTimeout(5)
exten => s,2,DigitTimeout(7)
exten => s,3,Wait(2)
exten => s,4,Background(custom/postcode-prompt)

exten => i,1,Wait(1)
exten => i,2,Playback(custom/unknown-location)
exten => i,3,Goto(s,1)

exten => t,1,Goto(custom-new-main-menu,s,1)

Thursday, February 2, 2006

conf.py 0.2

Filed under: Asterisk, Coding, VoIP — micolous @ 20:38

I’ve now updated “conf.py” to version 0.2. This release fixes a bug where if you had multiple Asterisk conferences, and conference A had users and conference B did not, that B would errornously report as having 1 user in it. That’s now been fixed now that the script takes into account responses from the Asterisk server a bit better.

Tuesday, January 24, 2006

Happy 2006, conf.py v0.1, autodialler-au v0.1

Filed under: Asterisk, Coding, VoIP — micolous @ 06:48

Happy 2006! I’ve been slacking off with this whole blogging thing, and there’s a whole lot of changed things. This whole use of static content in the blog has ment that I’m posting less.

I’ve written a small python script that shows who is in an Asterisk MeetMe conference. You can download it from here, and there is a demo showing the users on a conference I host.

In other coding, I’ve also written an autodialler for Asterisk, which is based on NotTheory’s autodialer.pl. My version uses the ACMA allocated
numbers list, and is written in Python. The effect is that it simplifies wardialling using Asterisk in Australia. It additionally generates a template file you can fill out to make notes, and records the phone calls made for future reference. You can download it here. You’ll need apsw installed for python sqlite3 support, and a copy of ACMA’s allocated number database to use the software (converted to
SQLite3 format using the included script, which is the same is what is used in phonesearch).

« Newer Posts

Powered by WordPress