From 32fb0e5b1949ef115e92de9457cb4e83854e51f2 Mon Sep 17 00:00:00 2001 From: Romain Forlot Date: Thu, 8 Jun 2017 15:25:27 +0200 Subject: Migration to AFB Binding V2 No more binder interface needed to use logging macros and others stuff like make_event or any other calls Change-Id: Iaee60697373bc8a0e67518e924b36b5389533e68 Signed-off-by: Romain Forlot --- CAN-binder/low-can-binding/utils/socketcan-raw.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'CAN-binder/low-can-binding/utils/socketcan-raw.cpp') diff --git a/CAN-binder/low-can-binding/utils/socketcan-raw.cpp b/CAN-binder/low-can-binding/utils/socketcan-raw.cpp index a35a99d..31965c3 100644 --- a/CAN-binder/low-can-binding/utils/socketcan-raw.cpp +++ b/CAN-binder/low-can-binding/utils/socketcan-raw.cpp @@ -42,10 +42,10 @@ namespace utils // Attempts to open a socket to CAN bus ::strcpy(ifr.ifr_name, device_name.c_str()); - DEBUG(binder_interface, "%s: ifr_name is : %s", __FUNCTION__, ifr.ifr_name); + DEBUG("ifr_name is : %s", ifr.ifr_name); if(::ioctl(socket_, SIOCGIFINDEX, &ifr) < 0) { - ERROR(binder_interface, "%s: ioctl failed. Error was : %s", __FUNCTION__, strerror(errno)); + ERROR("ioctl failed. Error was : %s", strerror(errno)); close(); } else @@ -55,7 +55,7 @@ namespace utils if(bind((struct sockaddr *)&tx_address_, sizeof(tx_address_)) < 0) { - ERROR(binder_interface, "%s: Bind failed. %s", __FUNCTION__, strerror(errno)); + ERROR("Bind failed. %s", strerror(errno)); close(); } } @@ -74,8 +74,8 @@ namespace utils ifr.ifr_ifindex = addr.can_ifindex; ioctl(s.socket(), SIOCGIFNAME, &ifr); - DEBUG(binder_interface, "Data available: %i bytes read", (int)nbytes); - DEBUG(binder_interface, "read: Found on bus %s:\n id: %X, length: %X, data %02X%02X%02X%02X%02X%02X%02X%02X", ifr.ifr_name, frame.can_id, frame.len, + DEBUG("Data available: %i bytes read", (int)nbytes); + DEBUG("read: Found on bus %s:\n id: %X, length: %X, data %02X%02X%02X%02X%02X%02X%02X%02X", ifr.ifr_name, frame.can_id, frame.len, frame.data[0], frame.data[1], frame.data[2], frame.data[3], frame.data[4], frame.data[5], frame.data[6], frame.data[7]); struct timeval tv; -- cgit 1.2.3-korg