aboutsummaryrefslogtreecommitdiffstats
path: root/can-utils.h
diff options
context:
space:
mode:
authorRomain Forlot <romain.forlot@iot.bzh>2017-02-09 18:05:48 +0000
committerRomain Forlot <romain.forlot@iot.bzh>2017-02-09 18:05:48 +0000
commit8669985f9ab8821053bdaeadc08250c8c1e71d29 (patch)
tree044015d6c8908702bbf4c256a5fb5c3cd47f8165 /can-utils.h
parentf12c0a6976b72f2a660735703176e495b16f6ae3 (diff)
Re-implementation in C++ and separate threads to
read, decode and pushing on the event loop. Old code has been moved into obsolete directory. Change-Id: Ia389ab84a1dc566c48e0269f2466843de0e51158 Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'can-utils.h')
-rw-r--r--can-utils.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/can-utils.h b/can-utils.h
index 55408cb4..0a4fa246 100644
--- a/can-utils.h
+++ b/can-utils.h
@@ -96,9 +96,15 @@ class CanBus {
bool is_fdmode_on;
struct sockaddr_can txAddress;
+ std::thread th_reading;
+ std::thread th_decoding;
+ std::thread th_pushing;
+
public:
int open();
int close();
+
+ void start_threads();
};
/* Public: The ID format for a CAN message.