Erlang, C, IC and asyncronous servers/clients
Kenneth Lundin
kenneth@REDACTED
Tue Feb 27 15:30:03 CET 2001
Hi,
I think there is an easy solution where you define 2 interfaces, one for
each
direction and use the same transportation channel for both.
/Kenneth
Jouni Ryno wrote:
>
> The current IC-system seems to generated code only for cases, were
> communication is initiated from only one side. I would need to port
> some older code, which used IG in more asynchronous way (yes, I know,
> it was not completely safe).
>
> In detail I have
> Erlang side C side
> raw telemetry -> data processing, packet detection
> when packet found from raw telemetry
> <- packet_type_X
> <- packet_type_Y
> <- up to N packets
>
> C-process receives binary chunks from Erlang, whenever it finds a
> valid, complete packet, it sends it to Erlang-process for further
> distribution. The catch is, there's n packets to generate, so simple
> function return values is not adequate.
>
> At least the IC examples for C-server and -client don't allow this kind
> of two-way message sending.
>
> So to put it simply, is there a way to do it ?
>
> (and yes, the I could the processing in Erlang, but we also have to
> give out source code for colleagues to analyze data later. Erlang is
> used in real time situation )
>
> Jouni Rynö mailto://Jouni.Ryno@fmi.fi/
> http://www.geo.fmi.fi/~ryno/
> Finnish Meteorological Institute http://www.fmi.fi/
> Geophysical Research http://www.geo.fmi.fi/
> P.O.BOX 503 Tel (+358)-9-19294656
> FIN-00101 Helsinki GSM (+358)-50-5302903
> Finland FAX (+358)-9-19294603
>
> "It's just zeros and ones, it cannot be hard"
--
Kenneth Lundin Ericsson Utvecklings AB
kenneth@REDACTED ÄT2/UAB/F/P
BOX 1505
+46 8 727 57 25 125 25 Älvsjö
More information about the erlang-questions
mailing list