?
Solved

Flashing light for DND with aastra 6731i and 6757i telephones in Asterisk 11

Posted on 2014-10-06
4
Medium Priority
?
622 Views
Last Modified: 2014-10-31
Hi,

We are using all Aastra 6337i and 6757i telephones on a FreePBX box running Asterisk 11 and we would like to be able to see when someone is using DND. If possible, we would like the light to flash for anyone that is using DND. For example: Extension 101 presses his DND button. All other extensions that have his name as a BLF in their phone show a flashing red light signaling that extension 101 is now in DND mode. Is this possible and how do I accomplish this?

Thank you
0
Comment
Question by:OAC Technology
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
4 Comments
 
LVL 15

Accepted Solution

by:
Phonebuff earned 2000 total points
ID: 40371433
Well,

   I would start here -- http://www.asteriskdocs.org/en/3rd_Edition/asterisk-book-html-chunk/usingCustomDeviceStates.html

   The look at the programing guide for the Aastra phones --  

  BUt this assumes that you are setting the button on the phone to execute and Asterisk DND, if you do a local DND on the phone, I don't believe there is a way to detect that --

 https://github.com/lgaetz/Aastra_Scripts/blob/master/User_Manuals/Aastra%20XML%20Scripts%20-%20PBX%20in%20a%20Flash-PA-001009-01-04%20version%202.3.0.pdf
0
 
LVL 2

Author Comment

by:OAC Technology
ID: 40377110
Sorry, this is a bit over my head. They would be using the Asterisk DND feature code to put their phones on DND. What exactly would I need to do to get the BLF light on others' phones to flash when a user uses the DND feature code?

Thanks
0
 
LVL 2

Author Comment

by:OAC Technology
ID: 40416360
Thanks for pointing me in the right direction. Here is how I solved this:

I modified the extensions_override_freepbx.conf file and added this:


[app-dnd-toggle]
exten => *76,1,Answer
exten => *76,n,Wait(1)
exten => *76,n,Macro(user-callerid,)
exten => *76,n,GotoIf($["${DB(DND/${AMPUSER})}" = ""]?activate:deactivate)
exten => *76,n(activate),Set(DB(DND/${AMPUSER})=YES)
exten => *76,n,Set(STATE=ONHOLD)
exten => *76,n,Gosub(app-dnd-toggle,sstate,1())
exten => *76,n(hook_on),Playback(do-not-disturb&activated)
exten => *76,n,Macro(hangupcall,)
exten => *76,n(deactivate),Noop(Deleting: DND/${AMPUSER} ${DB_DELETE(DND/${AMPUSER})})
exten => *76,n,Set(STATE=NOT_INUSE)
exten => *76,n,Gosub(app-dnd-toggle,sstate,1())
exten => *76,n(hook_off),Playback(do-not-disturb&de-activated)
exten => *76,n,Macro(hangupcall,)

exten => sstate,1,Set(DEVICE_STATE(Custom:DND${AMPUSER})=${STATE})
exten => sstate,n,Set(DEVICES=${DB(AMPUSER/${AMPUSER}/device)})
exten => sstate,n,GotoIf($["${DEVICES}" = "" ]?return)
exten => sstate,n,Set(LOOPCNT=${FIELDQTY(DEVICES,&)})
exten => sstate,n,GotoIf($["${DEVICES}" = "" ]?return)
exten => sstate,n,Set(LOOPCNT=${FIELDQTY(DEVICES,&)})
exten => sstate,n,Set(ITER=1)
exten => sstate,n(begin),Set(DEVICE_STATE(Custom:DEVDND${CUT(DEVICES,&,${ITER})})=${STATE})
exten => sstate,n,Set(ITER=$[${ITER} + 1])
exten => sstate,n,GotoIf($[${ITER} <= ${LOOPCNT}]?begin)
exten => sstate,n(return),Return()

;--== end of [app-dnd-toggle] ==--;


After this I went into the FreePBX GUI and went to Settings > Advanced Settings and set Enable Custom Device States to YES

Basically I just told the system to change the state of the *76 DND command to be the state of "ONHOLD" which makes the light flash whenever someone turns on DND using *76. The one small caveat that I found is that this directs the caller to the "busy" voicemail, but that didn't seem to bother anyone.  Hopefully this helps others out in the future.

Thanks again
0
 
LVL 2

Author Closing Comment

by:OAC Technology
ID: 40416362
See my final comment as well for the full solution
0

Featured Post

Simple, centralized multimedia control

Watch and learn to see how ATEN provided an easy and effective way for three jointly-owned pubs to control the 60 televisions located across their three venues utilizing the ATEN Control System, Modular Matrix Switch and HDBaseT extenders.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Implementing Avaya's One-X portal is pretty painless, until you want to deploy this to the Android and iPhone clients when these clients are outside of your network. The clients will also work within your local network. Here is our experience and so…
As companies replace their old PBX phone systems with Unified IP Communications, many are finding out that legacy applications such as fax do not work well with VoIP. Fortunately, Cloud Faxing provides a cost-effective alternative that works over an…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Internet Business Fax to Email Made Easy - With eFax Corporate (http://www.enterprise.efax.com), you'll receive a dedicated online fax number, which is used the same way as a typical analog fax number. You'll receive secure faxes in your email, fr…

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question