diff options
author | Romain Forlot <romain.forlot@iot.bzh> | 2017-05-16 15:12:45 +0200 |
---|---|---|
committer | Romain Forlot <romain.forlot@iot.bzh> | 2017-05-19 11:36:43 +0200 |
commit | c4f11994a1540576563819508d4148a0500db4b9 (patch) | |
tree | 868ffaecebd397fea46ef2ce9b8ebf2852fa8cd3 /CAN-binder/low-can-binding/binding | |
parent | d92a551c98751ef832453ab3b5286634a5278a33 (diff) |
Remove can-bus-dev following RAW->BCM sockets migration
No needs to get RAW socket for now, so can_bus_dev_t class is useless and
now removed from project.
Change-Id: I37b3e187ef28ba393beae7a99da4f422f74a298e
Signed-off-by: Romain Forlot <romain.forlot@iot.bzh>
Diffstat (limited to 'CAN-binder/low-can-binding/binding')
-rw-r--r-- | CAN-binder/low-can-binding/binding/configuration.cpp | 5 | ||||
-rw-r--r-- | CAN-binder/low-can-binding/binding/configuration.hpp | 2 | ||||
-rw-r--r-- | CAN-binder/low-can-binding/binding/low-can-hat.cpp | 18 |
3 files changed, 7 insertions, 18 deletions
diff --git a/CAN-binder/low-can-binding/binding/configuration.cpp b/CAN-binder/low-can-binding/binding/configuration.cpp index 005e662..6e2ccc4 100644 --- a/CAN-binder/low-can-binding/binding/configuration.cpp +++ b/CAN-binder/low-can-binding/binding/configuration.cpp @@ -32,11 +32,6 @@ can_bus_t& configuration_t::get_can_bus_manager() return can_bus_manager_; } -const std::map<std::string, std::shared_ptr<can_bus_dev_t>>& configuration_t::get_can_bus_devices() -{ - return can_bus_manager_.get_can_devices(); -} - diagnostic_manager_t& configuration_t::get_diagnostic_manager() { return diagnostic_manager_; diff --git a/CAN-binder/low-can-binding/binding/configuration.hpp b/CAN-binder/low-can-binding/binding/configuration.hpp index 2f1f4fc..ab6a793 100644 --- a/CAN-binder/low-can-binding/binding/configuration.hpp +++ b/CAN-binder/low-can-binding/binding/configuration.hpp @@ -59,8 +59,6 @@ class configuration_t can_bus_t& get_can_bus_manager(); - const std::map<std::string, std::shared_ptr<can_bus_dev_t>>& get_can_bus_devices(); - const std::string get_diagnostic_bus() const; diagnostic_manager_t& get_diagnostic_manager() ; diff --git a/CAN-binder/low-can-binding/binding/low-can-hat.cpp b/CAN-binder/low-can-binding/binding/low-can-hat.cpp index b115a96..747228e 100644 --- a/CAN-binder/low-can-binding/binding/low-can-hat.cpp +++ b/CAN-binder/low-can-binding/binding/low-can-hat.cpp @@ -68,19 +68,15 @@ extern "C" { can_bus_t& can_bus_manager = configuration_t::instance().get_can_bus_manager(); - /// Initialize CAN socket - if(can_bus_manager.init_can_dev() == 0) - { - can_bus_manager.start_threads(); + can_bus_manager.start_threads(); - /// Initialize Diagnostic manager that will handle obd2 requests. - /// We pass by default the first CAN bus device to its Initialization. - /// TODO: be able to choose the CAN bus device that will be use as Diagnostic bus. - if(configuration_t::instance().get_diagnostic_manager().initialize()) - return 0; - } + /// Initialize Diagnostic manager that will handle obd2 requests. + /// We pass by default the first CAN bus device to its Initialization. + /// TODO: be able to choose the CAN bus device that will be use as Diagnostic bus. + if(configuration_t::instance().get_diagnostic_manager().initialize()) + return 0; - ERROR(binder_interface, "%s: There was something wrong with CAN device Initialization. Check your config file maybe", __FUNCTION__); + ERROR(binder_interface, "%s: There was something wrong with CAN device Initialization.", __FUNCTION__); return 1; } }; |