Documentation ¶
Index ¶
Constants ¶
View Source
const MaxNbIODevices int = 16
Variables ¶
This section is empty.
Functions ¶
func RNGIODevice ¶
func RNGIODevice(C *Computer)
RNG: Device 1 A Random Number Generator. Places a random byte on the data bus, and saves in in RNGLast for testing purposes
func ROMSizeIODevice ¶
func ROMSizeIODevice(C *Computer)
ROMSize: Device 3 The size of the ROM module
func TTYIODevice ¶
func TTYIODevice(C *Computer)
TTY: Device 0 An output-only TTY implementation, just grabs the ASCII code on the bus and prints the corresponding character to TTYWriter
Types ¶
type Computer ¶
type Computer struct { BB *b.Breadboard IOAdapter *IOAdapter TTYWriter io.Writer RNGLast int ROMAddrLast int ROM []int // contains filtered or unexported fields }
COMPUTER
func NewComputer ¶
func (*Computer) BootAndRun ¶
Place the instructions in the ROM and calls Run() with the booloader program. A HALT instruction is appeneded at the end to make sure the computer stops when the program is over.
Click to show internal directories.
Click to hide internal directories.