riebl / vanetza

Open-source implementation of the ETSI C-ITS protocol stack
Other
197 stars 157 forks source link

Receiving real CAM from Autotalks devices with Vanetza #193

Open lo-hei opened 11 months ago

lo-hei commented 11 months ago

I have had an issue in the past where I was helped very well by @Irisbus in particular. I would like to thank you and @riebl again.

Some time has passed and my project has progressed with a custom application based on the Vanetza stack. I have had two Autotalks EVK (SDK 5.17) exchange CAM with each other. This also works without any problems. But now I would like to receive CAM from other Autotalks devices or real V2X-Cars (e.g. ZooZ or VW ID3). However, for some reason I cannot explain, they do not pass through the Vanetza stack and cannot be received. As I said, if I use two EVK with Vanetza stack, it works. I have verified that all devices are transmitting on the same frequency and messages on the radio frequency are also arriving and being registered (There is an application called diag-cli that registers incoming transmissions. There I see incoming messages on the EVK from ZooZ).

Probably the question is directed to @Irisbus. Since you also work with autotalks, did you happen to receive CAM messages from other devices? Are you aware of any limitations of the Vanetza stack that prevents getting CAMs from other devices? (E.g. missing certificates or incompatibility between the Vantza stack and that of Comsignia)?

Thank you very much for the help. Maybe someone has already tried something similar.

apgeorg commented 11 months ago

Hey @lo-hei, I think if the "real" V2X-Cars can turn off their security it should work. There is some work in progress in vanetza in that topic ;)

Recently we did some communication tests with our own custom devices (autotalks chipset + vanetza) and series devices (security off), cars etc. and it worked well!

lo-hei commented 11 months ago

Thank @apgeorg you for your answer and the help.

I only have one question regarding this. I would like to receive messages on an EVK (Craton2 + Vanetza) (I'm actually primarily focused on receiving). If I do not to turn off the security feature on the transmitters (i.e. on the ZooZ or on the real car), shouldn't I get at least non-decodable messages on the EVK? In the Vanetza implementation there is also an If-Statement and Print that non-decodable messages were received. But I don't get that either.

khevessy commented 11 months ago

Hi @lo-hei, when I tested communication on a road with real devices, I recall that I encountered two problems that I could solve:

Third problem that I could not solve yet was that Vanetza for now implements security encapsulation/decapsulation per ETSI standards TS 103 097 v1.2.1. All the devices I encountered when testing used ETSI TS 103 097 v1.3.1 or v2.1.1, which is not backwards compatible. Vanetza will refuse to decapsulate messages that have protocol version != 2 (i think that it refers to 1.2.1 and it is returned by SecuredMessage::protocol_version()).

I think that your problem might be related to the EtherType problem I mentioned, though, as you mention that you do not receive absolutely anything.

Coming back to security, @apgeorg, do you have any closer info about progress on implementing newer security layer? My understanding is that it was implemented by JordiMarias in #130, now the branch sec_v2_namespace is almost done, only thing left is separating the older version to separate namespace. As we want to use Vanetza with the newer security to be compatible with other devices, we are prepared to do the work needed ourselves, and I asked Mr. Riebl in #192 before looking at the code closer. Maybe @lo-hei would help with the implementation too, as you seem to also want to use this functionality?

firolino commented 11 months ago

@Irisbus Raphael is working on it right now and 1.3.1 will be released shortly! Afterwards we will release the PKI handling for it as well. Stay tuned :)

khevessy commented 11 months ago

@firolino Thanks for quick and hopeful response! I will look forward to the release.

firolino commented 11 months ago

@lo-hei As @apgeorg has mentioned, we are working successfully with multitude of CRATON2 EVKs and also custom products equipped with Autotalks chipssets (SECTON+PLUTON). Despite the security and @Irisbus hints, please respect also the communication parameters listed here in order to communicate with e.g. VW: https://www.car-2-car.org/fileadmin/documents/Basic_System_Profile/Release_1.6.2/C2CCC_RS_2037_Profile.pdf

lo-hei commented 11 months ago

Thank you very much. I will stay tuned and look forward to test the communication between EVK and other devices :)

After following the hint by @Irisbus and set .protocol_id socket EtherType to 0x8947 i finally receive the data-packages. But - like expected - Vanetza is not able to decode it.

mabroens commented 10 months ago

Hi All,

I have just updated to the latest and the RX seems now working. I am using NXP chipsets but that should not matter and im able to receive real messages from VW passing in the street.

TX security is not yet done though. But at least i can now see that its not dropping the rx messages.