Search Results

Showing results 1 to 39 of 39
Search took 0.01 seconds.
Search: Posts Made By: sysop_fb
Forum: C++ Jun 18th, 2009
Replies: 5
Views: 376
Posted By sysop_fb
So you want like a cuecard type program? Console based?
An easy way, given the only specifications you listed, would be to just setup your own record format for each spanish and english companion...
Forum: Assembly Jun 16th, 2009
Replies: 6
Views: 1,044
Posted By sysop_fb
You're not reading in an 'a', it's reading in a binary value that when your O/S prints recognizes as the value for 'a' and since you're putting this value onto an output stream in video it's assumed...
Forum: Assembly Jun 14th, 2009
Replies: 1
Views: 731
Posted By sysop_fb
Just think about it.

Given 11 % 3 how would you find the remainder? Well how would you do divide?
11 - 3 = +1 cycle with 8 left over
8 is > 3 so keep going
8 - 3 = +1 cycle with 5 left over
5...
Forum: C++ Jun 12th, 2009
Replies: 2
Views: 388
Posted By sysop_fb
Well I'd say you're probably not prototyping the functions you want to use from your library properly. Did you write a head file for your library and extern the prototypes?
Forum: Assembly Jun 10th, 2009
Replies: 2
Views: 731
Posted By sysop_fb
Have you read the MMX literature in the Intel Software developers manual volume 3? It explains the instructions pretty well and even gives you tips on how to optimize them.
Forum: Assembly Jun 10th, 2009
Replies: 3
Views: 528
Posted By sysop_fb
No the first one is popping whatever is on the stack at that location, the second one is considering whatever is at that position in the stack to be a memory address and you're saying whatever is at...
Forum: C May 20th, 2009
Replies: 10
Views: 891
Posted By sysop_fb
You could just add '0' to each of your numbers.
Forum: Assembly May 12th, 2009
Replies: 3
Views: 548
Posted By sysop_fb
You can look at the registers through debug
Forum: Assembly May 7th, 2009
Replies: 7
Views: 580
Posted By sysop_fb
A kernel function from what kernel? Which O/S? You can't directly call functions used inside the kernel of an O/S unless your code resides within the kernel itself or within a module of the kernel....
Forum: Assembly May 6th, 2009
Replies: 7
Views: 580
Posted By sysop_fb
No because they don't pop them off the stack. Not to mention the stack pointer as well as the stack has to be kept in the same condition as it was passed to it.
The C calling convention is the way...
Forum: Assembly May 6th, 2009
Replies: 5
Views: 689
Posted By sysop_fb
Psuedocode


a = 60
b = 3
divide a b


divide a b:
c=0
Forum: Assembly May 6th, 2009
Replies: 7
Views: 580
Posted By sysop_fb
There's one very large difference between pascal and C.
C contains functions with the ability to accept variable amounts of arguments. Such as... printf.
Pascal doesn't have(?)/can't handle...
Forum: Assembly May 5th, 2009
Replies: 5
Views: 689
Posted By sysop_fb
You can do division using subtraction.
60 / 3 if I subtract 3 from 60 it will take 20 times before 60 < 3
Forum: Assembly May 5th, 2009
Replies: 4
Views: 391
Posted By sysop_fb
Either I don't know what you're asking for or this smells like homework.

Anyway the param to the function you were asking about


