Dutchman2000 Posted June 30, 2015 Share Posted June 30, 2015 Hello- I am currently trying to convert some old 6502 source code to compile with DASM. One of the commands keeps getting a syntax error and I can't figure out what to change it to. The commands are currently: LDA #HIGH MYVEC LDA #LOW MYVEC MYVEC is the label of a subroutine. Anyone know the proper DASM conversion? Quote Link to comment Share on other sites More sharing options...
Bryan Posted June 30, 2015 Share Posted June 30, 2015 I think DASM uses greater/less than symbols to break up a word. I'm surprised how difficult it's been to verify this with a quick Internet search, though... try lda >myvec, lda <myvec. Quote Link to comment Share on other sites More sharing options...
CPUWIZ Posted June 30, 2015 Share Posted June 30, 2015 Exact usage: lda #>(MYVEC) ; HIGH sta lda # sta 1 Quote Link to comment Share on other sites More sharing options...
Dutchman2000 Posted June 30, 2015 Author Share Posted June 30, 2015 Thanks guys! That worked! Another question, I know that DB converts to BYTE but does DW convert to WORD? Quote Link to comment Share on other sites More sharing options...
Bryan Posted June 30, 2015 Share Posted June 30, 2015 I believe (again, I'm not 100% sure) that DASM supports dc.(type). So bytes are injected into the code with dc.b and words (saved little endian) with dc.w. Quote Link to comment Share on other sites More sharing options...
CPUWIZ Posted June 30, 2015 Share Posted June 30, 2015 Correct, I use both. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.