|
yarp-devices
|
Directories | |
| motor | |
| sensor | |
Files | |
| BusLoadMonitor.hpp | |
| CanBusBroker.hpp | |
| CanBusBroker_ParamsParser.h | |
| CanRxTxThreads.hpp | |
| LogComponent.hpp | |
| SdoReplier.hpp | |
| SingleBusBroker.hpp | |
| SyncPeriodicThread.hpp | |
| YarpCanSenderDelegate.hpp | |
This device offers a custom way of interfacing with wrapped raw subdevices through yarp::dev::IRemoteVariables. Available variables depend on the implementation of the subdevice; e.g. enableIp, ipMode, ipPeriodMs and enableCsv presented in the below examples are provided by the TechnosoftIpos device and parsed in the corresponding implementation of the yarp::dev::IRemoteVariablesRaw interface.
getRemoteVariablesList
Lists all CAN node IDs prepended with "ID", e.g. (ID15 ID16 ...).
getRemoteVariable
Retrieves all available key-value pairs for the selected node. Calls getRemoteVariablesListRaw to get raw keys and then iterates on getRemoteVariableRaw. The presence of additional surrounding parentheses is due to how the mapper device works and to keep being compatible with yarpmotorgui.
If key equals all, it returns remote vars for all available CAN nodes.
setRemoteVariable
Requires a key-value two-element bottle, value is a nested list.
Multiple keys can be bound per call, just nest them within an additional layer of bottles.
Same strategy works if you want to set the exact same remote variable (or variables) for all available nodes, just use all as key.
It is also possible to target multiple nodes in a single call, and set one or more remote variables at once. Use multi as key.