MIP_SDK
latest-2-g34f3e39
MicroStrain Communications Library for embedded systems
|
Namespaces | |
utils | |
Typedefs | |
using | DescriptorSetSpan = microstrain::Span< DescriptorSetInfo const *const > |
template<class T > | |
using | Span = microstrain::Span< T > |
Enumerations | |
enum | Type { Type::NONE = 0, Type::CHAR, Type::BOOL, Type::U8, Type::S8, Type::U16, Type::S16, Type::U32, Type::S32, Type::U64, Type::S64, Type::FLOAT, Type::DOUBLE, Type::ENUM, Type::BITS, Type::STRUCT, Type::UNION } |
Functions | |
const DescriptorSetInfo * | findDescriptorSet (const DescriptorSetSpan &descriptorSets, uint8_t descriptor) |
Searches for a descriptor set in a list of descriptor sets. More... | |
const FieldInfo * | findField (const DescriptorSetSpan &descriptorSets, mip::CompositeDescriptor descriptor) |
Searches for field metadata info by descriptor ID. More... | |
const FieldInfo * | findField (const DescriptorSetInfo &ds_info, uint8_t field_desc, bool check_shared_data) |
Searches for field metadata info by descriptor ID. More... | |
void * | accessFunctionSelector (void *p) |
template<size_t I, class FieldType > | |
auto & | get (typename EnableForFieldTypes< FieldType >::type &field) |
Gets a reference to parameter 'I' in the struct for the given field. More... | |
using mip::metadata::DescriptorSetSpan = typedef microstrain::Span<DescriptorSetInfo const* const> |
using mip::metadata::Span = typedef microstrain::Span<T> |
|
strong |
|
inline |
const DescriptorSetInfo * mip::metadata::findDescriptorSet | ( | const DescriptorSetSpan & | descriptorSets, |
uint8_t | descriptor | ||
) |
Searches for a descriptor set in a list of descriptor sets.
descriptorSets | List of descriptor sets to search. |
descriptor | Descriptor set ID number. |
const FieldInfo * mip::metadata::findField | ( | const DescriptorSetInfo & | ds_info, |
uint8_t | field_desc, | ||
bool | check_shared_data | ||
) |
Searches for field metadata info by descriptor ID.
You can use this function with a specific descriptor set constant, or after searching for one with findDescriptorSet.
descriptorSets | Specific descriptor set to search. |
descriptor | Field descriptor to search for. |
check_shared_data | If true and the descriptor is a shared data field, searches the shared data set instead. |
const FieldInfo * mip::metadata::findField | ( | const DescriptorSetSpan & | descriptorSets, |
mip::CompositeDescriptor | descriptor | ||
) |
Searches for field metadata info by descriptor ID.
descriptorSets | List of descriptor sets to search. |
descriptor | Descriptor set and field descriptor to search for. |
auto& mip::metadata::get | ( | typename EnableForFieldTypes< FieldType >::type & | field | ) |
Gets a reference to parameter 'I' in the struct for the given field.
I | Index indicating which parameter to access. 0-based. |
FieldType | Type of the MIP field struct. |
field | An instance of the field struct whose member variable will be accessed. |