Skip to content

Commit

Permalink
Merge remote-tracking branch 'refs/remotes/origin/main'
Browse files Browse the repository at this point in the history
  • Loading branch information
pm100 committed Jan 4, 2024
2 parents eb5d262 + 75dee97 commit fc26f1d
Showing 1 changed file with 31 additions and 22 deletions.
53 changes: 31 additions & 22 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -97,25 +97,27 @@ The command line has full searchable command history.
- up arrow scrolls to previous
- etc...

# load_code (load)
pressing enter will repeat the last line

### load_code (load)

loads a binary file that was output by ld65 for sim65. It expects to see the sim65 headers

`>> load <file name>`

# symbols (ll)
### symbols (ll)

loads symbol file output by ld65 for VICE. Generated by ld65 switches `-g -Ln <file>`

`>> ll <file name>`

you dont need to load symbols but its much easier with symbols

# run
### run

runs the code starting at the address found in the binary file header

# break (b)
### break (b)

Sets a breakpoint

Expand All @@ -124,13 +126,14 @@ Sets a breakpoint
Examples

`>> b ._main`

`>> b $27ba`

# bl
### bl

List break points

# bd
### bd

delete break points

Expand All @@ -142,25 +145,25 @@ deletes all break points

deletes break point #1 (from bl output)

# go
### go

resumes execution after break point

# next
### next

is 'step over' if it sees a function call it will not break until it returns

# step
### step

one instruction

# fin
### fin

run until return from current function call.

# watch (w)
### watch (w)

watch for memory read or write. Will breaak on the read of write of a location
watch for memory read or write. Will break on the read or write of a location

`>> w -r -w <addr>`

Expand All @@ -172,21 +175,21 @@ will break when a write it made to .sreg

wl and wd are the same as bl and bd

# memory (m)
### memory (m)

dumps memory

`>> m $1467`

# dis
### dis

Disassembles

`>> dis [addr]`

if no address is given it continues from the last address

# enable (en)
### enable (en)

Enables bug traps.

Expand All @@ -196,37 +199,43 @@ memory check will break if a read is made from a memory location that has not be

These are both turned off by default

# printf (p)
### print (p)

prints values from memory

`>> p -s -i -p <addr>`

Print either an integer (16 bit), a string or a pointer

# back_trace (bt)
### back_trace (bt)

Displays the current 6502 stack

# expr
### expr

Expression evaluator. Anywhere that an address can be given you can have an expression

The expr command evaluates an express, this can be useful for instecting thingss or just checking expression syntax
The expr command evaluates an expression, this can be useful for inspecting things or just checking expression syntax

an expression starts with '='. YOu can then have numbers, symbols, parantheses, registers, plus deference operations
An expression starts with '='. You can then have numbers, symbols, parantheses, registers, plus dereference operations

- `=xr` returns the x register
- `=.ptr1+0x20` returns that symbol plus 0x20
- `=@(.ptr1)` returns what ptr1 points at
- `=@ @(.ptr1)` returns what the ptr1 at ptr1 points to
- `=@(.ptr1+xr)` returns what ptr1 + xr points to

`@` is the dereference operation for a word

`@b` is the deref of a byte


Useful quickies

`dis =pc`
`expr =xr`


# quit
Note that you may need to enclose the whole expression in quotes so that it doesnt look like command arguments to the line parser

### quit

0 comments on commit fc26f1d

Please sign in to comment.