Forum Discussion
Altera_Forum
Honored Contributor
14 years agoIs your pio returning the next value on each read request?
Are you decoding the address lines properly? Although you are using IORD_16DIRECT() the bus cycle requested by the nios cpu will be a 32bit one (with all byte enables asserted). Since your slave is 16bit it will see 2 read cycles, one for address 0 and one for address 2 (not sure what the address line is called by then! - might be A0 relative to your slave). In practise it is best to use 32bit slaves and set the high bits to zero on reads.