Integration with legacy Voicemail

Where I work we’ve just implemented an Asterisk system between our 2 offices. Everybody loves the new system and the quality of the calls compared to our 25 year old PBX.

There’s just 1 problem. Our business relies greatly on voicemail and the built in VM system for asterisk is too limited for our use. This is fine because we’ve integrated our old VM system using a channel bank connected to one of our asterisk servers.

When a call gets sent to VM, we send the call over the channel bank and send the DTMF of the person’s mailbox who we want to put the message into. The caller leaves there message and hangs up. Asterisk hangs up the call just fine, however the voicemail system does not detect the hangup and continues to record the fast busy signal out of the channel bank until the max length of a voicemail is reached.

Under our old PBX when a hangup would occur, we would send 9******* to the VM system and that would signal a hangup. We’ve tried sending DTMF on hangup in our dialplan but that will only send DTMF to the asterisk end of the call, not out the Zap channel we use for the voicemail.

Does anybody know of a way we could send the 9******* out to our voicemail on a hangup? I’ve tried searching the forums and any documentation I could find, but I’ve had no luck as of yet.

Thank you for any assistance anybody could provide.