host

package
v0.0.0-...-66de1e3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 3, 2020 License: BSD-2-Clause Imports: 17 Imported by: 0

Documentation

Overview

Package host allows you to create a "host" that emulates a computer system with a 6502 CPU, 64K of memory, a built-in assembler, a built-in debugger, and other useful tools.

Within the host it is possible to assemble and load machine code into memory, debug and step through machine code, measure the number of CPU cycles elapsed, set address and data breakpoints, dump the contents of memory, disassemble the contents of memory, manipulate CPU registers and memory, and evaluate arbitrary expressions.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Host

type Host struct {
	// contains filtered or unexported fields
}

A Host represents a fully emulated 6502 system, 64K of memory, a built-in assembler, a built-in debugger, and other useful tools.

func New

func New() *Host

New creates a new 6502 host environment.

func (*Host) AssembleFile

func (h *Host) AssembleFile(filename string) error

AssembleFile assembles a file on disk and stores the result in a compiled 'bin' file. A source map file is also produced.

func (*Host) Break

func (h *Host) Break()

Break interrupts a running CPU.

func (*Host) RunCommands

func (h *Host) RunCommands(r io.Reader, w io.Writer, interactive bool)

RunCommands accepts host commands from a reader and outputs the results to a writer. If the commands are interactive, a prompt is displayed while the host waits for the the next command to be entered.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL