Altera_Forum
Honored Contributor
22 years agoDynamic Bus Sizing on Avalon Bus
Hi all,
To access a 8-Bit Port on a DSP (TMS320 / HPI8) I've implemented an 'Interface to User Logic' as Avalon memory slave. This module has 8-Data-Bits, 11 Addr-Bits, WRn, RDn, and CSn, all shared on Avalon except CSn. Because of its internal 16-Bit structure and 8-Bit interface a double access is necessary to read/write data via this interface while A[0] specifies upper or lower byte. So 'Dynamic Bus Sizing' should be the perfect solution. With a 16-bit-write to the port all seems to be ok: two WRn strobes with A0 changing from 0 to 1. But in a 16-Bit-read command four read cycles (RDn) are generated, reading a whole 32-Bit word on succeeding addresses. Disassembling the appropriate code shows 'ldhu r2,0(r2)' is used (once) in this context. Because the DSP-Interface has auto increment when reading its port, additional strobes increment internal address counter. My question is: How can I ensure that a 16-bit read on a 8-bit location produces only two read cycles on Avalon bus? Has anybody an answer? Mike ----------------------------------- Quartus: 4.1 Build 208 SP2 NIOS II SOPC Builder: 4.1 Build 208 Windows XP Pro