This is an archived, read-only copy of the United-TI subforum , including posts and topic from May 2003 to April 2012. If you would like to discuss any of the topics in this forum, you can visit Cemetech's
z80 & ez80 Assembly subforum. Some of these topics may also be directly-linked to active Cemetech topics. If you are a Cemetech member with a linked United-TI account, you can link United-TI topics here with your current Cemetech topics.
Z80 & 68k Assembly =>
z80 & ez80 Assembly
Author |
Message |
|
ztrumpet
Active Member
Joined: 06 May 2009 Posts: 555
|
Posted: 13 May 2009 03:25:14 pm Post subject: |
|
|
I am trying to make the "jump" from basic to asm and my compiler woln't work.
I've done everything I can think of.
Please help.
I'm using the asm batch file from Z-80 heaven:
Code: echo Syntax: asm [NAME (w/o extension)] [PATH]
@echo off
echo ----- Assembling %1 for the TI-83 Plus...
echo #define TI83P >temp.z80
cd "..\source"
if exist %1.z80 type %1.z80 >>temp.z80
if exist %1.asm type %1.asm >>temp.z80
move /y temp.z80 "../tasm"
cd "..\tasm"
tasm -80 -i -b -l temp.z80 %1.bin %2%1.xlt
if errorlevel 1 goto ERRORS
devpac8x %1
copy %1.8xp %2%1.8xp >nul
echo TI-83 Plus version is %1.8xp
move %1.8xp "..\exec"
goto DONE
:ERRORS
echo ----- There were errors.
:DONE
del temp.z80 >nul
del %1.bin >nul
del %1.xlt >nul
I'm testing this with Sigma's Hello program:
Code: .nolist
#include "ti83plus.inc"
#define ProgStart $9D95
.list
.org ProgStart - 2
.db t2ByteTok, tAsmCmp
b_call(_ClrLCDFull)
ld hl, 0
ld (PenCol), hl
ld hl, msg
b_call(_PutS) ; Display the text
b_call(_NewLine)
ret
msg:
.db "Hello world!", 0
.end
.end
In command prompt I type (in the tasm folder) asm hello and I get:
Code: Syntax: asm [Name (w/o extension)] [Path]
Syntax: asm [Name (w/o extension)] [Path]
----- Assembling hello for the TI-83 Plus...
TASM Z80 Assembler. Version 3.2 September, 2001.
Copyright © 2001 Squack Vally Software
tasm: pass 1 complete.
temp.z80 line 0007: unrecognised instruction. (B_CALL(_CLRLCDFULL))
temp.z80 line 0011: unrecognised instruction. (B_CALL(_PUTS))
temp.z80 line 0012: unrecognised instruction. (B_CALL(_NEWLINE))
tasm: pass 2 complete.
tasm: Number of errors = 3
----- There were errors.
Any help would be appreciated.
Thanks!
Last edited by Guest on 13 May 2009 03:26:09 pm; edited 1 time in total |
|
Back to top |
|
|
calc84maniac
Elite
Joined: 22 Jan 2007 Posts: 770
|
Posted: 13 May 2009 03:29:46 pm Post subject: |
|
|
It all depends on your version of ti83plus.inc. Some versions have it as bcall() (no underscore). A quick look at that include file should tell you what's going on.
Last edited by Guest on 11 Jul 2010 03:31:23 pm; edited 1 time in total |
|
Back to top |
|
|
ztrumpet
Active Member
Joined: 06 May 2009 Posts: 555
|
Posted: 13 May 2009 03:34:06 pm Post subject: |
|
|
Yay!
This works:
Code: .nolist
#include "ti83plus.inc"
#define ProgStart $9D95
.list
.org ProgStart - 2
.db t2ByteTok, tAsmCmp
bcall(_ClrLCDFull)
ld hl, 0
ld (PenCol), hl
ld hl, msg
bcall(_PutS) ; Display the text
bcall(_NewLine)
ret
msg:
.db "Hello world!", 0
.end
.end
Thanks!
Last edited by Guest on 13 May 2009 03:34:26 pm; edited 1 time in total |
|
Back to top |
|
|
darkstone knight
Advanced Member
Joined: 07 Sep 2008 Posts: 438
|
Posted: 13 May 2009 03:58:29 pm Post subject: |
|
|
the bcall(_ \ B_call(_ is very annoying for beginners... |
|
Back to top |
|
|
ztrumpet
Active Member
Joined: 06 May 2009 Posts: 555
|
Posted: 13 May 2009 04:06:31 pm Post subject: |
|
|
Is there anything else I will need to know that is like this? |
|
Back to top |
|
|
darkstone knight
Advanced Member
Joined: 07 Sep 2008 Posts: 438
|
Posted: 13 May 2009 04:16:32 pm Post subject: |
|
|
not really, the biggest problem is assembling your first problem, and not making stupid mistakes like "ADD DE,DE"...
yea, i made that mistake... "ADD DE,HL" is irritating aswell... for beginners annyway |
|
Back to top |
|
|
ztrumpet
Active Member
Joined: 06 May 2009 Posts: 555
|
Posted: 13 May 2009 04:29:29 pm Post subject: |
|
|
Thank you for your very quick help. I've been stuck on this for 2 weeks. Thanks! |
|
Back to top |
|
|
|
Register to Join the Conversation
Have your own thoughts to add to this or any other topic? Want to ask a question, offer a suggestion, share your own programs and projects, upload a file to the file archives, get help with calculator and computer programming, or simply chat with like-minded coders and tech and calculator enthusiasts via the site-wide AJAX SAX widget? Registration for a free Cemetech account only takes a minute.
»
Go to Registration page