Thank you all for helping me!
Finally i have my Asterisk 1.4.11 working well.
Hiding ID for some phones, and setting different callIDs for other phones was very hard for me few weeks ago, but now everything looks very easy…
extensions.conf
exten => _X.,10,Gotoif($[${CALLERID(num)}=109]?35:40)
;;; if phone 109 is making a call - goto 35, otherwise goto 40
exten => _X.,35,SetCallerPres(prohib_not_screened)
;;; hide callerID (works on my eicon PRI/30 card)
exten => _X.,36,Dial(CAPI/contr1/${EXTEN})
exten => _X.,40,SET(CALLERID(all)=My company name<5555555>)
;; set caller ID (5555555)
exten => _X.,41,Dial(CAPI/contr1/${EXTEN})
Also, i figured out how asterisk can receive fax messages.
This is part of my extensions.conf for recieving fax messages.
First, when somebody call phone number XXX3499 - asterisk pass that call to [fax]
exten => 3499,1,Goto(fax,s,1)
[fax]
exten => s,1,capicommand(receivefax|/fax/${UNIQUEID}.sff)
;;; Asterisk is recieving fax in file ${UNIQUEID}.sff placed in folder /fax/
exten => h,1,System(sfftobmp -j -f /fax/*.sff)
;;; use sfftobmp to convert from sff to jpg
exten => h,n,System(mv *.jpg /faxIN/)
;;; move .jpg fax in folder /faxIN
exten => h,n,System(rm -f /fax/*)
;; remove .sff file
exten => h,n,System(sam2p /faxIN/*.jpg PDF: /faxPDF/${UNIQUEID}.pdf)
;;; convert fax from .jpg to .pdf using sam2p
exten => h,n,System(rm -f /faxIN/*)
;;; remove .jpg fax file
exten => h,n,System(mv -f /faxPDF/${UNIQUEID}.pdf
/faxPDF/${STRFTIME(${EPOCH},%d-%m-%Y–%H-%M-%S)}.pdf)
;;; rename ${UNIQUEID}.pdf to DD-mm-YY–HH-MM-SS.pdf
exten => h,n,System(ncftpput -u username -p password -P 23 192.168.1.XXX / /faxPDF/${STRFTIME(${EPOCH},%d-%m-%Y–%H-%M-%S)}.pdf)
;;; upload recieved .pdf fax file to user winXP computer using ncftp trought ftp
exten => h,n,System(echo New FAX received! Look file ${STRFTIME(${EPOCH},%d-%m-%Y–%H-%M-%S)}.pdf |smbclient -M hostname -U Asterisk)
;;; send popup message to winXP using smbclient
Maybe this could be usefull for somebody…