Qurt uORB communicator fixes (#20705)

- there was an issue sending a message from slpi to apps. Seems the code was stuck in an loop and crashed when the message was sent from slpi to apps
This commit is contained in:
Zachary Lowell
2022-12-06 09:33:19 -06:00
committed by GitHub
parent 1ea026961e
commit 91acd494a3
7 changed files with 60 additions and 122 deletions
@@ -99,7 +99,7 @@ void uORB::AppsProtobufChannel::AdvertiseCallback(const char *topic)
return;
} else if (_RxHandler) {
_RxHandler->process_remote_topic(topic, true);
_RxHandler->process_remote_topic(topic);
} else {
PX4_ERR("Couldn't handle topic %s in advertise callback", topic);
@@ -119,7 +119,7 @@ void uORB::AppsProtobufChannel::SubscribeCallback(const char *topic)
_SlpiSubscriberCache[topic]++;
pthread_mutex_unlock(&_rx_mutex);
_RxHandler->process_add_subscription(topic, 1000);
_RxHandler->process_add_subscription(topic);
} else {
PX4_ERR("Couldn't handle topic %s in subscribe callback", topic);
@@ -264,7 +264,7 @@ int px4muorb_topic_advertised(const char *topic_name)
uORBCommunicator::IChannelRxHandler *rxHandler = channel->GetRxHandler();
if (rxHandler) {
return rxHandler->process_remote_topic(topic_name, true);
return rxHandler->process_remote_topic(topic_name);
} else {
PX4_ERR("Null rx handler in %s", __FUNCTION__);
@@ -295,7 +295,7 @@ int px4muorb_add_subscriber(const char *topic_name)
if (rxHandler) {
channel->AddRemoteSubscriber(topic_name);
// Pick a high message rate of 1000 Hz
return rxHandler->process_add_subscription(topic_name, 1000);
return rxHandler->process_add_subscription(topic_name);
} else {
PX4_ERR("Null rx handler in %s", __FUNCTION__);