Welcome Guest,Register Now
Log In

ANT Forum

Welcome guest, please Login or Register


Field definition - other arrays?


Total Posts: 9

Joined 2008-10-25


Having just prototyped two messages, one with 24 and the other 60 signed int fields, it seems that having additional array types (other than byte base type 13) would be beneficial. Since the base type denotes size anyway, couldn't the size byte be used to indicate the number of elements? So in my case, one message would have a field definition of 0x07 0x18 0x83 (there are 6 other fields) and the other 0x05 0x3C 0x83      

Total Posts: 116

Joined 2008-11-21


it is possible to define a field as an array of any defined basetype... However it would need to be defined that way in the profile. For example, there are FIT fields defined as arrays of type "string" or "Byte" within the scope of the current SDK... but there could easily be an array of "date_times" or any other basetype.

THe "size" field in a field definition is not referring to the size of the bastype per se... it actually refers to the size of the resultant field - i.e. the size of the basetype times the number of elements.