OpenCores
URL https://opencores.org/ocsvn/ssbcc/ssbcc/trunk

Subversion Repositories ssbcc

[/] [ssbcc/] [trunk/] [core/] [9x8/] [doc/] [opcodes.html] - Diff between revs 2 and 7

Show entire file | Details | Blame | View Log

Rev 2 Rev 7
Line 1... Line 1...
 
 
<!-- Copyright 2012, Sinclair R.F., Inc. -->
<!-- Copyright 2012-2014, Sinclair R.F., Inc. -->
<html>
<html>
<title>
<title>
Opcodes
Opcodes
</title>
</title>
<body>
<body>
<h1>Opcodes for the 9x8 micro controller</h1><br/>
<h1>Opcodes for the 9x8 micro controller</h1><br/>
Copyright 2012, Sinclair R.F., Inc.<br/><br/>
Copyright 2012, 2014, Sinclair R.F., Inc.<br/><br/>
This document describes the opcodes for the 9x8 micro controller.  The first
This document describes the opcodes for the 9x8 micro controller.  The first
  section lists the opcodes in alphabetic order, the second lists them by their
  section lists the opcodes in alphabetic order, the second lists them by their
  numerical value, and the final section describes each one in detail.<br/><br/>
  numerical value, and the final section describes each one in detail.<br/><br/>
Some of the opcodes are not directly accessible by the assembler and must be
Some of the opcodes are not directly accessible by the assembler and must be
  accessed through macros.  See <a href="macros.html">macros</a> for
  accessed through macros.  See <a href="macros.html">macros</a> for
Line 17... Line 17...
<h1>OPCODES</h1>
<h1>OPCODES</h1>
  This section documents the opcodes.<br/><br/>
  This section documents the opcodes.<br/><br/>
  Alphabetic listing:
  Alphabetic listing:
    <a href="#&">&amp;</a>,
    <a href="#&">&amp;</a>,
    <a href="#+">+</a>,
    <a href="#+">+</a>,
 
    <a href="#+c">+c</a>,
    <a href="#-">-</a>,
    <a href="#-">-</a>,
    <a href="#-1<>">-1&lt;&gt;</a>,
    <a href="#-1<>">-1&lt;&gt;</a>,
    <a href="#-1=">-1=</a>,
    <a href="#-1=">-1=</a>,
 
    <a href="#-c">-c</a>,
    <a href="#0<>">0&lt;&gt;</a>,
    <a href="#0<>">0&lt;&gt;</a>,
    <a href="#0=">0=</a>,
    <a href="#0=">0=</a>,
    <a href="#0>>">0&gt;&gt;</a>,
    <a href="#0>>">0&gt;&gt;</a>,
    <a href="#1+">1+&gt;</a>,
    <a href="#1+">1+&gt;</a>,
    <a href="#1-">1-&gt;</a>,
    <a href="#1-">1-&gt;</a>,
Line 108... Line 110...
      </tr>
      </tr>
    <th align="left"><a href="#over">over</a></th>
    <th align="left"><a href="#over">over</a></th>
      <td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>1</td><td>0</td><td>1</td><td>0</td>
      <td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>1</td><td>0</td><td>1</td><td>0</td>
      <td align="left">push a duplicate of the next-to-top of the data stack onto the data stack</td>
      <td align="left">push a duplicate of the next-to-top of the data stack onto the data stack</td>
      </tr>
      </tr>
 
    <th align="left"><a href="#+c">+c</a></th>
 
      <td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>1</td><td>0</td><td>1</td><td>1</td>
 
      <td align="left">push the carry bit from N+T onto the data stack</td>
 
      </tr>
 
    <th align="left"><a href="#-c">-c</a></th>
 
      <td>0</td><td>0</td><td>0</td><td>0</td><td>0</td><td>1</td><td>1</td><td>1</td><td>1</td>
 
      <td align="left">push the carry bit from N-T onto the data stack</td>
 
      </tr>
    <th align="left"><a href="#swap">swap</a></th>
    <th align="left"><a href="#swap">swap</a></th>
      <td>0</td><td>0</td><td>0</td><td>0</td><td>1</td><td>0</td><td>0</td><td>1</td><td>0</td>
      <td>0</td><td>0</td><td>0</td><td>0</td><td>1</td><td>0</td><td>0</td><td>1</td><td>0</td>
      <td align="left">swap the top and the next-to-top of the data stack</td>
      <td align="left">swap the top and the next-to-top of the data stack</td>
      </tr>
      </tr>
    <th align="left"><a href="#+">+</a></th>
    <th align="left"><a href="#+">+</a></th>
