summaryrefslogtreecommitdiffstats
path: root/low-can-binding/can/can-bus.cpp
diff options
context:
space:
mode:
authorRomain Forlot <romain.forlot@iot.bzh>2017-09-28 11:09:59 +0200
committerRomain Forlot <romain.forlot@iot.bzh>2017-09-28 11:12:40 +0200
commit4af423a2a09683acf0a9ad1e0a77bc45c2c843d9 (patch)
tree0c27bb742e8bfd9436098bb7ad8e6331dccb9be6 /low-can-binding/can/can-bus.cpp
parent91a8304cf1c9d7139840f95c1ad971c9603ed5bf (diff)
Add timestamp to diagnostic message event too
Change-Id: Id01a15efe1b6aa063ac9bb2d3989ff195035eeb0 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'low-can-binding/can/can-bus.cpp')
-rw-r--r--low-can-binding/can/can-bus.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/low-can-binding/can/can-bus.cpp b/low-can-binding/can/can-bus.cpp
index be40aab5..d5ad485f 100644
--- a/low-can-binding/can/can-bus.cpp
+++ b/low-can-binding/can/can-bus.cpp
@@ -109,6 +109,8 @@ void can_bus_t::process_diagnostic_signals(diagnostic_manager_t& manager, const
int subscription_id = can_message.get_sub_id();
openxc_VehicleMessage vehicle_message = manager.find_and_decode_adr(can_message);
+ if (can_message.get_timestamp())
+ {vehicle_message.timestamp = can_message.get_timestamp();}
if( (vehicle_message.has_simple_message && vehicle_message.simple_message.has_name) &&
s.find(subscription_id) != s.end() && afb_event_is_valid(s[subscription_id]->get_event()))
{