fadden / 6502bench

A workbench for developing 6502 code
https://6502bench.com
Apache License 2.0
166 stars 33 forks source link

Address table problem #149

Closed grue74 closed 1 year ago

grue74 commented 1 year ago

I have defined Project symbol

image

But Address table is not accepting that as part of the address range as OK button is greyed out.

image

I think this should be acceptable?

fadden commented 1 year ago

I think this is a duplicate of https://github.com/fadden/6502bench/issues/130

Short version: Format Address Table doesn't currently look at project/platform symbols, only "internal" labels. Some changes have been proposed.

fadden commented 2 months ago

I have a work in progress that identifies references to project/platform symbols when formatting a table. With the Commodore/C64-Kernal-RAM-use.sym65 symbol file included, the table is formatted to this:

VICSCN          .eq   $0400  {addr/1024} ;start of Default Screen Video Matrix
[...]
                .dd1  <VICSCN
                .dd1  <VICSCN+40
                .dd1  <VICSCN+80
                .dd1  <VICSCN+120
                .dd1  <VICSCN+160
                .dd1  <VICSCN+200
                .dd1  <VICSCN+240
                .dd1  <VICSCN+24
                .dd1  <VICSCN+64
                .dd1  <VICSCN+104
                .dd1  <VICSCN+144
                .dd1  <VICSCN+184
                .dd1  <VICSCN+224
                .dd1  <VICSCN+8
                .dd1  <VICSCN+48
                .dd1  <VICSCN+88
                .dd1  <VICSCN+128
                .dd1  <VICSCN+168
                .dd1  <VICSCN+208
                .dd1  <VICSCN+248
                .dd1  <VICSCN+32
                .dd1  <VICSCN+72
                .dd1  <VICSCN+112
                .dd1  <VICSCN+152
                .dd1  <VICSCN+192
                .dd1  >VICSCN
                .dd1  >VICSCN
                .dd1  >VICSCN
                .dd1  >VICSCN
                .dd1  >VICSCN
                .dd1  >VICSCN
                .dd1  >VICSCN
                .dd1  (>VICSCN)+1
                .dd1  (>VICSCN)+1
                .dd1  (>VICSCN)+1
                .dd1  (>VICSCN)+1
                .dd1  (>VICSCN)+1
                .dd1  (>VICSCN)+1
                .dd1  (>VICSCN)+2
                .dd1  (>VICSCN)+2
                .dd1  (>VICSCN)+2
                .dd1  (>VICSCN)+2
                .dd1  (>VICSCN)+2
                .dd1  (>VICSCN)+2
                .dd1  (>VICSCN)+2
                .dd1  (>VICSCN)+3
                .dd1  (>VICSCN)+3
                .dd1  (>VICSCN)+3
                .dd1  (>VICSCN)+3
                .dd1  (>VICSCN)+3

This still suffers from the problem where 8-bit values are formatted as individual byte offsets, rather than as pieces of a 16-bit value (see https://github.com/fadden/6502bench/issues/130#issuecomment-1120434890).

fadden commented 2 months ago

Available in https://github.com/fadden/6502bench/releases/tag/v1.9.0-dev3