Line 248... Line 258...
      PC &leftarrow; PC+1<br/>
      PC &leftarrow; PC+1<br/>
      R and <tt>return</tt> unchanged<br/>
      R and <tt>return</tt> unchanged<br/>
      T &leftarrow; N + T<br/>
      T &leftarrow; N + T<br/>
      N &leftarrow; <tt>stack--</tt><br/>
      N &leftarrow; <tt>stack--</tt><br/>
      <br/>
      <br/>
 
  <h2><a name="+c">Instruction:  +c</a></h2>
 
    <b>Desription:</b>  Push the carry bit from N+T onto the data
 
      stack.<br/><br/>
 
    <b>Operation:</b><br/><br/>
 
      PC &leftarrow; PC+1<br/>
 
      R and <tt>return</tt> unchanged<br/>
 
      T &leftarrow; the msb of the 9-bit sum of N+T<br/>
 
      N &leftarrow; T<br/>
 
      ++stack &leftarrow; N<br/>
 
      <br/>
  <h2><a name="-">Instruction:  -</a></h2>
  <h2><a name="-">Instruction:  -</a></h2>
    <b>Desription:</b>  Pop the data stack and replace the top with the
    <b>Desription:</b>  Pop the data stack and replace the top with the
      8&nbsp;difference of the previous top and next-to-top.<br/><br/>
      8&nbsp;difference of the previous top and next-to-top.<br/><br/>
    <b>Operation:</b><br/><br/>
    <b>Operation:</b><br/><br/>
      PC &leftarrow; PC+1<br/>
      PC &leftarrow; PC+1<br/>
Line 275... Line 295...
      PC &leftarrow; PC+1<br/>
      PC &leftarrow; PC+1<br/>
      R and <tt>return</tt> unchanged<br/>
      R and <tt>return</tt> unchanged<br/>
      T &leftarrow; 0xFF if T=0xFF, 0x00 otherwise<br/>
      T &leftarrow; 0xFF if T=0xFF, 0x00 otherwise<br/>
      N and <tt>stack</tt> unchanged<br/>
      N and <tt>stack</tt> unchanged<br/>
      <br/>
      <br/>
 
  <h2><a name="-c">Instruction:  -c</a></h2>
 
    <b>Desription:</b>  Push the carry bit from N-T onto the data
 
      stack.<br/><br/>
 
    <b>Operation:</b><br/><br/>
 
      PC &leftarrow; PC+1<br/>
 
      R and <tt>return</tt> unchanged<br/>
 
      T &leftarrow; the msb of the 9-bit difference N-T<br/>
 
      N &leftarrow; T<br/>
 
      ++stack &leftarrow; N<br/>
 
      <br/>
  <h2><a name="0<>">Instruction:  0<></a></h2>
  <h2><a name="0<>">Instruction:  0<></a></h2>
    <b>Desription:</b>  Set the top of the stack to all ones if the previous
    <b>Desription:</b>  Set the top of the stack to all ones if the previous
      value was not all zeros, otherwise set it to all zeros.<br/><br/>
      value was not all zeros, otherwise set it to all zeros.<br/><br/>
    <b>Operation:</b><br/><br/>
    <b>Operation:</b><br/><br/>
      PC &leftarrow; PC+1<br/>
      PC &leftarrow; PC+1<br/>

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.