DND not reflected when set via FreePBX UCP

A new install of a cloud based FreePBX system, new install of the latest version of FOP2 and everything. I created a button on the phones to toggle Do Not Disturb status using feature codes and it works very well, and when I use that it updates the BLF on the phone, the status in FOP2 as well as the toggle in the User Control Panel (UCP) of FreePBX.
However, if I use the toggle for Do Not Disturb in UCP it changes the phone BLF but FOP2 doesn't seem to get notified or display the status.
I have installed the "Presence Box DND Integration" plugin, although I'm not sure that is relevant here... Am I missing something else to make this work? Queue Pause from Presence box is not installed.
Having DND status display is a key reason for wanting to get FOP2 up and running.

Comments

  • From reading older threads (maybe no longer relevant, I don't know), I saw advise to look at the output of this:

    asterisk -rx "database show dnd"

    It updates for the extension when it is put in DND via the button on the phone (via feature codes) or using the UCP slider:

    /DND/528 : YES

    I saw another post, though, that mentioned looking at this:

    asterisk -rx "database show fop2state" | grep 528

    That does not update when using the UCP slider, however when using the phone buttons or feature code I see this:

    /fop2state/PJSIP/528 : Do not Disturb

  • Also, the BLF on the phone is set to *76528, it is a Grandstream GRP2616 if it matters. Since it is seeing the DND that UCP is sending via AJAX to Asterisk, some notification must be sent it is just not the one that FOP2 is monitoring for? Help would be appreciated. :)

  • I set up bami.sh (from github) to monitor events, and here is what happens when UCP sets DND via the button. Can FOP2 catch any of this to reflect the status?

    03/03/21 20:21:56 - DEBUG - Event: ExtensionStatus
    Privilege: call,all
    Exten: *76528
    Context: ext-dnd-hints
    Hint: Custom:DEVDND528
    Status: 2
    StatusText: Busy
    
    Event: ExtensionStatus Privilege: call,all Exten: *76528 Context: ext-dnd-hints Hint: Custom:DEVDND528 Status: 2 StatusText: Busy
    03/03/21 20:21:56 - INFO - Response: Event: ExtensionStatus
    Privilege: call,all
    Exten: *76528
    Context: ext-dnd-hints
    Hint: Custom:DEVDND528
    Status: 2
    StatusText: Busy
    
    Event: ExtensionStatus Privilege: call,all Exten: *76528 Context: ext-dnd-hints Hint: Custom:DEVDND528 Status: 2 StatusText: Busy
    03/03/21 20:21:56 - DEBUG - Event: DeviceStateChange
    Privilege: call,all
    Device: Custom:DEVDND528
    State: BUSY
    
    Event: DeviceStateChange Privilege: call,all Device: Custom:DEVDND528 State: BUSY
    03/03/21 20:21:56 - INFO - Response: Event: DeviceStateChange
    Privilege: call,all
    Device: Custom:DEVDND528
    State: BUSY
    
    Event: DeviceStateChange Privilege: call,all Device: Custom:DEVDND528 State: BUSY
    03/03/21 20:21:56 - DEBUG - Event: ExtensionStatus
    Privilege: call,all
    Exten: 528
    Context: ext-local
    Hint: PJSIP/528&Custom:DND528,CustomPresence:528
    Status: 2
    StatusText: Busy
    
    Event: ExtensionStatus Privilege: call,all Exten: 528 Context: ext-local Hint: PJSIP/528&Custom:DND528,CustomPresence:528 Status: 2 StatusText: Busy
    03/03/21 20:21:56 - INFO - Response: Event: ExtensionStatus
    Privilege: call,all
    Exten: 528
    Context: ext-local
    Hint: PJSIP/528&Custom:DND528,CustomPresence:528
    Status: 2
    StatusText: Busy
    
    Event: ExtensionStatus Privilege: call,all Exten: 528 Context: ext-local Hint: PJSIP/528&Custom:DND528,CustomPresence:528 Status: 2 StatusText: Busy
    03/03/21 20:21:56 - DEBUG - Event: DeviceStateChange
    Privilege: call,all
    Device: Custom:DND528
    State: BUSY
    
    Event: DeviceStateChange Privilege: call,all Device: Custom:DND528 State: BUSY
    03/03/21 20:21:56 - INFO - Response: Event: DeviceStateChange
    Privilege: call,all
    Device: Custom:DND528
    State: BUSY
    
  • Hi,

    Thanks for the detailed post, you give me everything I needed.

    I wrote a basic plugin that will monitor the DeviceStateChange events to reflect the state on FOP2 Presence. I have not tested it, please download it, install it via Plugins page and see if it works... if it does I will publish it.

    http://download.fop2.com/plugins/fpbxdnd-1.0.0.tgz

    Best regards,

  • I am sorry I missed your reply, I must have not turned on notifications or whatever, I didn't know you had replied. I almost gave up. :) Then again, I have never received a confirmation email for my account after trying several times, I think maybe outbound email from this server is not working??

    I went into plugin manager and used Browse to find the zip file then uploaded it. It shows in the "Locally Available Plugins" and the box is checked for Globally Enabled. I don't see any visible indication the plugin is loaded other than that, and it does not seem to be working. I did a 'fwconsole reload' but is there more required?

  • I restarted fop2 (systemctl stop fop2; systemctl start fop2) and it does seem to be working. A systemctl restart fop2 fails, complaining 'Found left-over process 27311 (fop2_server) in control group while starting unit.' but a full stop/start works.

    And the status does seem to be updating as expected. Thank you very much for adding this!! I appreciate it.

  • Hello
    The new phones of Sangoma and the Sangoma apps for pc and mac and mobilephone also have the same problem. I install this plugin and it DND on the Fop2 works again
    Can you publish it with the next update – thanks.
    Saludos desde Vienna

Leave a Comment

BoldItalicStrikethroughOrdered listUnordered list
Emoji
Image
Align leftAlign centerAlign rightToggle HTML viewToggle full pageToggle lights
Drop image/file