/**
 * This interface is a PIC that offers internal access and other features to make it debuggable.
 * <BR>You can read the source of this interface <A HREF="./DebuggablePIC.java.html"> here</A>.
 */
public interface DebuggablePIC extends PIC {

	/**
	 * Executes one instruction.
	 */
	public void Trace();

	/**
	 * Returns the program counter.
	 */
	public int getPC();

	/**
	 * Sets the program counter.
	 */
	public void setPC(int n);

	/**
	 * Returns the W register.
	 */
	public int getW();

	/**
	 * Sets the W register.
	 */
	public void setW(int n);

	/**
	 * Returns the stack pointer.
	 */
	public int getSP();

	/**
	 * Sets the stack pointer.
	 */
	public void setSP(int n);

	/**
	 * Returns the Level element of the stack.
	 */
	public int getStack(int Level);

	/**
	 * Sets the Level element of the stack.
	 */
	public void setStack(int Level, int n);

	/**
	 * Returns the DebuggableFlash.
	 */
	public DebuggableFlash getFlashMemory();

	/**
	 * Returns the DebuggableFileRegisters.
	 */
	public DebuggableFileRegisters getFileRegisters();

	/**
	 * Returns the state of the PIC.
	 */
	public String[] getStateForDisplay();

	/**
	 * Returns the stack for display.
	 */
	public String[] getStackForDisplay();


	/**
	 * Returns the program loaded into the flash for display.
	 */
	public String[] getFlashForDisplay();

	/**
	 * Refreshes the flash program.
	 * @param n The address of the instruction to refresh.
	 * @return The refreshed instruction.
	 */
	public String getFlashRefresh(int n, String s);

	/**
	 * Returns the breakpoints for display.
	 */
	public String[] getBreakpointsForDisplay();

	/**
	 * Sets a breakpoint to address n.
	 */
	public void setBreakpoint(int n);

	/**
	 * Retunrs the address of the nth breakpoint.
	 */
	public int getBreakpoint(int n);

	/**
	 * Returns true if there already is a breakpoint at address n.
	 */
	public boolean isBreakpoint(int n);

	/**
	 * Removes the breakpoint at address n.
	 */
	public void removeBreakpoint(int n);
}