Machine code translation help?

Incinerator

Limp Gawd
Joined
Aug 31, 2005
Messages
252
I've translated this code and did the few commands it wanted like but I'm hung up on this command 02 36 33 01.

Here's a picture of the hw, the only wrong one is the history of DX.
mlhwus5.jpg


I dont know whats wrong, I should just have to add DH with [0133]. ie 95+95 but it comes out to 12a, so I've tried 12a0, 1200, and some other values that didn't make sense but none have worked. Have I missed something?
 
well I tried 0a12 and that wasn't right. That was what I meant when I said values that didn't make sense, because add DH, [0133] should go directly into DH (the first 2 spaces of DX) and for the other registers there was no problem with how I was doing it...so I'm just lost.
 
Which processor is this for? Running in which mode?
 
Not that it's particularly innovative or unique, but that program looks extremely similiar to this program my professor at my University required use to complete assignments (Professor Wirth).

I always thought it was particularly interesting when we would get assignments that had multiple ways of writing the same answer, but yet his program would only accept the answer that matched the format he was expecting.
 
Intel 8088 processor

and this is the program you're talking about. Mentor. Hoggard is using it this semester for this Assembly class, and I know that sometimes Mentor is picky but I know that this is the right format for multiple changes in a register's value.
 
Ok so here's the thing...

95h + 95h = 012A

but its 2 bytes wide, so it wont fit in the DH register...

so it's going to cut off a byte. (DL is untouched at this point)
 
wow, if thats it I'm going to feel really stupid. I cant check right now but I will soon, but thanks a lot for your help.
 
Back
Top