<div>First, try this
                </div><div><br></div><div><div>init(Node) -&gt;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {foo, Node} ! register_event_handler,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {event, Node} ! {event, 'ALL'}.</div></div><div><br></div><div><br></div><div>register_event_handler will tell FS to send all events back to the *current* process, so you can get all events by using flush().</div><div><br></div><div>2) If you want to coming events send to a dedicated PID, spawn a process and then send the following message in that process</div><div><br></div><div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {foo, Node} ! register_event_handler,</div></div><div><br></div><div><br></div><div>IN your case, you might want this:</div><div><br></div><div><div>loop() -&gt;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {foo, Node} ! register_event_handler,</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; {event, Node} ! {event, 'ALL'},</div><div><br></div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; receive</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;stop -&gt;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;ok;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;_Anything -&gt;</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;io:format("received ~p~n", [_Anything]),</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;loop()</div><div>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; end.</div></div><div><br></div><div><br></div><div><br></div><div>3) Anyway, try read the freeswitch.erl in the source tree to understand more.</div><div><br></div>
                <div><div><br></div><div>--&nbsp;</div><div>Seven Du</div><div>Sent with <a href="http://www.sparrowmailapp.com/?sig">Sparrow</a></div><div><br></div></div>
                 
                <p style="color: #A0A0A8;">On Monday, December 31, 2012 at 9:12 PM, Gerald Weber wrote:</p>
                <blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px;">
                    <span><div><div><meta http-equiv="Content-Type" content="text/html; charset=us-ascii"><meta name="Generator" content="Microsoft Word 14 (filtered medium)"><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--><div><p style="margin: 0px; "><span style="color:#1F497D">Some more infos:<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">Changed the init/1 function to:<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">init(Node) -&gt;<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {foo, Node} ! register_event_handler,<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {foo, Node} ! register_log_handler,<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {foo, Node} ! {event, 'ALL'},<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {foo, Node} ! {set_log_level, debug}.<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">Now the „invalid process type“ error message disappeared, but i still dont get any events.<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">Some erlang console command outputs:<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">freeswitch@fstest&gt; erlang listeners<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">Listener to <a href="mailto:test33@freeswitch.besharp.at">test33@freeswitch.besharp.at</a> with 0 outbound sessions<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">freeswitch@fstest&gt; erlang bindings<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">No bindings<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">freeswitch@fstest&gt; erlang handlers<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">Listener <a href="mailto:test33@freeswitch.besharp.at">test33@freeswitch.besharp.at</a>:<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">--------------------------------<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CLONE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_CREATE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_DESTROY<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_STATE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_CALLSTATE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_ANSWER<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_HANGUP<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_HANGUP_COMPLETE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_EXECUTE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_EXECUTE_COMPLETE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_HOLD<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_UNHOLD<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_BRIDGE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_UNBRIDGE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_PROGRESS<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_PROGRESS_MEDIA<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_OUTGOING<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_PARK<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_UNPARK<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_APPLICATION<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_ORIGINATE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_UUID<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">API<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">LOG<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">INBOUND_CHAN<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">OUTBOUND_CHAN<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">STARTUP<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">SHUTDOWN<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">PUBLISH<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">UNPUBLISH<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">TALK<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">NOTALK<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">SESSION_CRASH<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">MODULE_LOAD<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">MODULE_UNLOAD<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">DTMF<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">MESSAGE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">PRESENCE_IN<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">NOTIFY_IN<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">PRESENCE_OUT<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">PRESENCE_PROBE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">MESSAGE_WAITING<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">MESSAGE_QUERY<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">ROSTER<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CODEC<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">BACKGROUND_JOB<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">DETECTED_SPEECH<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">DETECTED_TONE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">PRIVATE_COMMAND<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">HEARTBEAT<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">TRAP<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">ADD_SCHEDULE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">DEL_SCHEDULE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">EXE_SCHEDULE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">RE_SCHEDULE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">RELOADXML<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">NOTIFY<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">SEND_MESSAGE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">RECV_MESSAGE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">REQUEST_PARAMS<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CHANNEL_DATA<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">GENERAL<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">COMMAND<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">SESSION_HEARTBEAT<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CLIENT_DISCONNECTED<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">SERVER_DISCONNECTED<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">SEND_INFO<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">RECV_INFO<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">RECV_RTCP_MESSAGE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CALL_SECURE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">NAT<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">RECORD_START<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">RECORD_STOP<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">PLAYBACK_START<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">PLAYBACK_STOP<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CALL_UPDATE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">FAILURE<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">SOCKET_DATA<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">MEDIA_BUG_START<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">MEDIA_BUG_STOP<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CONFERENCE_DATA_QUERY<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CONFERENCE_DATA<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CALL_SETUP_REQ<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CALL_SETUP_RESULT<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">CUSTOM:<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">Thanks<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D">gw<o:p></o:p></span></p><p style="margin: 0px; "><span style="color:#1F497D"><o:p>&nbsp;</o:p></span></p><div><div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm"><p style="margin: 0px; "><b><span lang="DE" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;mso-fareast-language:DE-AT">Von:</span></b><span lang="DE" style="font-size:10.0pt;font-family:&quot;Tahoma&quot;,&quot;sans-serif&quot;;mso-fareast-language:DE-AT"> freeswitch-users-bounces@lists.freeswitch.org [<a href="mailto:freeswitch-users-bounces@lists.freeswitch.org">mailto:freeswitch-users-bounces@lists.freeswitch.org</a>] <b>Im Auftrag von </b>Gerald Weber<br><b>Gesendet:</b> Montag, 31. Dezember 2012 13:30<br><b>An:</b> <a href="mailto:freeswitch-users@lists.freeswitch.org">freeswitch-users@lists.freeswitch.org</a><br><b>Betreff:</b> [Freeswitch-users] mod_event_erlang and invalid process type<o:p></o:p></span></p></div></div><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">Hi all,<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">trying to learn erlang i tried to connect to freeswitch using mod_event_erlang and receive some events:<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">erlang shell:<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">[root@fstest ~]# erl -name <a href="mailto:test33@freeswitch.besharp.at">test33@freeswitch.besharp.at</a> -setcookie ClueCon<o:p></o:p></p><p style="margin: 0px; ">Erlang R15B03 (erts-5.9.3.1) [source] [64-bit] [smp:2:2] [async-threads:0] [hipe] [kernel-poll:false]<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">Eshell V5.9.3.1&nbsp; (abort with ^G)<o:p></o:p></p><p style="margin: 0px; ">(<a href="mailto:test33@freeswitch.besharp.at)1">test33@freeswitch.besharp.at)1</a>&gt; Pid = fsevents:start().<o:p></o:p></p><p style="margin: 0px; ">&lt;0.46.0&gt;<o:p></o:p></p><p style="margin: 0px; ">(<a href="mailto:test33@freeswitch.besharp.at)2">test33@freeswitch.besharp.at)2</a>&gt; fsevents:init('<a href="mailto:freeswitch@freeswitch.besharp.at">freeswitch@freeswitch.besharp.at</a>').<o:p></o:p></p><p style="margin: 0px; ">{event,'ALL'}<o:p></o:p></p><p style="margin: 0px; ">(<a href="mailto:test33@freeswitch.besharp.at)3">test33@freeswitch.besharp.at)3</a>&gt;<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">Console output:<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">2012-12-31 13:18:36.900506 [DEBUG] handle_msg.c:301 ALL events enabled<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:18:36.900506 [DEBUG] handle_msg.c:314 enable event ALL<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:18:51.480577 [ERR] ei_helpers.c:274 Invalid process type 0! ((null),, &lt;0.0.0&gt;)<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:18:51.480577 [ERR] ei_helpers.c:274 Invalid process type 0! ((null),, &lt;0.0.0&gt;)<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:18:51.500492 [ERR] ei_helpers.c:274 Invalid process type 0! ((null),, &lt;0.0.0&gt;)<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">Can anyone tell me what i’m doing wrong ? Console log keeps saying invalid process type (until i kill the erlang process)<o:p></o:p></p><p style="margin: 0px; ">and i dont receive any events.<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">Erlang Version: 5.9.3.1<o:p></o:p></p><p style="margin: 0px; ">Freeswitch: latest HEAD from 2012-12-31 <o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">The fsevents module:<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">-module(fsevents).<o:p></o:p></p><p style="margin: 0px; ">-export([start/0, init/1, loop/0]).<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">start() -&gt;<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Pid = spawn(?MODULE, loop, []),<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; register(?MODULE,Pid),<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; Pid.<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <o:p></o:p></p><p style="margin: 0px; ">init(Node) -&gt;<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; {foo, Node} ! {event, 'ALL'}.<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <o:p></o:p></p><p style="margin: 0px; ">loop() -&gt;<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; receive<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; stop -&gt;<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ok;<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; _Anything -&gt;<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; io:format("received ~p~n", [_Anything]),<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; loop()<o:p></o:p></p><p style="margin: 0px; ">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; end.<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">The communication seems to work basically:<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">(<a href="mailto:test33@freeswitch.besharp.at)4">test33@freeswitch.besharp.at)4</a>&gt; {foo, <a href="mailto:freeswitch@freeswitch.besharp.at">freeswitch@freeswitch.besharp.at</a>} ! {api, status, ""}.<o:p></o:p></p><p style="margin: 0px; ">{api,status,[]}<o:p></o:p></p><p style="margin: 0px; ">(<a href="mailto:test33@freeswitch.besharp.at)5">test33@freeswitch.besharp.at)5</a>&gt; receive Y -&gt; Y after 1000 -&gt; timeout end.<o:p></o:p></p><p style="margin: 0px; ">{ok,"UP 0 years, 0 days, 1 hour, 20 minutes, 52 seconds, 534 milliseconds, 225 microseconds\nFreeSWITCH (Version 1.3.13b git 8859eb0 2012-12-30 19:08:55Z) is ready\n0 session(s) since startup\n0 session(s) - 0 out of max 30 per sec \n1000 session(s) max\nmin idle cpu 0.00/99.00\nCurrent Stack Size/Max 240K/8192K\n"}<o:p></o:p></p><p style="margin: 0px; ">(<a href="mailto:test33@freeswitch.besharp.at)3">test33@freeswitch.besharp.at)3</a>&gt;<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">Console output:<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">freeswitch@fstest&gt; load mod_erlang_event<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [INFO] mod_enum.c:872 ENUM Reloaded<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [INFO] switch_time.c:1165 Timezone reloaded 530 definitions<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [DEBUG] mod_erlang_event.c:1816 sections 16<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [CONSOLE] switch_loadable_module.c:1348 Successfully Loaded [mod_erlang_event]<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [NOTICE] switch_loadable_module.c:254 Adding Application 'erlang'<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [NOTICE] switch_loadable_module.c:254 Adding Application 'erlang_sendmsg'<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [NOTICE] switch_loadable_module.c:298 Adding API Function 'erlang'<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">+OK Reloading XML<o:p></o:p></p><p style="margin: 0px; ">+OK<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [DEBUG] mod_erlang_event.c:1915 Socket 48 up listening on 0.0.0.0:8031<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:21.420611 [DEBUG] mod_erlang_event.c:1946 Connected to epmd and published erlang cnode at <a href="mailto:freeswitch@freeswitch.besharp.at">freeswitch@freeswitch.besharp.at</a><o:p></o:p></p><p style="margin: 0px; ">freeswitch@fstest&gt; 2012-12-31 13:17:43.380527 [DEBUG] mod_erlang_event.c:1986 Launching listener, connection from node <a href="mailto:test33@freeswitch.besharp.at">test33@freeswitch.besharp.at</a>, ip 192.168.20.73<o:p></o:p></p><p style="margin: 0px; ">2012-12-31 13:17:43.380527 [DEBUG] mod_erlang_event.c:1009 Connection Open from 192.168.20.73<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p><p style="margin: 0px; ">Thanks / regards and Happy New Year <span style="font-family:Wingdings">J</span><o:p></o:p></p><p style="margin: 0px; ">Gw<o:p></o:p></p><p style="margin: 0px; "><o:p>&nbsp;</o:p></p></div></div><div><div>_________________________________________________________________________</div><div>Professional FreeSWITCH Consulting Services:</div><div><a href="mailto:consulting@freeswitch.org">consulting@freeswitch.org</a></div><div><a href="http://www.freeswitchsolutions.com">http://www.freeswitchsolutions.com</a></div><div><br></div><div>FreeSWITCH-powered IP PBX: The CudaTel Communication Server</div><div><a href="http://www.cudatel.com">http://www.cudatel.com</a></div><div><br></div><div>Official FreeSWITCH Sites</div><div><a href="http://www.freeswitch.org">http://www.freeswitch.org</a></div><div><a href="http://wiki.freeswitch.org">http://wiki.freeswitch.org</a></div><div><a href="http://www.cluecon.com">http://www.cluecon.com</a></div><div><br></div><div>FreeSWITCH-users mailing list</div><div><a href="mailto:FreeSWITCH-users@lists.freeswitch.org">FreeSWITCH-users@lists.freeswitch.org</a></div><div><a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a></div><div>UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a></div><div><a href="http://www.freeswitch.org">http://www.freeswitch.org</a></div></div></div></span>
                 
                 
                 
                 
                </blockquote>
                 
                <div>
                    <br>
                </div>