GIDForums  

Go Back   GIDForums > Computer Programming Forums > Assembly Language
User Name
Password
Register FAQ Members List Calendar Search Today's Posts Mark Forums Read

 
 
Thread Tools Search this Thread Rate Thread
  #1  
Old 19-Apr-2008, 03:34
Annon777 Annon777 is offline
New Member
 
Join Date: Apr 2008
Posts: 4
Annon777 is on a distinguished road
Post

need help on a task


I was asked to program using Z80 simulator IDE and its assembler to,

subtract a hex number in memory location F101h from a hex number in F100h and stores the value in memory location F202h with the following meaning:
i) 01h if the result is negative;
ii) 00h if the result is zero;
iii) FFh if the result is positive

I already did the first part. Correct me if it's wrong.

ORG 0F000h
LD A, (0F100H)
LD B, A
LD A, (0F101h)
SUB A,B
LD (0F202h), A
HALT

Now, I need help with the numbered parts. Thanks.

update: ok, I tried assembling the code and found an error. The 'SUB' was not recognized as instruction. Now, I'm running out of idea. This whole thing is very new to me..
 
 

Recent GIDBlog2nd Week of IA Training by crystalattice

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Program icons are lost in task bar when minimized ngjackie Computer Software Forum - Windows 6 20-Jan-2008 15:41
Schedule task using C /C++ code gbellair CPP / C++ Forum 5 27-Nov-2007 08:22
How to implement the task by C language newonea C Programming Language 8 24-Jul-2007 23:37
Task Manager not COMING up insaneSNIPE Computer Software Forum - Windows 0 08-Oct-2006 22:45
Looking for Software for a Certain Task ShanesterB Computer Software Forum - Windows 0 26-Feb-2006 06:50

Network Sites: GIDNetwork · GIDWebHosts · GIDSearch · Learning Journal by J de Silva, The

All times are GMT -6. The time now is 23:27.


vBulletin, Copyright © 2000 - 2008, Jelsoft Enterprises Ltd.