Multiple calls in case of emergency

I would like to implement a multi-party call system …

In case of emergency (eg fire) my asterisk must automatically call:
Me, my colleagues, the firemen, the police …

Where do I start ?

You could look at the code for Reminders or Wake Up Calls and write a script to do something similar, except triggered by your event rather than at a specific time.

However, I strongly recommend that you get real monitoring service for your security system. For example, in the US several UL-certified companies provide service for $15 per month or less.

In many countries, police may not dispatch on receipt of an automated call. If they do, and it’s a false alarm, you will likely be fined. If this happens several times, they may not respond when you have a real emergency.

On receipt of an alarm signal, a monitoring company will normally first try to reach you at the monitored location, giving you a chance to say “sorry, the smoke detector was triggered by a cooking accident”. If their confirmation call is unanswered or the person who answers doesn’t know the correct password, they will call the proper authorities on a special emergency number for dispatch.

In Italy is normal to do automated calls to police…

The main goal for me (for now) will be a call to me… then all my colleagues.

I am trying to use ivr, and then the “originate” command…
But I need to have a feedback from asterisk. Because if I originate ten calls, but I have two pstn lines, only two calls will be enstablished… and I cannot know it !!

I think I must to ask Asterisk if there are free outbound channels… then originate the first channel… then wait tha first call is finished (or timeout expired)… then go to the second call…(and continue)

If you call Originate with the Async parameter, it will return quickly and you can request multiple concurrent calls. You’ll then be notified with OriginateResponse events; your script would reschedule failed calls a few seconds later.

Alternatively, you could use a Status command (or something specific to channel type) to see what channels are in use and wait appropriately.

Another approach would be a VoIP service to handle the overflow, so you could do ten calls at once. This could be useful for non-emergency calls, too. Instead of waiting for a line to become free, you’d pay a small per-minute charge and get through right away. Several good VoIP providers have rates to Italy landlines less than €0.01; mobiles are less than €0.03.

Google asterisk call files. I would verify with your local psap that these calls are i
appropriate. And what they should contain. What initiates the calls?

You should take a look at the Page Pro Module, it allows you to place hooks into outbound routes, that will notify a paging group. For example if someone were to call 911 (or a local emergency number.) The system would automatically ring the page group at the same time, and allows for members of that page group to listen to the call, and barge in and speak if necessary. Of course the Page Pro module also adds a lot of other functions such as Valet style paging, and Scheduled Paging.