riebl / artery

OMNeT++ V2X simulation framework for ETSI ITS-G5
GNU General Public License v2.0
202 stars 128 forks source link

Equip services to vehicles #331

Open alizz-99 opened 3 months ago

alizz-99 commented 3 months ago

Hi! I am trying to equip my own service to vehicles, and I want to filter it according to their type. For example, only equip cars that are "car-shuttle" type. I do it in the following way:

<services>
    <service type="CarService">
        <listener port="2001" />
        <filters><type pattern="car-shuttle" /></filters>.
    </service>
</services>

but then no car is equipped with my CarService. In filters, the type tag is used for that?

Thank you very much!

riebl commented 3 months ago

Example usage at https://github.com/riebl/artery/blob/ef807a74fd2eba48abd2c31b4a7f5a8a895a9027/scenarios/artery/services.xml#L6

The type filter checks the module type of the host entities.