Instruction | Effect | |
---|---|---|
SET | b, a | sets b to a |
ADD | b, a | sets b to b+a, sets EX to 0x0001 if there's an overflow, 0x0 otherwise |
SUB | b, a | sets b to b-a, sets EX to 0xffff if there's an underflow, 0x0 otherwise |
MUL | b, a | sets b to b*a, sets EX to ((b*a)>>16)&0xffff (treats b, a as unsigned) |
MLI | b, a | like MUL, but treat b, a as signed |
DIV | b, a | sets b to b/a, sets EX to ((b<<16)/a)&0xffff. if a==0, sets b and EX to 0 instead. (treats b, a as unsigned) |
DVI | b, a | like DIV, but treat b, a as signed. Rounds towards 0 |
MOD | b, a | sets b to b%a. if a==0, sets b to 0 instead. |
MDI | b, a | like MOD, but treat b, a as signed. (MDI -7, 16 == -7) |
AND | b, a | sets b to b&a |
BOR | b, a | sets b to b|a |
XOR | b, a | sets b to b^a |
SHR | b, a | sets b to b>>>a, sets EX to ((b<<16)>>a)&0xffff (logical shift) |
ASR | b, a | sets b to b>>a, sets EX to ((b<<16)>>>a)&0xffff (arithmetic shift) (treats b as signed) |
SHL | b, a | sets b to b<<a, sets EX to ((b<<a)>>16)&0xffff |
IFB | b, a | performs next instruction only if (b&a)!=0 |
IFC | b, a | performs next instruction only if (b&a)==0 |
IFE | b, a | performs next instruction only if b==a |
IFN | b, a | performs next instruction only if b!=a |
IFG | b, a | performs next instruction only if b>a |
IFA | b, a | performs next instruction only if b>a (signed) |
IFL | b, a | performs next instruction only if b<a |
IFU | b, a | performs next instruction only if b<a (signed) |
ADX | b, a | sets b to b+a+EX, sets EX to 0x0001 if there is an over-flow, 0x0 otherwise |
SBX | b, a | sets b to b-a+EX, sets EX to 0xFFFF if there is an under-flow, 0x0 otherwise |
STI | b, a | sets b to a, then increases I and J by 1 |
STD | b, a | sets b to a, then decreases I and J by 1 |
JSR | a | pushes the address of the next instruction to the stack, then sets PC to a |
HCF | a | --- |
INT | a | triggers a software interrupt with message a |
IAS | a | sets IA to a |
IAG | a | sets a to IA |
RFI | a | disables interrupt queueing, pops A from the stack, then pops PC from the stack |
IAQ | a | if a is nonzero, interrupts will be added to the queue instead of triggered. if a is zero, interrupts will be triggered as normal again |
HWN | a | sets a to number of connected hardware devices |
HWQ | a | sets A, B, C, X, Y registers to information about hardware a A+(B<<16) is a 32 bit word identifying the hardware id C is the hardware version X+(Y<<16) is a 32 bit word identifying the manufacturer |
HWI | a | sends an interrupt to hardware a |
PC (Windows/Linux) | Mac | action |
---|---|---|
Ctrl-U | Ctrl-U | change to upper case |
Ctrl-Shift-U | Ctrl-Shift-U | change to lower case |
Ctrl-Alt-Down | Command-Option-Down | copy lines down |
Ctrl-Alt-Up | Command-Option-Up | copy lines up |
Ctrl-F | Command-F | find |
Ctrl-K | Command-G | find next |
Ctrl-Shift-K | Command-Shift-G | find previous |
Ctrl-End,Ctrl-Down | Command-End,Command-Down | go to end |
Ctrl-L | Command-L | go to line |
Alt-Right,End | Command-Right,End,Ctrl-E | go to line end |
Alt-Left,Home | Command-Left,Home,Ctrl-A | go to line start |
Ctrl-Home,Ctrl-Up | Command-Home,Command-Up | go to start |
Ctrl-Left | Option-Left | go to word left |
Ctrl-Right | Option-Right | go to word right |
Tab | Tab | indent |
Alt-Down | Option-Down | move lines down |
Alt-Up | Option-Up | move lines up |
Shift-Tab | Shift-Tab | outdent |
Insert | Insert | overwrite |
Ctrl-Shift-Z,Ctrl-Y | Command-Shift-Z,Command-Y | redo |
Ctrl-D | Command-D | remove line |
Ctrl-K | remove to line end | |
Option-Backspace | remove to linestart | |
Alt-Backspace,Ctrl-Alt-Backspace | remove word left | |
Alt-Delete | remove word right | |
Ctrl-R | Command-Option-F | replace |
Ctrl-Shift-R | Command-Shift-Option-F | replace all |
Ctrl-A | Command-A | select all |
Shift-Down | Shift-Down | select down |
Shift-Left | Shift-Left | select left |
Shift-End | Shift-End | select line end |
Shift-Home | Shift-Home | select line start |
Shift-PageDown | Shift-PageDown | select page down |
Shift-PageUp | Shift-PageUp | select page up |
Shift-Right | Shift-Right | select right |
Ctrl-Shift-End,Alt-Shift-Down | Command-Shift-Down | select to end |
Alt-Shift-Right | Command-Shift-Right | select to line end |
Alt-Shift-Left | Command-Shift-Left | select to line start |
Ctrl-Shift-Home,Alt-Shift-Up | Command-Shift-Up | select to start |
Shift-Up | Shift-Up | select up |
Ctrl-Shift-Left | Option-Shift-Left | select word left |
Ctrl-Shift-Right | Option-Shift-Right | select word right |
Ctrl-O | split line | |
Ctrl-T | Ctrl-T | transpose letters |
Ctrl-Z | Command-Z | undo |