diff options
-rw-r--r-- | src/can/can-bus-dev.cpp | 5 | ||||
-rw-r--r-- | src/can/can-bus-dev.hpp | 2 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/can/can-bus-dev.cpp b/src/can/can-bus-dev.cpp index 3f3dc1c..32a8906 100644 --- a/src/can/can-bus-dev.cpp +++ b/src/can/can-bus-dev.cpp @@ -38,6 +38,11 @@ can_bus_dev_t::can_bus_dev_t(const std::string& dev_name) { } +std::string can_bus_dev_t::get_device_name() const +{ + return device_name_; +} + /// @brief Open the can socket and returning it /// @return -1 if something wrong. int can_bus_dev_t::open() diff --git a/src/can/can-bus-dev.hpp b/src/can/can-bus-dev.hpp index 3a1f537..5907c58 100644 --- a/src/can/can-bus-dev.hpp +++ b/src/can/can-bus-dev.hpp @@ -48,6 +48,8 @@ private: public: can_bus_dev_t(const std::string& dev_name); + std::string get_device_name() const; + int open(); int close(); |