From 20cbe35dc3282b8e27278e3bd54d415cc8147d3c Mon Sep 17 00:00:00 2001 From: Andre Hartmann Date: Sat, 17 Mar 2018 21:06:20 +0100 Subject: VectorCAN: Fix receiving frames with multiple open channels As reason for the fix, see section "3.4.1 XLevent" in the Vector documentation XL_Driver_Library_Manual_EN.pdf, which states: "portHandle: Internal use only". This portHandle seems to be always zero and therefore channels greater then zero could not receive frames. Tested with Vectors simulated channels by sending frames to one channel which in turn were received by both channels. The sending channel had the local echo flag set, the other one not. [ChangeLog][QCanBus][VectorCAN] Fixed a receive problem in the VectorCAN plugin. When multiple channels were open, only the first one could receive frames. Task-number: QTBUG-67030 Change-Id: Ib76a04bc06e7b810d1c1cb092b79c4bc1aacf23a Reviewed-by: Denis Shienkov Reviewed-by: Mihai Baneu Reviewed-by: Alex Blasche --- src/plugins/canbus/vectorcan/vectorcanbackend.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/plugins/canbus') diff --git a/src/plugins/canbus/vectorcan/vectorcanbackend.cpp b/src/plugins/canbus/vectorcan/vectorcanbackend.cpp index dc28d7c..9026888 100644 --- a/src/plugins/canbus/vectorcan/vectorcanbackend.cpp +++ b/src/plugins/canbus/vectorcan/vectorcanbackend.cpp @@ -355,7 +355,7 @@ void VectorCanBackendPrivate::startRead() break; } - if (event.tag != XL_RECEIVE_MSG || event.portHandle != portHandle) + if (event.tag != XL_RECEIVE_MSG) continue; const s_xl_can_msg &msg = event.tagData.msg; -- cgit v1.2.3