Bartosz Piec
2006-Feb-01 12:01 UTC
[Asterisk-Users] Receiving faxes with spandsp - strange problem
Hello, I'm trying to receive faxes with asterisk. My configuration is like this: PSTN fax -> ISDN -> Cisco router with VoIP module -> Asterisk When I try to send a fax from PSTN fax I got the standard fax signal, Asterisk starts rxfax application and then call ends and there is no tif anywhere. On the fax display there is still one message: Calling... Part of my extensions.conf: [incoming] exten => 2933975,1,Goto(fax,2201,1) [fax] exten => 2201,1,Macro(faxreceive) [macro-faxreceive] exten => s,1,SetVar(FAXFILE=/var/spool/asterisk/fax/${UNIQUEID}.tif) exten => s,2,DBGet(EMAILADDR=extensionemail/${MACRO_EXTEN}) exten => s,3,rxfax(${FAXFILE}) exten => s,4,Congestion exten => s,103,SetVar(EMAILADDR=defaultuser@example.com) exten => s,104,Goto(3) 2933975 is the number on which asterisk should listen for new faxes and it works (in a way that rxfax is being run). Info from asterisk console: -- Executing Goto("SIP/62.111.174.65-f67004d0", "fax|2201|1") in new stack -- Goto (fax,2201,1) -- Executing Macro("SIP/62.111.174.65-f67004d0", "faxreceive") in new stack -- Executing SetVar("SIP/62.111.174.65-f67004d0", "FAXFILE=/var/spool/asterisk/fax/1138819786.1.tif") in new stack -- Executing DBget("SIP/62.111.174.65-f67004d0", "EMAILADDR=extensionemail/2201") in new stack -- DBget: varname=EMAILADDR, family=extensionemail, key=2201 -- DBget: set variable EMAILADDR to bpiec@softhis.com -- Executing RxFAX("SIP/62.111.174.65-f67004d0", "/var/spool/asterisk/fax/1138819786.1.tif") in new stack And that's all. Fax disconnects and there is no /var/spool/asterisk/fax/1138819786.1.tif file. What can be wrong? I saw that people are using 'fax' in extensions.conf (exten => fax,1,rxfax(${FAXFILE})). When this can be used? It isn't working for me... Maybe it is an issue with Cisco router configuration? Normal calls (not faxes) from PSTN lines work great... I have installed asterisk 1.2.4 and spandsp 0.0.2pre23. -- Best regards, Bartosz Piec
Bartosz Jozwiak
2006-Feb-01 12:28 UTC
[Asterisk-Users] Receiving faxes with spandsp - strange problem
> I'm trying to receive faxes with asterisk. My configuration is like this: > > PSTN fax -> ISDN -> Cisco router with VoIP module -> Asterisk > > When I try to send a fax from PSTN fax I got the standard fax signal, > Asterisk starts rxfax application and then call ends and there is no tif > anywhere. On the fax display there is still one message: Calling... > > Part of my extensions.conf: > > [incoming] > exten => 2933975,1,Goto(fax,2201,1) > > [fax] > exten => 2201,1,Macro(faxreceive) > > [macro-faxreceive] > exten => s,1,SetVar(FAXFILE=/var/spool/asterisk/fax/${UNIQUEID}.tif) > exten => s,2,DBGet(EMAILADDR=extensionemail/${MACRO_EXTEN}) > exten => s,3,rxfax(${FAXFILE}) > exten => s,4,Congestion > exten => s,103,SetVar(EMAILADDR=defaultuser@example.com) > exten => s,104,Goto(3) > > 2933975 is the number on which asterisk should listen for new faxes and it > works (in a way that rxfax is being run). > > Info from asterisk console: > > -- Executing Goto("SIP/62.111.174.65-f67004d0", "fax|2201|1") in new > stack > -- Goto (fax,2201,1) > -- Executing Macro("SIP/62.111.174.65-f67004d0", "faxreceive") in new > stack > -- Executing SetVar("SIP/62.111.174.65-f67004d0", > "FAXFILE=/var/spool/asterisk/fax/1138819786.1.tif") in new stack > -- Executing DBget("SIP/62.111.174.65-f67004d0", > "EMAILADDR=extensionemail/2201") in new stack > -- DBget: varname=EMAILADDR, family=extensionemail, key=2201 > -- DBget: set variable EMAILADDR to bpiec@softhis.com > -- Executing RxFAX("SIP/62.111.174.65-f67004d0", > "/var/spool/asterisk/fax/1138819786.1.tif") in new stack > > And that's all. Fax disconnects and there is no > /var/spool/asterisk/fax/1138819786.1.tif file. What can be wrong? > > I saw that people are using 'fax' in extensions.conf (exten => > fax,1,rxfax(${FAXFILE})). When this can be used? It isn't working for > me... > > Maybe it is an issue with Cisco router configuration? Normal calls (not > faxes) from PSTN lines work great... > > I have installed asterisk 1.2.4 and spandsp 0.0.2pre23. >I have almost the same configuration like you. Everything works 100% except I do not have Cisco in between. I use TDM400 FXO card. Check if rxfax actually receives anything... Bartosz
Bartosz Piec
2006-Feb-02 01:51 UTC
[Asterisk-Users] Receiving faxes with spandsp - strange problem
Bartosz Jozwiak wrote:> Check if rxfax actually receives anything...How? -- Best regards, Bartosz Piec
Bartosz Piec
2006-Feb-02 02:19 UTC
[Asterisk-Users] Receiving faxes with spandsp - strange problem
Pierre Burton wrote:> What's your cisco conf ? how did you transfert between Cisco and > asterisk ? A-law, U-law ??This is part of my Cisco config: voice-card 0 no dspfarm ! ! ! voice service voip sip ! ! voice class codec 1 codec preference 1 g711ulaw codec preference 2 g711alaw codec preference 3 g729r8 bytes 40 codec preference 4 g723r63 bytes 96 codec preference 5 g726r16 bytes 80 codec preference 6 g726r24 codec preference 7 g726r32 codec preference 8 g728 codec preference 9 gsmefr codec preference 10 gsmfr voice vad-time 65536 ! voice translation-rule 1 rule 1 /^0?/ // ! voice translation-rule 2 rule 2 /^1?2?/ // voice translation-profile CutTwelve translate called 2 ! voice translation-profile CutZero translate calling 3 translate called 1 voice-port 0/1/0:15 echo-cancel coverage 32 no comfort-noise music-threshold -70 dial-peer voice 1 pots translation-profile outgoing CutZero destination-pattern ^0 direct-inward-dial port 0/1/0:15 ! dial-peer voice 2 voip description Route calls starting with 293 to centile translation-profile outgoing CutTwelve application session destination-pattern 1229339[60-79] voice-class codec 1 session protocol sipv2 session target ipv4:62.111.174.79 dtmf-relay rtp-nte h245-signal h245-alphanumeric ! sip-ua retry invite 3 retry response 3 retry bye 3 retry cancel 3 timers trying 1000 sip-server ipv4:asterisk.ip.add.ress As I understand, the preferred codec is ulaw. Should I change something in this configuration? -- Best regards, Bartosz Piec
Bartosz Piec
2006-Feb-03 04:08 UTC
[Asterisk-Users] Receiving faxes with spandsp - strange problem
Bartosz Jozwiak wrote:> Check if rxfax actually receives anything...How? -- Best regards, Bartosz Piec
Bartosz Piec
2006-Feb-03 04:26 UTC
[Asterisk-Users] Receiving faxes with spandsp - strange problem
Pierre Burton wrote:> What's your cisco conf ? how did you transfert between Cisco and > asterisk ? A-law, U-law ??This is part of my Cisco config: voice-card 0 no dspfarm ! ! ! voice service voip sip ! ! voice class codec 1 codec preference 1 g711ulaw codec preference 2 g711alaw codec preference 3 g729r8 bytes 40 codec preference 4 g723r63 bytes 96 codec preference 5 g726r16 bytes 80 codec preference 6 g726r24 codec preference 7 g726r32 codec preference 8 g728 codec preference 9 gsmefr codec preference 10 gsmfr voice vad-time 65536 ! voice translation-rule 1 rule 1 /^0?/ // ! voice translation-rule 2 rule 2 /^1?2?/ // voice translation-profile CutTwelve translate called 2 ! voice translation-profile CutZero translate calling 3 translate called 1 voice-port 0/1/0:15 echo-cancel coverage 32 no comfort-noise music-threshold -70 dial-peer voice 1 pots translation-profile outgoing CutZero destination-pattern ^0 direct-inward-dial port 0/1/0:15 ! dial-peer voice 2 voip description Route calls starting with 293 to centile translation-profile outgoing CutTwelve application session destination-pattern 1229339[60-79] voice-class codec 1 session protocol sipv2 session target ipv4:62.111.174.79 dtmf-relay rtp-nte h245-signal h245-alphanumeric ! sip-ua retry invite 3 retry response 3 retry bye 3 retry cancel 3 timers trying 1000 sip-server ipv4:asterisk.ip.add.ress As I understand, the preferred codec is ulaw. Should I change something in this configuration? -- Best regards, Bartosz Piec
Matt Riddell (IT)
2006-Feb-03 04:40 UTC
[Asterisk-Users] Receiving faxes with spandsp - strange problem
Bartosz Piec wrote:> Hello, > > I'm trying to receive faxes with asterisk. My configuration is like this:Codec? -- Cheers, Matt Riddell _______________________________________________ http://www.sineapps.com/news.php (Daily Asterisk News - html) http://freevoip.gedameurope.com (Free Asterisk Voip Community) http://www.sineapps.com/rssfeed.php (Daily Asterisk News - rss)