09.05.2014 Views

LAC-1 single axis controller manual

LAC-1 single axis controller manual

LAC-1 single axis controller manual

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

SMAC<br />

<strong>LAC</strong>-1 Technical Reference Manual<br />

4.4 Register Commands<br />

The <strong>LAC</strong>-1 uses part of its nonvolatile RAM (NVRAM) to create a 512 by 32 bit general<br />

purpose register space with Register "0" being referred to as the Accumulator.<br />

The registers have many uses including storing data and parameters, performing<br />

mathematical operations and controlling command execution. The registers can be manipulated<br />

by several commands and can also be used to replace the argument in most commands. For<br />

example, if register "6" contains the value "-12000" and the following command is used...<br />

MA@6,GO<br />

it would use the contents of register "6" as the argument thus giving the same result as if the<br />

following command was issued...<br />

MA-12000<br />

Note that the use of the "@" character is what caused the command to assume a register<br />

argument (or indirect argument) instead of a direct argument. If the value following the "@" is not<br />

in the range of the 512 registers (0 to 511), an error will be reported. If the value contained by the<br />

register of the indirect argument is out of range, an error will also be reported.<br />

As stated earlier, because the registers are within the NVRAM, they are non-volatile and can<br />

be used as such. For example, if a register is incremented once every user program cycle, it can be<br />

used as an ongoing cycle counter for maintenance purposes, production accounting and etc.<br />

4.4.1 Internal Variables<br />

In certain applications, the user may find it necessary to use data pertinent to the internal<br />

operation of the <strong>LAC</strong>-1. This may be accomplished via the use of the Read Byte (RB), the Read<br />

Word (RW) and the Read Long (RL) commands which copy the <strong>LAC</strong>-1's internal RAM memory to<br />

the accumulator and the Write Byte (WB), the Write Word (WW) and the Write Long (WL) commands<br />

which copy the accumulator to the <strong>LAC</strong>-1's internal RAM memory. The listings below tell the<br />

location of and describe the internal variables that may be of use to the user.<br />

WARNING:<br />

Randomly modifying these variables or other internal RAM not listed will most<br />

likely affect the operation of the <strong>LAC</strong>-1 resulting in unpredictable behavior or<br />

possible damage.<br />

41

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!