Fix: decoded name will be prefixed as at subscription.
authorRomain Forlot <romain.forlot@iot.bzh>
Thu, 16 Mar 2017 18:10:38 +0000 (19:10 +0100)
committerRomain Forlot <romain.forlot@iot.bzh>
Thu, 16 Mar 2017 18:10:38 +0000 (19:10 +0100)
Reason is that the simple message is used to match a subscribed signals
in the map. So it has to be the same that at the subscription.

Change-Id: Ie9504583948027523a7288b5e4a20707c49b6d59
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
src/can/can-bus.cpp

index 29e63b7..0c2337c 100644 (file)
@@ -91,7 +91,7 @@ int can_bus_t::process_can_signals(can_message_t& can_message)
                {
                        decoded_message = decoder_t::translateSignal(*sig, can_message, configuration_t::instance().get_can_signals());
 
-                       openxc_SimpleMessage s_message = build_SimpleMessage(sig->get_generic_name(), decoded_message);
+                       openxc_SimpleMessage s_message = build_SimpleMessage(sig->get_name(), decoded_message);
                        vehicle_message = build_VehicleMessage(s_message);
 
                        std::lock_guard<std::mutex> decoded_can_message_lock(decoded_can_message_mutex_);