SPRUIX1B October 2022 – April 2024 TMS320F2800132 , TMS320F2800133 , TMS320F2800135 , TMS320F2800137
The parallel general-purpose I/O (GPIO) boot mode asynchronously transfers code from host to C28x internal memory. Each value is 8-bits long and follows the same data flow as outlined in Figure 4-12.
The control subsystem communicates with the external host device by polling/driving the Host Control and 28x control lines. The handshake protocol shown in Figure 4-13 must be used to successfully transfer each word using GPIO [D0:D7]. This protocol is very robust and allows for a slower or faster host to communicate with the master subsystem.
Two consecutive 8-bit words are read to form a single 16-bit word. The least-significant byte (LSB) is read first followed by the most-significant byte (MSB). In this case, data is read from GPIO[D0:D7].
The 8-bit data stream is shown in Table 4-31.
Bytes | GPIO[D0:D7] (Byte 1 of 2) |
GPIO[D0:D7] (Byte 2 of 2) |
Description | |
---|---|---|---|---|
1 | 2 | AA | 08 | 0x08AA (KeyValue for memory width = 16 bits) |
3 | 4 | 00 | 00 | 8 reserved words (words 2 - 9) |
... | ... | ... | ... | ... |
17 | 18 | 00 | 00 | Last reserved word |
19 | 20 | BB | 00 | Entry point PC[22:16] |
21 | 22 | DD | CC | Entry point PC[15:0] (PC = 0x00BBCCDD) |
23 | 24 | NN | MM | Block size of the first block of data to load = 0xMMNN words |
25 | 26 | BB | AA | Destination address of first block Addr[31:16] |
27 | 28 | DD | CC | Destination address of first block Addr[15:0] (Addr = 0xAABBCCDD) |
29 | 30 | BB | AA | First word of the first block in the source being loaded = 0xAABB |
... ... ... |
... Data for this section. ... |
|||
. | BB | AA | Last word of the first block of the source being loaded = 0xAABB | |
. | NN | MM | Block size of the 2nd block to load = 0xMMNN words | |
. | BB | AA | Destination address of second block Addr[31:16] | |
. | DD | CC | Destination address of second block Addr[15:0] | |
. | BB | AA | First word of the second block in the source being loaded | |
. | … | |||
n | n+1 | BB | AA | Last
word of the last block of the source being loaded (More sections if required) |
n+2 | n+3 | 00 | 00 | Block size of 0000h - indicates end of the source program |
The device first signals the host that the device is ready to begin data transfer by pulling the 28x control pin low. The host load then initiates the data transfer by pulling the DSP control pin low. The complete protocol is shown in Figure 4-13.
This process is repeated for each data value to be sent.
Figure 4-14 shows an overview of the Parallel GPIO bootloader flow.
Figure 4-15 shows the transfer flow from the host side. The operating speed of the CPU and host are not critical in this mode as the host waits for the device and the device in turn waits for the host. In this manner, the protocol works with both a host running faster and a host running slower than the device.
Figure 4-16 shows the flow used to read a single word of data from the parallel port.
The 8-bit routine, shown in Figure 4-16, discards the upper 8 bits of the first read from the port and treats the lower 8 bits masked with D7 in bit position 7 and D6 in bit position 6 as the least-significant byte (LSB) of the word to be fetched. The routine then performs a second read to fetch the most-significant byte (MSB). The routine then performs a second read to fetch the most-significant byte (MSB). The routine then combines the MSB and LSB into a single 16-bit value to be passed back to the calling routine.