HelloWorldSubscriber_on_subscription_matched Not Work

2 posts / 0 new
Last post
Offline
Last seen: 1 year 7 months ago
Joined: 01/03/2023
Posts: 10
HelloWorldSubscriber_on_subscription_matched Not Work

Hi,

I'm working on the DDS Micro.

I add a function to get DDS_ParticipantBuiltinTopicData in the HelloWorld_dpde example. So the basic steps are:

 1. Print new found participant info (e.g. DCPS key) by install the listenser :

builtin_participant_listener.on_data_available = BuiltinParticipantListener_on_data_available;

retcode = DDS_DataReader_set_listener( builtin_participant_datareader, &builtin_participant_listener, DDS_DATA_AVAILABLE_STATUS);

2. Start normal Pub/Sub workflow:

on publisher:

datawriter_listener.on_publication_matched = HelloWorldPublisher_on_publication_matched;

on subscriber:

datareader_listener.on_data_available = HelloWorldSubscriber_on_data_available;
datareader_listener.on_subscription_matched = HelloWorldSubscriber_on_subscription_matched;

The problem I got is if I enable the builtin_participant_listener, the publisher sends samples as normal but no data received by the subscriber, without showing any errors. If I disable the builtin_participant_listener, pub/sub works ok.

Could anyone help to figure this problem please?

Thanks a lot.

Qian

 

Organization:
Offline
Last seen: 1 year 7 months ago
Joined: 01/03/2023
Posts: 10

Hi,

I'm stil getting this bug unsolved.

Whenever I enable the DataReaderLister for the ParticipantBuiltinTopic on the publisher, the normal data pub/sub cannot start as no matching between the publisher and subscriber.

The ParticipantBuiltinTopic can be printed out with no error.

Is there anything to be set when using the DataWriterListener for normal data together with the DataReaderListenser for built-in topic?

Appreciated for any help.

 

Qian