How to use the choochoo.fit.profile.fields.TypedField function in choochoo

To help you get started, we’ve selected a few choochoo examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github andrewcooke / choochoo / choochoo / fit / decode.py View on Github external
def __field_description(self, defn, record):
        developer_index = record.attr.developer_data_index[0][0]
        number = record.attr.field_definition_number[0][0]
        base_type = self.__types.base_types[
            self.__types.profile_to_type('fit_base_type').profile_to_internal(
                record.attr.fit_base_type_id[0][0])]
        name = record.attr.field_name[0][0]
        units = record.attr.units[0][0]
        self.__dev_fields[developer_index][number] = \
            TypedField(self.__log, name, number, units, None, None, None, base_type, self.__types)