pub fn file_id_message() -> MessageInfo {
    let mut fields = HashMap::new();
    let field = FieldInfo {
        name: "type",
        field_type: FieldDataType::File,
        def_number: 0,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(0, field);
    let field = FieldInfo {
        name: "manufacturer",
        field_type: FieldDataType::Manufacturer,
        def_number: 1,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(1, field);
    let mut subfields = Vec::new();
    let sub_fld = FieldInfo {
        name: "favero_product",
        field_type: FieldDataType::FaveroProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::FaveroElectronics.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::Garmin.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::Dynastream.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::DynastreamOem.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::Tacx.as_i64(), sub_fld));
    let field = FieldInfo {
        name: "product",
        field_type: FieldDataType::UInt16,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: subfields,
        components: Vec::new(),
    };
    fields.insert(2, field);
    let field = FieldInfo {
        name: "serial_number",
        field_type: FieldDataType::UInt32z,
        def_number: 3,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(3, field);
    // Only set for files that are can be created/erased.
    let field = FieldInfo {
        name: "time_created",
        field_type: FieldDataType::DateTime,
        def_number: 4,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(4, field);
    // Only set for files that are not created/erased.
    let field = FieldInfo {
        name: "number",
        field_type: FieldDataType::UInt16,
        def_number: 5,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(5, field);
    // Optional free form string to indicate the devices name or model
    let field = FieldInfo {
        name: "product_name",
        field_type: FieldDataType::String,
        def_number: 8,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(8, field);
    MessageInfo {
        name: "file_id",
        global_message_number: MesgNum::FileId,
        fields,
    }
}
/// Must be first message in file.
Must be first message in file.
Must be first message in file .
pub fn file_id_message() -> MessageInfo {
    let mut fields = HashMap::new();
    let field = FieldInfo {
        name: "type",
        field_type: FieldDataType::File,
        def_number: 0,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(0, field);
    let field = FieldInfo {
        name: "manufacturer",
        field_type: FieldDataType::Manufacturer,
        def_number: 1,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(1, field);
    let mut subfields = Vec::new();
    let sub_fld = FieldInfo {
        name: "favero_product",
        field_type: FieldDataType::FaveroProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::FaveroElectronics.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::Garmin.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::Dynastream.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::DynastreamOem.as_i64(), sub_fld));
    let sub_fld = FieldInfo {
        name: "garmin_product",
        field_type: FieldDataType::GarminProduct,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    subfields.push((1, Manufacturer::Tacx.as_i64(), sub_fld));
    let field = FieldInfo {
        name: "product",
        field_type: FieldDataType::UInt16,
        def_number: 2,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: subfields,
        components: Vec::new(),
    };
    fields.insert(2, field);
    let field = FieldInfo {
        name: "serial_number",
        field_type: FieldDataType::UInt32z,
        def_number: 3,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(3, field);
    // Only set for files that are can be created/erased.
    let field = FieldInfo {
        name: "time_created",
        field_type: FieldDataType::DateTime,
        def_number: 4,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(4, field);
    // Only set for files that are not created/erased.
    let field = FieldInfo {
        name: "number",
        field_type: FieldDataType::UInt16,
        def_number: 5,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(5, field);
    // Optional free form string to indicate the devices name or model
    let field = FieldInfo {
        name: "product_name",
        field_type: FieldDataType::String,
        def_number: 8,
        scale: 1.000000,
        offset: 0.000000,
        units: "",
        accumulate: false,
        subfields: Vec::new(),
        components: Vec::new(),
    };
    fields.insert(8, field);
    MessageInfo {
        name: "file_id",
        global_message_number: MesgNum::FileId,
        fields,
    }
}
pub fn file_id_message ( ) -> MessageInfo { let mut fields = HashMap :: new ( ) ; let field = FieldInfo { name : " " , field_type : FieldDataType :: File , def_number : 0 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; fields . insert ( 0 , field ) ; let field = FieldInfo { name : " " , field_type : FieldDataType :: Manufacturer , def_number : 1 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; fields . insert ( 1 , field ) ; let mut subfields = Vec :: new ( ) ; let sub_fld = FieldInfo { name : " " , field_type : FieldDataType :: FaveroProduct , def_number : 2 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; subfields . push ( ( 1 , Manufacturer :: FaveroElectronics . as_i64 ( ) , sub_fld ) ) ; let sub_fld = FieldInfo { name : " " , field_type : FieldDataType :: GarminProduct , def_number : 2 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; subfields . push ( ( 1 , Manufacturer :: Garmin . as_i64 ( ) , sub_fld ) ) ; let sub_fld = FieldInfo { name : " " , field_type : FieldDataType :: GarminProduct , def_number : 2 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; subfields . push ( ( 1 , Manufacturer :: Dynastream . as_i64 ( ) , sub_fld ) ) ; let sub_fld = FieldInfo { name : " " , field_type : FieldDataType :: GarminProduct , def_number : 2 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; subfields . push ( ( 1 , Manufacturer :: DynastreamOem . as_i64 ( ) , sub_fld ) ) ; let sub_fld = FieldInfo { name : " " , field_type : FieldDataType :: GarminProduct , def_number : 2 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; subfields . push ( ( 1 , Manufacturer :: Tacx . as_i64 ( ) , sub_fld ) ) ; let field = FieldInfo { name : " " , field_type : FieldDataType :: UInt16 , def_number : 2 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : subfields , components : Vec :: new ( ) , } ; fields . insert ( 2 , field ) ; let field = FieldInfo { name : " " , field_type : FieldDataType :: UInt32z , def_number : 3 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; fields . insert ( 3 , field ) ; // Only set for files that are can be created/erased. let field = FieldInfo { name : " " , field_type : FieldDataType :: DateTime , def_number : 4 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; fields . insert ( 4 , field ) ; // Only set for files that are not created/erased. let field = FieldInfo { name : " " , field_type : FieldDataType :: UInt16 , def_number : 5 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; fields . insert ( 5 , field ) ; // Optional free form string to indicate the devices name or model let field = FieldInfo { name : " " , field_type : FieldDataType :: String , def_number : 8 , scale : 1.000000 , offset : 0.000000 , units : " " , accumulate : false , subfields : Vec :: new ( ) , components : Vec :: new ( ) , } ; fields . insert ( 8 , field ) ; MessageInfo { name : " " , global_message_number : MesgNum :: FileId , fields , } }
Must be first message in file.
Must be first message in file .