[erlang-questions] ASN.1 multiple records

Abd El-Fattah Mahran <>
Mon Feb 10 10:18:23 CET 2014

Dear Rimon,

Consider you have SDCDR.asn and ASN1 configuration file SDCDR.asn1config

*** Compile .asn File*
asn1ct:compile("SDCDR", [ber_bin, optimize, verbose, driver, undec_rest]).

*** Compile .asn File with configuration file .asn1config*
asn1ct:compile("SDCDR", [ber_bin, optimize, verbose, driver, asn1config,

*** Steps For decoding .asn file*
{ok, F} = file:read_file("SDPCDR_sdp01a.ASN").

{ok, {lifeCycleChange, LifeCycleChange}, Rest} =
'SDCDR':decode('SDPCallDataRecord', F).

*** Use Rest Variable to get the Rest of the data.*
{ok, {accountAdjustment, AccountAdjustment}, Rest1} =
'SDCDR':decode('SDPCallDataRecord', Rest).

best regards,

On Sun, Feb 9, 2014 at 3:07 PM, Rimon Farouk <> wrote:

> Dears;
> I've succeeded in reading ASN.1 binary files containing single message,
> but how can i read an ASN.1 binary file containing multiple messages?
> I cannot find sufficient resources for Erlang dealing with ASN.1 files.
> Kindly help.
> Thanks a lot ...
> Best regards ...
> Rimon
> _______________________________________________
> erlang-questions mailing list
> http://erlang.org/mailman/listinfo/erlang-questions

Best Regards,
Abd El-Fattah Mahran
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20140210/12456d71/attachment.html>

More information about the erlang-questions mailing list