Mercurial > lcfOS
annotate python/target.py @ 199:a690473b79e2
Added msp430 target
author | Windel Bouwman |
---|---|
date | Fri, 07 Jun 2013 18:59:57 +0200 |
parents | |
children | 5e391d9a3381 |
rev | line source |
---|---|
199 | 1 |
2 """ | |
3 Base classes for defining a target | |
4 """ | |
5 | |
6 # Machine code interface: | |
7 class Operand: | |
8 """ Single machine operand """ | |
9 pass | |
10 | |
11 class Register(Operand): | |
12 def __init__(self, name): | |
13 self.name = name | |
14 | |
15 class Instruction: | |
16 def __init__(self, opcode): | |
17 self.opcode = opcode | |
18 | |
19 class Target: | |
20 def __init__(self): | |
21 self.instructions = [] | |
22 def createInstruction(self, vi): | |
23 pass | |
24 pass | |
25 | |
26 |