Asterisk & DIALPLAN.... HELP ME :)

Hi to all!
I’m newbie with asterisk and i’ve a big question, i hope someone can help me.
I’ve an asterisk that is connected with a trunk sip with a cisco call manager. Some mobile device (Nokia E series) are connected in SCCP to Cisco, some other are connected in SIP to Asterisk.

CCM is the gateway to go out to PSTN line.

I would like to make this. From CCM i dial a mobile phone number (not extension), the call i routed to asterisk, check if this mobile is “registered” and if yes call it, if not (for example is a device external to Cisco and asterisk world) the call comeback to CCM that route it to the PSTN line.

Is it possible? If yes can someone write me a very simple extension.conf so i can learn how to do it? Many thanks to all!!

There is a context in Asterisk SIP configuration file named “regcontextâ€