View custom extension state

I search a method to make a function like "Mobile Twinning", asterisk side is almost working, but through FOP i need to force extension state to INUSE when is necessary, better if i can set state and called or caller.
I try to understood FOP2Callbacks.pm, but i don't know if is a good way and is very difficult.
I try to explain what i do, when a mobile call through asterisk DISA a number, I set Custom:DND2001 = INUSE, 2001 is the extension twinning with mobile number. So the extension 2001 is busy, when mobile hangup set Custom:DND2001 = NOT_INUSE.
What I would do with FOP2 is to intercept Custom:DND2001 state or ad hoc variable, to view that extension 2001 is in conversation.
I hope you understand my bad english first of all and you have an idea or solution.

Thank you
Marco Baldini
Sign In or Register to comment.