Login Form






Lost Password?
No account yet? Register
Home arrow Forums
ECharts
Welcome, Guest
ACCESS THE MEDIA SEVER (0 viewing) 
Go to bottom Post Reply Favoured: 0
TOPIC: ACCESS THE MEDIA SEVER
#364
gfunk (User)
Fresh Boarder
Posts: 19
graphgraph
User Offline Click here to see the profile of this user
ACCESS THE MEDIA SEVER 10 Months, 1 Week ago  
good day

I am having trouble connecting my app to te media server (asterisk)
can someone help me specify the Xlite and asterisk server's IP address ?
here is what a did.

def save = {
def blaster = new Blaster(params)
if(!blaster.hasErrors() && blaster.save()) {

def address = blaster.address.trim()
javaToClick2DialFlow1MachineService.initiate("sip:${address}@[XLITE IP ADDRESS]", "sip:recorder@[ASTERISK IP ADRESS]",30,false)

flash.message = "Blaster ${blaster.id} created"
// redirect(actionhow,id:blaster.id)

redirect(controller:"blasteeList",action:"create",params:[blasterId:blaster.id])

}
else {
render(view:'create',model:[blaster:blaster])
}

thanks.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#365
Tom Smith (Admin)
Admin
Posts: 70
graphgraph
User Offline Click here to see the profile of this user
Re:ACCESS THE MEDIA SEVER 10 Months, 1 Week ago  
In the demo, we relied on the Converge runtime to route to the proper IP addresses. The X-Lite registered with Converge, so that its IP address was known. A new address called "recorder" was created that subscribed to the Forward feature; this feature was provisioned with the IP address of the server.

This way the application is nice and clean; it does not have to worry about the routing details. Leave that to the Converge runtime.

Hope this helps. Post back if you have further questions.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#366
gfunk (User)
Fresh Boarder
Posts: 19
graphgraph
User Offline Click here to see the profile of this user
Re:ACCESS THE MEDIA SEVER 10 Months, 1 Week ago  
Thank you Tom, but i have some questions:

1) Is the new address called "recorder" the address of the X-lite ? (i mean the machine on which the x-lite is installed ? )

2)IF the X-lite and media server (asterisk) are on the different machine, how do i change this code so that this can work properly?

avaToClick2DialFlow1MachineService.initiate("sip:${address}@[?????]", "sip:recorder@[?????]",30,false)

thank you tom and have a great day.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#367
Gregory W. Bond (User)
Expert Boarder
Posts: 81
graph
User Offline Click here to see the profile of this user
Re:ACCESS THE MEDIA SEVER 10 Months, 1 Week ago  
1) Is the new address called "recorder" the address of the X-lite ? (i mean the machine on which the x-lite is installed ? )


no - assuming you're using the Converge runtime what you want to do is create a new Converge address called 'record' that forwards to your asterisk recorder address - that way, any Converge app can simply reference sip: This e-mail address is being protected from spam bots, you need JavaScript enabled to view it (or whatever domain you've chosen for your Converge runtime installation) to access the recorder without needing to know the actual IP address of the recorder - this is the approach we used in our screencast - take a look at the 18:00 mark for an example of a controller accessing the 'recorder' address

here's what you need to do to add the 'recorder' address to the Converge runtime and configure it to forward to asterisk:

'recorder' is a UserAddress you add for an Individual (say, the 'admin' Individual) via the Converge Administration 'Addresses' web page (http://localhost:8080/converge-admin-0.1/userAddress/list)

after you add the 'recorder' address, you subscribe the address to the built-in Converge 'Forward' feature using the Converge Administration 'Sub_script_ions' web page (http://localhost:8080/converge-admin-0.1/featureSub_script_ion/list) - the feature should be subscribed to in the 'terminating' region since it's only intended for calls to the recorder - since the recorder only subscribes to this one feature the default terminating priority value of 0 can be used (this value determines the relative order of a feature in the call path when an address subscribes to more than one feature)

the last step is to configure the recorder's newly subscribed to 'Forward' feature to forward to your asterisk recorder - to do this, use the Converge Forward Administration page (http://localhost:8080/converge-forward-0.1/) and edit the entry for the recorder address so that the 'Forwarding User' is whatever sip 'user' you configured for your asterisk recorder (we used 'brecord' for our configuration), and "Forwarding Host' is the IP address of your asterisk server

that's it! i think this also answers your second question (please clarify the question if it doesn't)

we used the same approach for the p_layer_ function we configured on our asterisk server

the code we used for our screencast, as well as the asterisk config file we used are available from here
 
Report to moderator   Logged Logged  
 
Last Edit: 2009/11/02 17:50 By bond.
  The administrator has disabled public write access.
#368
Gregory W. Bond (User)
Expert Boarder
Posts: 81
graph
User Offline Click here to see the profile of this user
Re:ACCESS THE MEDIA SEVER 10 Months, 1 Week ago  
tom just informed me that the asterisk config file for the screencast is not included in the screencast code zipfile (sorry) - so here it is:

Code: :

 [default] exten => brecord,1,Answer() exten => brecord,2,Playback(custom/record-msg) exten => brecord,3,Record(/tmp/blast-recording.gsm,0,30) exten => brecord,4,Playback(goodbye) exten => brecord,5,Hangup() exten => bplay,1,Answer() exten => bplay,2,Playback(/tmp/blast-recording) exten => bplay,3,Wait(2) exten => bplay,4,Hangup()

 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
#369
Tom Smith (Admin)
Admin
Posts: 70
graphgraph
User Offline Click here to see the profile of this user
Re:ACCESS THE MEDIA SEVER 10 Months, 1 Week ago  
This config assumes the presence of a prompt in custom/record-msg (saying something like "Record your announcement now") ... feel free to use your own prompt here.
 
Report to moderator   Logged Logged  
  The administrator has disabled public write access.
Go to top Post Reply
Powered by FireBoardget the latest posts directly to your desktop
Copyright © 2006-2009 echarts.org