DS80C400 C Libraries: TBIN2 File Format
A TBIN2 file is made up of multiple TBIN2 records, terminated by the end-of-file. It is very
similar in structure to the TBIN file format, except that there is a 1-byte version number and
the CRC16 precedes the data. The TBIN2 file format is understood by the Netboot algorithm of the
DS80C400. Following is a high level description of a TBIN2 file...
[ TBIN2 Record ]
[ TBIN2 Record ]
[ ... ]
[ TBIN2 Record ]
[ end of file ]
Note that Netboot is primarily intended for manufacturing and development, and not for
deployed systems. Current DS80C400 parts require a deviation from the TBIN2 format
specification for files containing over 64KB of data. To correct for this problem,
use the following tools: FIXME-FIXME-FIXME-FIXME
A TBIN2 record has a 1 byte version number, 3 bytes of starting address, 2 bytes of (length-1),
2 bytes of CRC16, and [length] bytes of data. Therefore, a TBIN record can carry a maximum of
64Kbytes of data to load, plus its 8 bytes of overhead.
The version number refers to the version of the TBIN2 record formant, and should be 1.
[ VERSION ]
[ A_low ][ A_high ][ A_xhigh ]
[ L_low ][ L_high ]
[ CRC_low ][ CRC_high ]
[ D1 D2 D3 ... D(L+1) ]
For example...
- If a TBIN2 record is to be loaded at address 000000h,
| A_low | = | 00h |
| A_high | = | 00h |
| A_xhigh | = | 00h |
- If a TBIN2 record is to be loaded at address 010203h,
| A_low | = | 03h |
| A_high | = | 02h |
| A_xhigh | = | 01h |
- If a TBIN2 record contains 5 bytes of data to load,
- If a TBIN2 record contains 0508h bytes of data to load,
- If a TBIN2 record contains 65536 bytes of data to load,
- If a TBIN2 record contains a single byte to load,