COVESA / capicxx-someip-tools

Common API C++ SOMEIP tooling
Mozilla Public License 2.0
76 stars 55 forks source link

Event id should be encoded with the most significant bit set to 1 in FDEPL #1

Closed pgarnero06 closed 6 years ago

pgarnero06 commented 7 years ago

The SOME/IP Autosar specification AUTOSAR_TR_SomeIpExample_4.2.1.pdf specifies it could support up to 65536 services with up to 32768 methods and up to 32768 notifications/events. So a notification/event identifier should range from 0 to 32767.

The distinction, in SOME/IP messages, between a method id and an event id is made by setting the most significant bit of a 16 bits value (see page 18 in AUTOSAR_TR_SomeIpExample_4.2.1.pdf) to:

However, it seems that the most significant bit should be set for event ids in FDEPL files. So, for example, an event id of 1 should be encoded as 0x8001 when specifying a SomeIpEventID value in a broadcast description,

GenivivSOMEIPmaintainer commented 6 years ago

An event identifier of 1 should not be encoded as 0x8001 but is invalid. Event identifiers range from 0x8000 to 0xFFFE. It is up to the user to define correct identifiers, neither CommonAPI-SOME/IP nor vsomeip will check them.