14-10-2004, 11:36 AM
Dear,
I have to design our new familly product SW platform.
To do this, we have introduce in our design the \"components set\" concept, that gathers components that have the same functionnal behaviour and that are interchangeable.
Let's take the example of a driver: we can have driver1 and driver2 that
are interchangeable, do the same job, and part of the same library. They
present the same interface.
During project instanciation from the SW platform, we choose one of them. To manage this, we plan to have a definition of the include file to avoid modifying a generic component that would call these drivers.
and in all the components that use this driver, we plan to include the
appropriate header file this way:
Is this a violation of the MISRA rule 89 ?
Defining the header file this way:
Is this a violation of the MISRA rule 89 ?
Thank you for your answer.
Best regards
Laurent Perron
I have to design our new familly product SW platform.
To do this, we have introduce in our design the \"components set\" concept, that gathers components that have the same functionnal behaviour and that are interchangeable.
Let's take the example of a driver: we can have driver1 and driver2 that
are interchangeable, do the same job, and part of the same library. They
present the same interface.
During project instanciation from the SW platform, we choose one of them. To manage this, we plan to have a definition of the include file to avoid modifying a generic component that would call these drivers.
Code:
#define COMP_DRIVER \"driver1.h\"
and in all the components that use this driver, we plan to include the
appropriate header file this way:
Code:
#include COMP_DRIVER
Is this a violation of the MISRA rule 89 ?
Defining the header file this way:
Code:
#define COMP_DRIVER \"../driver1/driver1.h\"
Is this a violation of the MISRA rule 89 ?
Thank you for your answer.
Best regards
Laurent Perron
<t></t>