asn1c icon indicating copy to clipboard operation
asn1c copied to clipboard

FATAL error: component xxx at line xxx has the same tag as component xxx at line xxx

Open sandman opened this issue 4 years ago • 2 comments

Hi,

I am getting a same tag error while compiling my asn schema. This is similar to #291 that @velichkov very kindly resolved.

I followed the instructions there (Added AUTOMATIC TAGS and passed compilation options -fcompound-names -pdu=all.

The command I used is: asn1c -fcompound-names -pdu=all ISO_TS_14906_v6.asn ISO_TS_14906_generic_v7.asn ISO_TS_14816.asn

This is the error I get:

FATAL: Processing Action-Response at line 41: component "iid" at line 43 has the same tag as component "ret" at line 45 in ISO_TS_14906_generic_v7.asn FATAL: Consider adding AUTOMATIC TAGS after module EfcDsrcGeneric DEFINITIONS, or manually tag components in ISO_TS_14906_generic_v7.asn FATAL: Processing Get-Response at line 285: component "iid" at line 287 has the same tag as component "ret" at line 289 in ISO_TS_14906_generic_v7.asn FATAL: Consider adding AUTOMATIC TAGS after module EfcDsrcGeneric DEFINITIONS, or manually tag components in ISO_TS_14906_generic_v7.asn

I am unable to make sense of this.

Any help will be much appreciated.

Attached the asn1 schema (renamed to .txt)

ISO_TS_14816.asn.txt ISO_TS_14906_generic_v7.asn.txt ISO_TS_14906_v6.asn.txt

sandman avatar Apr 27 '20 18:04 sandman

Ok, I got it to work by adding manual tags for both of those components. No idea why the AUTOMATIC TAGS directive doesn't work. Maybe it has something to do with the Request/Response grammar (ROSE)?

sandman avatar Apr 28 '20 17:04 sandman

@sandman I am also facing the same issue. Can you please share the ASN.1 after manual tagging ?

keyankay avatar Feb 02 '21 12:02 keyankay