Copyright © Romilly Bowden 2000, 2001.
There has been some confusion about the length of the HART data field. An old version of the Data Link specification gave a 25-byte limit, but that document was withdrawn, and the current specifications apparently do not specify a maximum length.
The first and second editions of my "Technical Overview" booklet mention a 25-byte limit in several places, but this is wrong. As it says in the Preface, you should never regard the booklet as definitive!
Up until HART Revision 5, the Universal and Common-Practice commands have conformed to this limit, and most device designers have restricted themselves to 25 bytes or less for their Device-Specific commands. However, there do exist devices with Device-Specific commands using much longer messages for special purposes. The design of a general-purpose host may need to take account of this possibility.
HART Revision 6 includes new Universal Commands 20, 21 and 22 (using the new 32-character Long Tag) with data fields of 32 bytes (plus the two status bytes in a response). Also, remember that it is quite legal for the data field of any command to be extended in future revisions. Although slave devices are not required to understand any additional data bytes, they should either allow spare message buffer space, or use the byte count to track incoming data bytes, up to the check byte, so as to accept and check a message with an extended data field properly.
The protocol itself is unable to support more than 255 bytes in the data field, since the byte count has to be stated as a one-byte number (and this includes the two status bytes in a "response" message).