Forum: Assembly 17 Days Ago |
| Replies: 2 Views: 330 Review how VIDEO BIOS Interrupt 10h is suppose to function!
You indicate string doesn't contain attributes with AX,1300h
BUT Never set BL to indicate attribute to use!
ALSO DL=column ... |
Forum: Assembly 17 Days Ago |
| Replies: 2 Views: 394 ????
addi $t0, $t0, 0 # increment address in $t0
N = N + 0
Did you cut'n'paste improperly?
Is code missing? |
Forum: Assembly 22 Days Ago |
| Replies: 7 Views: 310 Command line Arguments are typically passed in one of two ways to a program at startup.
int count count of arguments
char *argv[] array of arguments
This seems to... |
Forum: Assembly 23 Days Ago |
| Replies: 7 Views: 310 Can't do that, you don't have code! |
Forum: Assembly 23 Days Ago |
| Replies: 7 Views: 310 code?
Are you trapping for a keyword mult?
How about trapping for operators
3 * 4
12
1 + 2
3 |
Forum: Assembly 23 Days Ago |
| Replies: 1 Views: 305 Okay, I'm flipping this back at you. Note the comments and decide for yourself!
By the way. Did you mean
((xvy)^z)*2
((x OR y ) AND z ) * 2
then next time...
((x | y) & z) * 2
Or did you... |
Forum: Assembly 23 Days Ago |
| Replies: 1 Views: 295 Use a register to increment.
Use a register as memory reference that you increment.
Use a register for value loaded from memory.
Use a register for current max index.
You need to try to do... |
Forum: Assembly 23 Days Ago |
| Replies: 3 Views: 337 You can download processor books but my favorite reference is the 32/64-bit 80x86 Assembly Language Architecture Book.
Your mathematical operation and/or compares will set conditional flags.
You... |
Forum: Assembly 23 Days Ago |
| Replies: 4 Views: 383 You aren't being very clear!
If you are using a more recent computer but somehow using an old DOS interface and not in an emulator, then you can use 32-bit instructions in Real Mode. An operand... |
Forum: Assembly 24 Days Ago |
| Replies: 6 Views: 393 Sorry we digressed but this website policy is that we can't post code except in response to helping you correct your posted code. Since you haven't posted code our ability to help you is limited! |
Forum: C 25 Days Ago |
| Replies: 1 Views: 158 Code, what code?
If I understand your need you need edge triggering. Assuming high until pull down upon edge trigger.
Here's some C code. You need to create an assembly language equivalent!
... |
Forum: Assembly 26 Days Ago |
| Replies: 4 Views: 268 PEP8 doccumentation is NIL!!!
[code]
; 1100 raaa Load register r from memory
0000 C1000C 1100 0011 - 000C LDA FirstNum,d ; A: = first number
; 0001 100r NOT of Register R
0003... |
Forum: Assembly 26 Days Ago |
| Replies: 4 Views: 268 That part was obvious.
I'm not familiar with PEP8 but am with many other processors.
Use your table lookup and convert the binary back into pseudo source code to make it readable! |
Forum: Assembly 26 Days Ago |
| Replies: 4 Views: 268 Why are you showing us the binary output.
Please show the source code used to generate that binary output or atleast the list file that contains both binary and the source assembly! |
Forum: Assembly 27 Days Ago |
| Replies: 6 Views: 393 Actually pretty straight forward! Two months no problem! And I need the work! My employer sent us all home over three weeks ago. |
Forum: Assembly 27 Days Ago |
| Replies: 6 Views: 393 This sounds more like an engineering task. There are websites like guru.com, etc. where you can post this kind of thing and find someone to build it for you! You will need to indicate whether you're... |
Forum: Assembly 27 Days Ago |
| Replies: 1 Views: 366 I'm VERY VERY rusty on a 68HC12
ldy #16 ;Loop 16 times
Loop:
asld ; Carry <- A <- B <- 0 MSB in carry
psha
? ; a = Sum
adda a,0 ;... |
Forum: Assembly 31 Days Ago |
| Replies: 10 Views: 545 Not familiar with EMU8086 and assuming you can't use an alternate tool you can do it this way!
; Alpha sorted for speed
Label FoodTable
DWORD offset xApple, iApple
DWORD offset... |
Forum: Assembly 32 Days Ago |
| Replies: 10 Views: 545 Almost.
That's your initial get the code working step.
Then, once it works, since the text is alpha sorted, and the records are fixed size, do a binary search.
Look a record COUNT/2, Is it,... |
Forum: Assembly 32 Days Ago |
| Replies: 10 Views: 545 There's usually hundreds of commands in a scripting language so would mean more like...
iApple = 1
iPear = 2
iCorn =3
iDog = 4
iGrape= 5
xApple db 'Apple',0
xCorn db 'Corn',0 |
Forum: Assembly 33 Days Ago |
| Replies: 10 Views: 545 A command line selector should be a table of ASCII commands with associated enumeration. When a string match is found, then use the enumeration with a jump table to call that command handler! |
Forum: Assembly 33 Days Ago |
| Replies: 2 Views: 290 I think you misunderstand the syscall function. It doesn't return a four byte integer. It returns a string!
You also aren't setting $a1 to maximum number of characters to read - 1. The function... |
Forum: Assembly 33 Days Ago |
| Replies: 4 Views: 561 This may make your issue more obvious...
Quotient : Remainder = Dividend / Divisor
AL : AH = AX / (8-bit)
AX : DX = DX:AX / (16-bit)
EAX : EDX = EDX:EAX /(32-bit)
You needed to specfy a... |
Forum: Assembly 34 Days Ago |
| Replies: 1 Views: 171 There is absolutely no reason for someone to be messing around with the binary in this era of assemblers and compilers. But if you are overly curious, run your debug. Open the command prompt and type... |
Forum: Assembly 34 Days Ago |
| Replies: 7 Views: 399 Different ways to solve your problem, but first a near relative jump is +127....-128
You can use an inverse branch logic.
if ! NeedToJumpUP goto next
jmp far above
next: |
Forum: Assembly 34 Days Ago |
| Replies: 1 Views: 236 The ASR Arithmetic Shift Right instruction affects four flags.
N (Negative) Bit set if sign bit (MSB) is set!
Z (Zero) Bit set if result is zero.
C (Carry) Bit Set with previous value in LSB. ... |
Forum: Assembly Oct 16th, 2009 |
| Replies: 5 Views: 314 According to your other post you mention entering integers with that many digits and parsing each digit. Why are you now entering as a Single-Precision Floating-Point value and having the system call... |
Forum: Assembly Oct 16th, 2009 |
| Replies: 5 Views: 314 You are getting exactly the error I'm talking about! That's one of the reason you do not use floating-point for accounting as you lose pennies! That's why for accounting application its best to... |
Forum: Assembly Oct 14th, 2009 |
| Replies: 3 Views: 239 You perform an multiplication and store the 32-bit low result in register t3 and the upper 32-bits in register t2.
But you print register t0, one of the source operands of the multiplication, not... |
Forum: Assembly Oct 14th, 2009 |
| Replies: 3 Views: 10,071 You should enter your five integers by looping and storing in an array, then summing the array.
In your code you don't need the compare as the addition will set the zero flag if the result is... |
Forum: Assembly Oct 14th, 2009 |
| Replies: 3 Views: 239 $LO = $s * $t
mult $t0,$t1
mfhi $t2 # HI
mflo $t3 # LO
la $a0, t0 equals
li $v0, 4 #print_string
syscall |
Forum: Assembly Oct 14th, 2009 |
| Replies: 1 Views: 306 The Auxiliary Carry (AF bit of Status Flags) is used for the carry out of bit 3 (0...7) into bit 4 for use in BCD operations! Think of it as a nibble carry! |
Forum: Assembly Oct 14th, 2009 |
| Replies: 5 Views: 314 Won't work the way you think!
A float is 32-bit so only have about 4-5 digits of precision. That number is WAY TOO BIG! So it will definitely be put into exponential form provided the buffer is... |
Forum: Assembly Oct 12th, 2009 |
| Replies: 2 Views: 214 MIPS doesn't have a carry bit like the 80x86 so you have to emulate it!
If result of lower 32-bit addition is less then any of the original values then a carry occured! So use the result of the... |
Forum: Assembly Oct 11th, 2009 |
| Replies: 1 Views: 213 |
Forum: Assembly Oct 11th, 2009 |
| Replies: 8 Views: 381 You can also do it in BCD!
No need for decimal to ASCII conversion!
This is just one way to do this!
mov bh,'8'
mov bl,'4'
sub bh,'0'
sub bl,'0'
;bh = 10's digit, bl=1's digit |
Forum: Assembly Oct 11th, 2009 |
| Replies: 2 Views: 10,139 Technically that's not a string reversal. If you were to push your characters into a buffer, then reverse them, that's a string reversal!
But your code appears to be okay! Do you have a specific... |
Forum: Assembly Oct 11th, 2009 |
| Replies: 3 Views: 392 Not to cloud the issue, but first you need to deterimine if you are working with signed versus unsigned data? You need to use a different compare based upon the type of data you're using!
Above &... |
Forum: Assembly Oct 7th, 2009 |
| Replies: 4 Views: 339 Vex or First cmpetitions?
Or homebrew? |
Forum: Assembly Oct 7th, 2009 |
| Replies: 4 Views: 339 LEAVE STI ALONE!!!!!!!!!!!!!!
Interrupts are already turned on! If they weren't no input would be handled. No keyboard, no anything as they are all interrupt driven!
There is a Serial BIOS in... |