mov eax,[ebp-08h]
push eax
mov eax,0051F900h
...
Forum: Assembly May 5th, 2009
Replies: 2
Views: 490
Posted By sysop_fb
A caesar encryption is just a replacement encryption.
Couple of ways to go about this but I only have time to explain two
One is the simpliest you have two strings
ABCDEFGHI
WLPQSRNXZ
You take...
Forum: Assembly May 4th, 2009
Replies: 6
Views: 383
Posted By sysop_fb
It depends, on unix systems and code from people who've used unix for eons(better to say in the unix world?) you'll find a lot of AT&T syntax. As well if you do inline asm in C you'll be doing AT&T....
Forum: Assembly May 4th, 2009
Replies: 6
Views: 383
Posted By sysop_fb
Not that I know of but you could check the man pages. I'm about 4 months out of date :)
Alternatively there are programs out there to convert your code back and forth.
Forum: Assembly May 4th, 2009
Replies: 6
Views: 631
Posted By sysop_fb
In an array of chars as such
ABCDEF
You access the 'A' via base address + 0 so you access the F via base address + 5
Then we load up our new array.
so...
new_array+0 = (user_input+5 with altered...
Forum: Assembly May 4th, 2009
Replies: 8
Views: 748
Posted By sysop_fb
Nope, you know you can still run real-mode segmented .COM purely DOS programs from the vista cmd shell?
I'm so glad they made it backwards compatible because now instead of using my gui IDE for...
Forum: Assembly May 4th, 2009
Replies: 2
Views: 381
Posted By sysop_fb
Sorry for the late response been really busy lately.
From the code you've posted I don't really see a problem.

Here's the best and most useful time to open up gdb.
And I'll attempt to explain an...
Forum: Assembly May 4th, 2009
Replies: 6
Views: 631
Posted By sysop_fb
You know the difference between an upper and lower case character?
20h
You know the difference between the binary of an upper and lower case character?
1 bit.
Consider the following
E - 01000101...
Forum: Assembly May 3rd, 2009
Replies: 1
Views: 324
Posted By sysop_fb
1. What? You can't google for an ascii table? Maybe your 'friend' should review his course materials.

2.See 1
3.See 1
4.See 1 or open up a debugger
5.See 4
6.See 4
7..... why don't you.........
Forum: Assembly May 3rd, 2009
Replies: 6
Views: 430
Posted By sysop_fb
If I'm understanding you correctly you just want to print the string to command line without using the o/s api MessageBox?
Well let's see you could use the interrupt interface; a quick google search...
Forum: Assembly May 3rd, 2009
Replies: 6
Views: 383
Posted By sysop_fb
Because they're different syntaxs and not even a little bit different...
NASM syntax is based on intel syntax while gas syntax is based on AT&T syntax.


If you write a simple hello world...
Forum: Assembly May 2nd, 2009
Replies: 2
Views: 499
Posted By sysop_fb
The first part:
If all you're wanting to do is pull a specific bit out then you should look into ANDing
I believe DIV and IDIV both only store the quotient and remainder

Second part: ...
Forum: Assembly May 2nd, 2009
Replies: 2
Views: 400
Posted By sysop_fb
Which part don't you understand?
Forum: Assembly Apr 29th, 2009
Replies: 8
Views: 748
Posted By sysop_fb
Can you post the code?
Were both computers using the same cpu architecture?
Forum: C Apr 29th, 2009
Replies: 3
Views: 305
Posted By sysop_fb
Forum: Assembly Apr 27th, 2009
Replies: 6
Views: 1,115
Posted By sysop_fb
movl 12(%ebp),%ebx #parameter 2
movl 8(%ebp),%edx #parameter 1.



loop:
addl (%ebx,%ecx,1),%eax #Parameter2[i] store in %eax
subl (%edx,%ecx,1),%eax #parameter1[i]-%eax...
Forum: Assembly Apr 27th, 2009
Replies: 5
Views: 1,228
Posted By sysop_fb
You know how to use gdb? :)
Also repost your code if gdb shows no hints.
Forum: C Apr 27th, 2009
Replies: 7
Views: 719
Posted By sysop_fb
You just want to know how to concatenate two strings in C?

strcat(my_buffer, my_other_buffer);

Although if you're going to placing your new tokens in a completely new area via strcpy and then a...
Forum: Assembly Apr 26th, 2009
Replies: 5
Views: 1,228
Posted By sysop_fb
Try using di instead of trying to do all that crazy addition followed by subtraction.


mov si,0
mov di, strlen
.loop:
mov dx , [str + si]
mov cx , [str + di]
mov [aloc + si], dx
mov...
Forum: Assembly Apr 25th, 2009
Replies: 6
Views: 1,115
Posted By sysop_fb
indexing an array is easy. We'll assume I'm referring to a char array.
if the memory address of your array is in ebx
then ebx+0 is the first element in that array correct?
So that means ebx+1 is...
Forum: Assembly Apr 25th, 2009
Replies: 4
Views: 733
Posted By sysop_fb
MIPS has a rol/ror (rotate left / rotate right) mnemonic doesn't it?

If I couldn't do rotating I imagine I would use ANDing with a combination of shifting.
Forum: Assembly Apr 24th, 2009
Replies: 2
Views: 433
Posted By sysop_fb
If you have a 32 bit system you could just do something like

Either checking if it overflowed into dx or just zeroing everything out before hand
mov cx, dx
shl ecx, 16
mov cx, ax


Or you...
Forum: Assembly Apr 24th, 2009
Replies: 10
Views: 881
Posted By sysop_fb
If you're attempting to use the windows/dos interrupt 10 in linux then ofcourse you're going to be having problems, because you're not in windows/dos :)
You should look up the linux interrupt 80h
Forum: Assembly Apr 24th, 2009
Replies: 10
Views: 881
Posted By sysop_fb
When you execute your executable it seg faults? Well would kind of need some code to see what's going on.
Forum: Assembly Apr 24th, 2009
Replies: 6
Views: 1,115
Posted By sysop_fb
You need to post some sort of an attempt and then I'll help you with it. I'll give you a hint though --
If you index through each string at the same time and cmp each time in a loop as long as cmp...
Forum: Assembly Apr 24th, 2009
Replies: 2
Views: 769
Posted By sysop_fb
mov ebx,1
add ebx,string
mov string, [ebx]

On the third line you're trying to copy the second character of string into the address of the first character in string. I don't think that's your...
Showing results 1 to 39 of 39

 


About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC