I’m running asterisk 13.17.1 and I have to use dynamic rooms. It seems work ok, however I have a situation, when a first member access confbridge a new room is active, so new members are able to dial and get in the same room, Just dialing a number and then dialing the conference room number. But, if the first member exits, no new members can access the conference room. We listen a message conf-invalid. My confbridge has to allow new members even if first member is out.
Here is my extensions.conf:
[from-TECHMAHINDRA]
exten => 41992,1,NoOp(${CALLERID(num)})
same => n,Goto(conferencia,s,1)
[conferencia]
exten => s,1,Answer()
exten => s,2,NoOp()
exten => s,3,Set(TIMEOUT=0)
exten => s,4,Set(INVALID=0)
exten => s,5,Background(bemvindo)
exten => s,6,Waitexten(6)
exten => 1,1,Macro(enter_conference)
exten => 2,1,GotoIf([{LEN(${CALLERID(num)})} > 7]?externo,s,1)
exten => 2,2,Macro(create_conference)
exten => i,1,Set(INVALID=[{INVALID}+1])
exten => i,2,Playback(invalida)
exten => i,3,GotoIf([{INVALID} > 2]?desliga,s,1)
exten => i,4,Goto(conferencia,s,5)
exten => t,1,Set(TIMEOUT=[{TIMEOUT}+1])
exten => t,2,Playback(desculpe)
exten => t,3,GotoIf([{TIMEOUT} > 2]?desliga,s,1)
exten => t,4,Goto(conferencia,s,5)
[macro-create_conference]
exten => s,1,Set(__CONFERENCENUM={RAND(9001,9999)})
same => n,GotoIf([{GROUP_COUNT({CONFERENCENUM}@conference)} > 0] ? 1)
same => n,Set(GROUP(conference)={CONFERENCENUM})
same => n,Playback(conf-enteringno)
same => n,SayDigits({CONFERENCENUM})
same => n,ConfBridge(${CONFERENCENUM},my_bridge,my_user)
[macro-enter_conference]
exten => s,1,Set(INVALID=0)
same => 2,Read(CONFERENCENUM,conf-getconfno,4)
same => 3,Wait(4)
same => 4,GotoIf([{GROUP_COUNT({CONFERENCENUM}@conference)} == 0] ? 6)
same => 5,ConfBridge({CONFERENCENUM},my_bridge,my_user)
same => 6,Set(INVALID=[{INVALID}+1])
same => 7,Playback(conf-invalid)
same => 8,GotoIf([{INVALID} > 2]?desliga,s,1)
same => 9,Goto(2)
[externo]
exten => s,1,Answer()
same => n,Playback(call_externa)
same => n,Hangup()
[desliga]
exten => s,1,Answer()
same => n,Playback(agradecemos)
same => n,HangUp()
Here is my confbridge.conf
[my_bridge]
type=bridge
max_members=10
regcontext=from-TECHMAHINDRA
language=en_US
[my_user]
type=user
music_on_hold_when_empty=yes
announce_join_leave=yes
[my_menu]
type=menu