In-System Debugging—IP2022 User’s Manual 332 www.ubicom.com Because the IP2022 has to send something back simultaneously
with receiving each command, it echoes the previous command
and sends it back with its MSB (bit 7 of the command byte) set to
signal   completion   of   the   previous   command.   The   very   first
command acknowledgement returns 0x800000 because there is
no previous command, i.e. the acknowledgment has the DONE bit
set and a return value that is all zero.
Commands that do not require any data to be returned generate
command   acknowledgements   with   zero   in   the   return   value.
However, most command acknowledgements have a return value
that   consists   of   the   STATUS   and   W   registers   concatenated
together, with the STATUS register occupying the high byte of the
return value and the W register occupying the low byte. Because
there   is   no   ISD/ISP   command   for   reading   the   IP2022   data
memory, data memory must be read using instructions executed
on the IP2022. By using CPU instructions to read data memory
into  the  W  register,  the  data  becomes  visible  on  the  ISD/ISP
interface in the command acknowledgement return value.
A    few    ISD/ISP    commands    are    acknowledged    with    the
ISP_STATUS  register  as  the  return  value.  The  format  of  this
register is shown in Section 5.2.1.