Manager for Bus Configuration.
More...
#include <configuration_manager.hpp>
|
| ConfigurationManager (std::string &file) |
|
template<typename T > |
std::optional< T > | get_entry (std::string device_name, std::string entry_name) |
| Gets a configuration entry for a specific device.
|
|
std::string | dump_device (std::string device_name) |
| Dump device string.
|
|
void | init_config () |
| Initialises the configuration.
|
|
uint32_t | get_all_devices (std::vector< std::string > &devices) |
| Returns all device names.
|
|
Manager for Bus Configuration.
The Bus configuration Manager stores the YAML bus configuration and enables reading configuration entries. The configuration manager is passed to all ros2_canopen master and slave drivers to enable reading driver specific configuration parameters from the YAML configuration file.
◆ ConfigurationManager()
ros2_canopen::ConfigurationManager::ConfigurationManager |
( |
std::string & |
file | ) |
|
|
inline |
◆ get_entry()
template<typename T >
std::optional< T > ros2_canopen::ConfigurationManager::get_entry |
( |
std::string |
device_name, |
|
|
std::string |
entry_name |
|
) |
| |
|
inline |
Gets a configuration entry for a specific device.
- Template Parameters
-
T | Datatype of the retrieved object |
- Parameters
-
device_name | Device name |
entry_name | Entry name |
- Returns
- std::optional<T> Return value, can be empty.
◆ dump_device()
std::string ros2_canopen::ConfigurationManager::dump_device |
( |
std::string |
device_name | ) |
|
|
inline |
Dump device string.
- Parameters
-
- Returns
- std::string
◆ init_config()
void ros2_canopen::ConfigurationManager::init_config |
( |
| ) |
|
Initialises the configuration.
◆ get_all_devices()
uint32_t ros2_canopen::ConfigurationManager::get_all_devices |
( |
std::vector< std::string > & |
devices | ) |
|
Returns all device names.
- Parameters
-
devices | List with names of all devices |
- Returns
- uint32_t Number of devices discovered
The documentation for this class was generated from the following file: