How to generate PREADY signal from slave in APB protocol?

1.1k Views Asked by At

I am designing AMBA APB slave. All signals for AMBA APB in my design are being generated properly from master side but in what case my slave should generate PREADY signal? PENABLE, PSEL, PADDR and PDATA are avalible from master. When should my slave generate PREADY signal? Are there any specific cases I should consider while designing slave to make PREADY high? Should my data get transferred only when PREADY is high?

2

There are 2 best solutions below

0
On

PREADY should be high when you wish to read or write from the device. In the case that your device has no wait states, you will generally always want your PREADY signal to be high because your device is 'always' 'ready' to transmit data.

If your device does have wait states, then you will want to pull PREADY low to 'wait' for your device to come out of its wait states. When your device is ready to transmit data, it can then set PREADY to high until it re-enters a wait state.

The device controls the PREADY signal. Therefore, regardless of what the bus is doing, the device can control when it reads or writes data with the PREADY signal.

0
On

Please refer to official AMBA APB spec from ARM, see link below: AMBA APB spec

Functionality behind PREADY is well defined there, if it is industry standard then You should always follow requirements defined in the standard specification.