7 number_of_modules_(number_of_modules)
39 auto& info =
infos_[i].settings().actuator().springConstant();
40 res[i] = (info) ? info.get() : std::numeric_limits<float>::quiet_NaN();
54 auto& info =
infos_[i].settings().actuator().springConstant();
55 out[i] = (info) ? info.get() : std::numeric_limits<float>::quiet_NaN();
size_t size() const
Returns the number of module infos in this group info.
Info objects have various fields representing the module state; which fields are populated depends on...
void hebiGroupInfoRelease(HebiGroupInfoPtr info)
Frees resources created by the GroupInfo object.
HebiStatusCode hebiGroupInfoWriteGains(HebiGroupInfoPtr info, const char *file)
Export gains from a GroupInfo object into a file.
HebiGroupInfoPtr hebiGroupInfoCreate(size_t size)
Creates a GroupInfo for a group with the specified number of modules.
const Info & operator[](size_t index) const
Access the info for an individual module.
GroupInfo(size_t number_of_modules)
Create a group info with the specified number of modules.
bool writeGains(const std::string &file) const
Export the gains from this GroupInfo object into a file, creating it as necessary.
Eigen::VectorXd getSpringConstant() const
Convenience function for returning spring constant values.
~GroupInfo() noexcept
Destructor cleans up group info object as necessary.
std::vector< Info > infos_
HebiInfoPtr hebiGroupInfoGetModuleInfo(HebiGroupInfoPtr info, size_t module_index)
Get an individual info for a particular module at index module_index.
HebiGroupInfoPtr internal_
const size_t number_of_modules_