Jump to content





Title screen

Posted by atari2600land, 05 December 2018 · 58 views

there.
Attached Image
Now what I want to do is have this start automatically WITHOUT me typing "SYS 4096." The * symbol does not want to work in DASM, so * = 1000 is out of the question...






Figured it out. Apparently * in my disassembler (DASM) means org. It kept giving me an unknown mnemonic error if I put in * = 0801. I found this online and replaced the *=0801 with org $0801 and it runs good.

  org $0801
    .byte $0c, $08, $0a, $00, $9e, $20
    .byte $34, $30, $39, $36, $00, $00
    .byte $00
  • Report

Here is a macro for you, suitable to be used in DASM. It is called like this:

 

basicline $0801,2018

 

where $0801 equals start of the program (org) and 2018 is the line number of the SYS. Basically it doesn't do anything your current code already doesn't, except that if you would have reason to use a different ORG or want a different line number, it will adjust automatically.

 

#mac basicline
  org {1}
  word 0$ ; link to next line
  word {2} ; line number
  byte $9E ; SYS token
 
; SYS digits
 
  if (* + 8) / 10000
    byte $30 + (* + 8) / 10000
  endif
  if (* + 7) / 1000
    byte $30 + (* + 7) % 10000 / 1000
  endif
  if (* + 6) / 100
    byte $30 + (* + 6) % 1000 / 100
  endif
  if (* + 5) / 10
    byte $30 + (* + 5) % 100 / 10
  endif
  byte $30 + (* + 4) % 10
  byte 0 ; end of BASIC line
0$:
  word 0 ; end of BASIC program
#endm
  • Report

December 2018

S M T W T F S
      1
2345678
9101112131415
161718 19 202122
23242526272829
3031     

Recent Entries

Recent Comments

Search My Blog

Search My Blog