I’m not sure if this fix the problem, but this is how I have done!
This is what I have in </etc/asterisk/zapata.conf> on my FXO channel.
; Channel 4 FXO port for incoming analog line
cidsignalling=dtmf ; Sweden
cidstart=polarity ; Sweden
channel => 4
immediate: Normally (i.e. with immediate set to ‘no’, the default), when you lift an FXS handset, the Zaptel driver provides you a dialtone and listens for digits that you dial, passing them on to Asterisk. Asterisk waits until the number you’ve dialled matches an extension, and then begins executing the first command on the matching extension. If you set
immediate=yes, then Asterisk will instruct the Zaptel driver to not generate a dialtone when you lift a handset, instead passing control immediately to Asterisk. Asterisk will start executing the commands for this channel’s “s” extension. This is sometimes referred to as “batphone mode”. Default: no.
This made it answer the incoming call a little quicker and still have callerID enabled!
But it is still a bit slow on answering, but quicker than 5sec.