My incoming config has a NoOp statement to display the cid and some info about the call in the status on the console. I will change the code to do a more generic statement to display the cid both before and after the answer just to see. Here is the most current code that I have been playing with…
[inbound]
include => faxes-in
include => vm-in
;Generic inbound context
exten => s,1,Wait(10) ; Delay for caller id detection
exten => s,n,Answer() ; Actually answer the call
exten => s,n,PlayTones(ring) ; "Comfort ringing" during fax detection
exten => s,n,Wait(5) ; Delay for fax detection
exten => s,n,GotoIf($["X${CALLERID(num)}" = "X"]?inbound,s-inv,1) ; Checks for unidentified calls
exten => s,n,GotoIf(${DB_EXISTS(blacklist/${CALLERID(num)})}?inbound,s-blk,1) ; Checks for blacklisted numbers
exten => s,n,GotoIf(${DB_EXISTS(blacklist/${CALLERID(name)})}?inbound,s-blk,1) ; Checks for blacklisted names
exten => s,n,GotoIf(${DB_EXISTS(whitelist/${CALLERID(num)})}?inbound,s-wht,1) ; Checks for whitelisted numbers
exten => s,n,GotoIf(${DB_EXISTS(whitelist/${CALLERID(name)})}?inbound,s-wht,1) ; Checks for whitelisted names
exten => s,n,Goto(inbound,s-cid,1)
;Inbound calls without caller id
exten => s-inv,1,NoOp(Incoming call with invalid Caller ID info)
exten => s-inv,n,PlayTones(info)
exten => s-inv,n,Wait(1)
exten => s-inv,n,Playback(were-sorry)
exten => s-inv,n,Playback(privacy-unident)
exten => s-inv,n,Playback(please-hang-up-and-try-again)
exten => s-inv,n,Congestion()
;Inbound blacklisted calls
exten => s-blk,1,NoOp(Incoming Blacklist Call - ${CALLERID(all)})
exten => s-blk,n,PlayTones(info)
exten => s-blk,n,Wait(1)
exten => s-blk,n,Playback(were-sorry)
exten => s-blk,n,Playback(privacy-you-are-blacklisted)
exten => s-blk,n,Playback(privacy-stop-calling-not-welcome2)
exten => s-blk,n,Congestion()
;Inbound whitelisted calls
exten => s-wht,1,NoOp(Incoming Whitelist Call - ${CALLERID(all)})
exten => s-wht,n,Goto(inbound,s-pass,1) ; Process call
;Inbound calls with proper caller id
exten => s-cid,1,NoOp(Incoming Call - ${CALLERID(all)})
exten => s-cid,n,Zapateller() ; Oblitterate telemarketers
exten => s-cid,n,GotoIf(${DB(Features/GlobalTC)}=0?inbound,s-pass,1) ; Check if time conditions active
exten => s-cid,n,GotoIfTime(22:00-07:00|*|*|*?vm-in,vm,1) ; No ringing from 10p-7a daily
exten => s-cid,n,GotoIfTime(07:00-17:00|mon-fri|*|*?vm-in,vm,1) ; No ringing from 7a-5p weekdays
exten => s-cid,n,Goto(inbound,s-pass,1) ; Process call
;Process calls
exten => s-pass,1,GotoIf(${DB(Features/GlobalDND)}=1?vm-in,vm,1) ; Check if global DND active
exten => s-pass,n,Playback(pls-wait-connect-call)
exten => s-pass,n,Dial(SIP/100,45,tmro) ; Dial internal extens
exten => s-pass,n,Goto(vm-in,vm,1)
And here is an excerpt of a call that has no cid. I called home from work just today…
-- Starting simple switch on 'Zap/1-1'
-- Executing Wait("Zap/1-1", "10") in new stack
-- Executing Answer("Zap/1-1", "") in new stack
-- Executing PlayTones("Zap/1-1", "ring") in new stack
-- Executing Wait("Zap/1-1", "5") in new stack
-- Executing GotoIf("Zap/1-1", "1?inbound|s-inv|1") in new stack
-- Goto (inbound,s-inv,1)
-- Executing NoOp("Zap/1-1", "Incoming call with invalid Caller ID info") in new stack
-- Executing PlayTones("Zap/1-1", "info") in new stack
-- Executing Wait("Zap/1-1", "1") in new stack
-- Executing Playback("Zap/1-1", "were-sorry") in new stack
-- Playing 'were-sorry' (language 'en')
-- Executing Playback("Zap/1-1", "privacy-unident") in new stack
-- Playing 'privacy-unident' (language 'en')
-- Executing Playback("Zap/1-1", "please-hang-up-and-try-again") in new stack
-- Playing 'please-hang-up-and-try-again' (language 'en')
-- Executing Congestion("Zap/1-1", "") in new stack
== Spawn extension (inbound, s-inv, 7) exited non-zero on 'Zap/1-1'
-- Hungup 'Zap/1-1'
Here is the console log of a successful call, this is from my cell phone to home (cell number obfuscated)…
-- Starting simple switch on 'Zap/1-1'
-- Executing Wait("Zap/1-1", "10") in new stack
-- Executing Answer("Zap/1-1", "") in new stack
-- Executing PlayTones("Zap/1-1", "ring") in new stack
-- Executing Wait("Zap/1-1", "5") in new stack
-- Executing GotoIf("Zap/1-1", "0?inbound|s-inv|1") in new stack
-- Executing GotoIf("Zap/1-1", "0?inbound|s-blk|1") in new stack
-- Executing GotoIf("Zap/1-1", "0?inbound|s-blk|1") in new stack
-- Executing GotoIf("Zap/1-1", "1?inbound|s-wht|1") in new stack
-- Goto (inbound,s-wht,1)
-- Executing NoOp("Zap/1-1", "Incoming Whitelist Call - "CELLULAR CALL" <937XXXXXXX>") in new stack
-- Executing Goto("Zap/1-1", "inbound|s-pass|1") in new stack
-- Goto (inbound,s-pass,1)
-- Executing GotoIf("Zap/1-1", "0=1?vm-in|vm|1") in new stack
-- Executing Playback("Zap/1-1", "pls-wait-connect-call") in new stack
-- Playing 'pls-wait-connect-call' (language 'en')
-- Executing Dial("Zap/1-1", "SIP/100|45|tmro") in new stack
-- Called 100
-- Started music on hold, class 'default', on Zap/1-1
-- SIP/100-08cdff58 is ringing
-- Nobody picked up in 45000 ms
-- Stopped music on hold on Zap/1-1
-- Executing Goto("Zap/1-1", "vm-in|vm|1") in new stack
-- Goto (vm-in,vm,1)
-- Executing Wait("Zap/1-1", "1") in new stack
== Spawn extension (vm-in, vm, 1) exited non-zero on 'Zap/1-1'
-- Hungup 'Zap/1-1'
And finally, my zapata.conf file…
[channels]
;Channel defaults
usecallerid=yes
hidecallerid=no
cidsignalling=bell
callerid=asreceived
cidstart=ring
sendcalleridafter=1
usecallingpres=yes
faxdetect=incoming
callwaiting=no
threewaycalling=no
transfer=no
echocancel=yes
echotraining=yes
immediate=no
hanguponpolarityswitch=yes
musiconhold=default
;Channel definitions
context=inbound
signalling=fxs_ks
rxgain=12.5
txgain=3.0
group=1
channel => 1
All the adjustments in the zapata.conf are from things that I have been able to find on the internet from various * faqs, wikis and such. I’ve changed the rxgain up and down, and none of the variances affected reception of cid from those numbers that seem to send cid correctly. The only things that I can think of that there could be wrong is the caller id string comparator at the 5th line of ‘s’ exten…beats me, though.
Of everything in asterisk, this is the only thing that has given me fits. Everything else works perfectly. I can even do stuff that my Nortel Option 11c at work can’t do…and * is a LOT easier to program! 
Thanks everyone for a great forum and great software!
Mike